Posted: 11th Jun 2007 4:31
Hi,

I am writing a very simple app (for my own convenience), where I need to input a string command (strictly 2D) and then switch to 3D. Now, the first time it works. However, when I try to switch from 3D to 2D for the INPUT command (which doesn't work to well with a 3D backdrop), well, let's just say everything goes crazy. Either the INPUT's prompt doesn't show, or whatever I write begins to flicker.

So basically, when the program begins, it asks for the input string, and creates the 3D camera. Then, I need to somehow get rid of the camera and do another INPUT. I tried using SET CAMERA VIEW, but it didn't work. I tried DELETE CAMERA, but even after deleted, the 3d backdrop continues to show, and my INPUT command's output looks horrible. Any suggestions on this?
Posted: 11th Jun 2007 5:16
Try this:

+ Code Snippet
<Code That Creates Camera>
Sync Off
CLS
Input "Whatever";yourvariable
Sync on : sync rate Youramount
<Continued Code>


Not tested so I don't know if it will work, but hopefully the CLS command there will do the trick.
Posted: 11th Jun 2007 16:43
Simply use:

Set Camera View 0,0,1,1

This will set the 3D output window to a single pixel, but as long as you don't use the CLS command, what was on the screen will remain there while you use the Input command.

When you want the camera view back, simply use:

Set Camera View 0,0,800,600

.. or whatever screen mode you were using before.

TDK_Man
Posted: 23rd Jun 2007 23:26
Hi, thanks for your replies.

But even using CLS, what was on the screen remains. Why is this?
Posted: 23rd Jun 2007 23:33
Hmmm...

It shouldn't do - well, I should say that it doesn't in DBC, so it might be another difference between DBC and Pro.

But, did it solve the problem you were having? If so, then all well and good!

TDK_Man
Posted: 24th Jun 2007 2:37
This retains the 3d screen, but the input looks fine.

+ Code Snippet
backdrop on
sync on

make object cube 1,1
do
if spacekey()
   set camera view 0,15,800,600
   cls 0
   input "hello: ",a$
   set camera view 0,0,800,600
endif

text 0,0,a$
turn object left 1,.1
sync
loop


May not be exactly what your looking for, but for a simple way of entering text I think it would suffice.