Hi all.
1.- How do I define a Light Radius? Because i need the light radius to be independant from it's color intensity. This is, I need to create a large light source, with a low color value, for example, radius 50000 and color #110000 (or RGB(25, 0, 0)).
2.- How do Terrain Meshes works exactly? I want to create a terrain object, and i have created a 256 colours B&W TGA image to define heights, but when compiling the program, it returns a fatal error and crashes. Debugger returns no error or message. Any tip? I'm using GIMP last version to do this.
3.- How can i "print" a message to the player in the 3D Scene? I mean, what function i should use to do that? Is there any "PrintScene(<message>)" or similar?
That's all. Thanks in advance.
Tschüs.
Coding Questions for 3D Game programming
Coding Questions for 3D Game programming
Auf Deutsch, es klingt besser.
Re: Coding Questions for 3D Game programming
Extract from docÜbermann wrote:2.- How do Terrain Meshes works exactly? I want to create a terrain object, and i have created a 256 colours B&W TGA image to define heights, but when compiling the program, it returns a fatal error and crashes. Debugger returns no error or message. Any tip? I'm using GIMP last version to do this.
The used picture must be a sqare, where x and y sizes are powers of 2 +1, with a minimum size of 65. Possible sizes can be 65x65, 129x129, 257x257 and so on. E.g. for a terrain with 64x64 grid of squares you need 65x65 pixels.
You can use Window3D and Gadget3D to buid a GUI, or use a Sprite.3.- How can i "print" a message to the player in the 3D Scene? I mean, what function i should use to do that? Is there any "PrintScene(<message>)" or similar?
Please correct my english
http://purebasic.developpez.com/
http://purebasic.developpez.com/
Re: Coding Questions for 3D Game programming
I know that.Comtois wrote:Extract from docÜbermann wrote:2.- How do Terrain Meshes works exactly? I want to create a terrain object, and i have created a 256 colours B&W TGA image to define heights, but when compiling the program, it returns a fatal error and crashes. Debugger returns no error or message. Any tip? I'm using GIMP last version to do this.
The used picture must be a sqare, where x and y sizes are powers of 2 +1, with a minimum size of 65. Possible sizes can be 65x65, 129x129, 257x257 and so on. E.g. for a terrain with 64x64 grid of squares you need 65x65 pixels.
I just modified the image at the examples, drawing a simple white line, and saving the image as 256 colors (what the help file says) and black and white. But the program crashes. I didn't change the image size, so that's not the problem.
I did, with Gimp:
1.- Open the examples image,
2.- Draw a 5 pixels width white line,
3.- Save the image,
4.- Close Gimp, and compile/run the terrain sample again.
5.- When i choose the resolution and start the demo, the program crashes. No debug error or message.
I have already solved that, aber i didnt test it. I think i can use the "DrawText( )" procedure.
Anyway, thanks for your help.
Auf Wiedersehen.
Auf Deutsch, es klingt besser.
- Kaeru Gaman
- Addict

- Posts: 4826
- Joined: Sun Mar 19, 2006 1:57 pm
- Location: Germany
Re: Coding Questions for 3D Game programming
as far I remember, Drawing doesn't work properly with DX9.I think i can use the "DrawText( )" procedure.
better use a Spritefont.
oh... and have a nice day.
