SFML community forums

Help => Graphics => Topic started by: ludolover on June 11, 2020, 12:47:27 am

Title: Drawn vertex array not showing up when cleared between frames
Post by: ludolover on June 11, 2020, 12:47:27 am
I have a vertex array that is being processed, then drawn to a RenderWindow. After calling display on the window, I want to clear the vertex array, making it ready for another round of processing. However, when clearing it - nothing shows up in the window. It works when not clearing, but now I'm drawing junk since the number of vertices differ between frames...

my loop (pseudo):

  populate vertex array
  clear window
  draw vertex array to window
  display window
  clear vertex array (now nothing shows in window)

Am i doing something wrong here (probably)? Help!

 
 
Title: Re: Drawn vertex array not showing up when cleared between frames
Post by: Laurent on June 11, 2020, 07:17:52 am
Seeing actual code may help.