Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 pictures and cls
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
pavol




PostPosted: Fri Jan 20, 2006 11:03 am   Post subject: pictures and cls

is there any way to cls everything on the screen besides something like a background pic. i'm starting on a game, i draw a background pic and the user controls this guy on it. the only problem is that this makes the game very very slow cuz i have to redraw the background pic every time. so is there any way to cls, keep the background, and redraw the user guy in the new position? Hit Wall
any help appreciated
Sponsor
Sponsor
Sponsor
sponsor
sylvester-27




PostPosted: Fri Jan 20, 2006 11:17 am   Post subject: (No subject)

could u post the code please. It'll make it easier.
do_pete




PostPosted: Fri Jan 20, 2006 11:19 am   Post subject: (No subject)

Well according to the manual picXor should do the trick ... but it doesn't so I don't think you can do it.
Albrecd




PostPosted: Fri Jan 20, 2006 11:38 am   Post subject: (No subject)

How is picXor supposed to do that? I never could make any sence out of it...
do_pete




PostPosted: Fri Jan 20, 2006 11:45 am   Post subject: (No subject)

There is something about that in [Turing Tutorials]
Prognosis




PostPosted: Sat Jan 21, 2006 11:20 pm   Post subject: (No subject)

in your loop, whenever you want to do a cls, just draw all of the graphics over again for your backround.
codemage




PostPosted: Mon Jan 23, 2006 1:22 pm   Post subject: (No subject)

Noo... use Xor. Wonderful Xor.

Draw OVER your on-screen objects with Xor.
This erases them, but leaves the background layer.
You can then re-draw the objects in their new positions.

Shake-rinse-repeat.
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 7 Posts ]
Jump to:   


Style:  
Search: