06-21-2006, 06:11 AM
06-21-2006, 06:36 AM
Quote:what is this c++ wrapper i keep looking at for using C++ Header library's in freebasic?I haven't heard of it.
There's the GCC frontend which should allow us to use C++ stuff, and other things from just about every other modern programming language AFAIK (Or maybe it's just that anything not written in C is usually written in C++ or ASM lolz)... Someone FBC smart please banish me to hell for my mistakes in this paragraph.
06-21-2006, 01:33 PM
to use c++ library in fb using wrappers is possible. In this scenario wrapper is a thin layer that implements c++ library in a C procedural way.
Forxample wx-c is a wrapper that warps wxWidgets into C like api. or MFC that wraps winapi into more OOP style.
Forxample wx-c is a wrapper that warps wxWidgets into C like api. or MFC that wraps winapi into more OOP style.
Anonymous
06-21-2006, 08:24 PM
like, in c++ you can have an object with a bunch of methods, lets say your object is called myTimer and it has methos set, print, restore. then in c++ you could do like
but in procedural you need only function calls, so a wrapper would be like this (in fb pseudo code)
of course, it wouldnt be sub...end sub in c++, i just did that so it'd be easier to understand.
Code:
myTimer::set()
myTimer::print()
but in procedural you need only function calls, so a wrapper would be like this (in fb pseudo code)
Code:
sub myTimer_Set()
myTimer::set()
end sub
of course, it wouldnt be sub...end sub in c++, i just did that so it'd be easier to understand.