Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / How to clear a 3d screen?

Author
Message
ScottyB
18
Years of Service
User Offline
Joined: 26th Jul 2007
Location:
Posted: 2nd Aug 2007 01:24
How do you clear a 3d-screen?
It's blue and I would like to paint it black.
cls does'nt work appearently in this mode.
Thanks
roddman
18
Years of Service
User Offline
Joined: 24th Jul 2007
Location: Over There
Posted: 2nd Aug 2007 03:50
Since it's blue I assume you have the backdrop turned on. If so all you have to do is COLOR BACKDROP 0.

Cls only clears 2d like text, lines, etc.

Cory
luke810
19
Years of Service
User Offline
Joined: 4th Sep 2006
Location: United States
Posted: 2nd Aug 2007 06:24
The "3d-screen" is the backdrop and you have to recolor it using the COLOR BACKDROP command. (For black it would be Color Backdrop 0)
Hangar18
19
Years of Service
User Offline
Joined: 13th Mar 2007
Location:
Posted: 2nd Aug 2007 06:24
I think the following should help.

backdrop on
Color backdrop 0
sync

Also if you want to have a texture in the background, rather than just black space then you could do... (note "imagename" needs to be a texture you have created in PSP or Photoshop say but you can export your images as bmp, psd or a number of other extns that DB recognises (i.e. DB isnt just limited to png files).


load image "imagename.png",1
make object plain 100,100,2
Texture object 2,1
Position object 2,0,0,0
Position camera 0,0,0
point camera 0,0,0
do
sync
loop
luke810
19
Years of Service
User Offline
Joined: 4th Sep 2006
Location: United States
Posted: 2nd Aug 2007 06:28
If you want a texture for the backdrop and it's seamless you can also you the TEXTURE BACKDROP command. Although the downside is that it maps the texture onto the backdrop as 2 rows of three tiles.
ScottyB
18
Years of Service
User Offline
Joined: 26th Jul 2007
Location:
Posted: 2nd Aug 2007 20:11
Thanks that fixed the problem and thanks
for the tips.

Login to post a reply

Server time is: 2026-07-05 22:38:50
Your offset time is: 2026-07-05 22:38:50