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

Author Topic: PreserveOpenGLStates  (Read 2377 times)

0 Members and 1 Guest are viewing this topic.

Afr0

  • Newbie
  • *
  • Posts: 6
    • View Profile
    • http://www.afr0games.com
PreserveOpenGLStates
« on: March 12, 2012, 02:50:34 pm »
Can someone give me a list of states preserved by PreserveOpenGLStates()?
I tried looking this up in the C# documentation, but it wasn't mentioned.
I really want to use SFML for rendering, because I can't figure out how to render the way I need to using XNA, but SFML seems to be doing some weird coordinate system changes that prevents OpenGL rendering from working the way it does in C and C++ (animations are fucked up, and when rendering triangles all seem to be rendered in the same place).
I tried editing the Nehe example in the Tao distribution to ensure that this was in fact a problem with SFML, but the Tao examples all keep crashing my computer (even when I compile as 32bit, as I'm on a 64bit system).

I also tried disabling the states by calling App.PreserveOpenGLStates(false), but that made me unable to render anything at all (except the SFML image).

coolhome

  • Jr. Member
  • **
  • Posts: 59
    • View Profile
Re: PreserveOpenGLStates
« Reply #1 on: March 12, 2012, 08:07:32 pm »
Just out of curiosity why do you want to use SFML with XNA? I see no point in attempting to use both. It would be too painful with no benefit.
CoderZilla - Everything Programming

Afr0

  • Newbie
  • *
  • Posts: 6
    • View Profile
    • http://www.afr0games.com
PreserveOpenGLStates
« Reply #2 on: March 12, 2012, 09:26:33 pm »
I'm not trying to use SFML with XNA, I'm trying to use SFML and OpenGL instead of XNA!!
I thought it would be easy but SFML is giving me a really hard time. I need to know specifically which states are preserved when calling RenderWindow.PreserveOpenGLStates()

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
PreserveOpenGLStates
« Reply #3 on: March 12, 2012, 10:46:57 pm »
Quote
I need to know specifically which states are preserved when calling RenderWindow.PreserveOpenGLStates()

Why don't you simply look at the source code? Honestly, I don't remmeber what this function did in SFML 1.6.
Laurent Gomila - SFML developer