Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Delete Window content  (Read 1344 times)

0 Members and 1 Guest are viewing this topic.

newatthis

  • Newbie
  • *
  • Posts: 1
    • View Profile
    • Email
Delete Window content
« on: June 24, 2017, 11:22:54 am »
Dear Members,

I´ve got an issue with my Program. I need to know if there is a general command in SFML to delete my whole window Content after running through a loop. My Problem is the shout down of the program after a certain amount of reps, due to the fact that created shapes in the step before are still existent.

Do you have any ideas how to fix this Problem?

This is the first time I use SFML so sorry for my low skills ;)

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11030
    • View Profile
    • development blog
    • Email
Re: Delete Window content
« Reply #1 on: June 24, 2017, 12:35:32 pm »
You should read through the official SFML tutorials.
A general render loop should consist of one clear(), some draw() and one display() call.

So it sounds like you're missing the clear() call.
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/