Search found 484 matches
- Jun 16, 2007 5:13
- Forum: Libraries Questions
- Topic: openGL textures and FB
- Replies: 12
- Views: 7337
Change this: '' generate texture glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, wid, hgt, 0, GL_RGBA, GL_UNSIGNED_BYTE, buffer) to this: '' generate texture glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, wid, hgt, 0, GL_BGR, GL_UNSIGNED_BYTE, buffer) Untested, but the same technique has worked in my C++ projects....
- May 17, 2007 10:17
- Forum: Beginners
- Topic: recursive functions?
- Replies: 3
- Views: 2631
Yes, functions can call themselves, and yes, what you're asking is very possible. Turn your sub into a function that returns an integer. At the beginning of the function, declare a local integer, init that to zero. At each recursive function call inside your recursive function, add the return value ...
- Mar 11, 2007 10:02
- Forum: Game Dev
- Topic: using GETJOYSTICK
- Replies: 5
- Views: 3927
- Mar 06, 2007 1:58
- Forum: Beginners
- Topic: math operations with array pointers
- Replies: 11
- Views: 4350
If you have a better answer then post it. But your response is pretty clueless to me. No seriously, next time you have a problem, you should copy-paste the code as is. Adapted versions can inadvertently introduce self-corrections, and then we're left wondering why the code sample works, but the cod...
- Mar 04, 2007 7:20
- Forum: Beginners
- Topic: math operations with array pointers
- Replies: 11
- Views: 4350
Thanks for the replies. This code works, it is a little messy and not-so-optimal but does the work. So my guess is that FB likes to know the upper and lower bounds of the arrays (like its own descriptor is set)? Nope. It just means you screwed up with the first code sample, though I've got nothing ...
- Mar 03, 2007 2:12
- Forum: General
- Topic: Any other debuggers?
- Replies: 10
- Views: 2790
- Feb 27, 2007 23:07
- Forum: Linux
- Topic: Integrating GfxLib with Gtk
- Replies: 14
- Views: 13694
You are seeing the color problems, right? The order of the bytes in the screen buffer still need to be worked out. Maybe it would be nice if ScreenRes could allow you to tweak the byte order, say to just make it RRRRGGGGBBBB, instead of some 4-byte thing that the 24-bit screen defaults too. Yeah, I...
- Feb 27, 2007 5:58
- Forum: Linux
- Topic: Integrating GfxLib with Gtk
- Replies: 14
- Views: 13694
- Feb 22, 2007 0:51
- Forum: Beginners
- Topic: Pointer as an formula. (solved)
- Replies: 9
- Views: 2857
Since those pointers have to maintained somehow, they need to go into a class or type. Knowing stuff about classes, but nothing about classes in FB, the following code is purely theoretical and should be fixed by somebody who knows what they're doing: '' UNTESTED THEORETICAL FB CODE ''*** Pseudo cla...
- Feb 22, 2007 0:21
- Forum: Beginners
- Topic: Static array of pointer on static array ... how to ?
- Replies: 6
- Views: 1993
Well, there's good news and there's bad news. The bad news is that AFAIK, once you turn to pointers, you lose FB's nice array information. To find out if you're at the end of an array, you'll need to use either a sentinel value, or define a wrapper type with a length. FB's pointers most closely mimi...
- Feb 21, 2007 21:59
- Forum: General
- Topic: Windows API: How do I call it?
- Replies: 13
- Views: 4304
- Feb 18, 2007 5:16
- Forum: General
- Topic: shared library not working?
- Replies: 7
- Views: 2775
Like coderJeff said, this will do the trick: LD_LIBRARY_PATH=.:$LD_LIBRARY_PATH ./mytest As to why Linux doesn't search the current directory for libs, it's considered a security risk. Otherwise anybody could override vital system libraries with their own versions just by plonking in the malicious l...
- Feb 17, 2007 5:33
- Forum: Archive
- Topic: Bullet Rel
- Replies: 4
- Views: 3036
- Feb 16, 2007 10:50
- Forum: General
- Topic: OOP & Code Scope
- Replies: 8
- Views: 3632
Wouldnt it be better to have all the members of a Type or Class included in the scope of the declaration? Its seems like its a much cleaner and more logical implementation. Better than what? All members of a class are accessible inside the class and its members. Public members are also accessible o...
- Feb 15, 2007 0:50
- Forum: Beginners
- Topic: Creating a union of two types
- Replies: 7
- Views: 2477