Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

frame buffering

 
not -Mc
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
first i initialise the onscreen frame when the program starts and then copy the empty frame buffer



then i write all my graphics to the buffer frame in my draw() method at the end of which the buffer frame is copied to the onscreen frame.



but then if i set frame to = buffer, wont it become invisible too, so i need to reapply visibility which causes the frame to flash between visible and invisible.

I feel like i'm doing it completely wrong, any suggestions for this newb?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, welcome to the ranch ! Please check your private messages for an important administrative matter.
 
Rob Spoor
Sheriff
Pie
Posts: 20495
54
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
buffer and frame both refer to the same JFrame object.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic