equal
deleted
inserted
replaced
65 EGLI_ASSERT( m_osContext != NULL ); |
65 EGLI_ASSERT( m_osContext != NULL ); |
66 } |
66 } |
67 |
67 |
68 CEGLWindowSurface::~CEGLWindowSurface(void) |
68 CEGLWindowSurface::~CEGLWindowSurface(void) |
69 { |
69 { |
70 #if !defined(EGLI_USE_PLATSIM_EXTENSIONS) |
70 #if !defined(EGLI_USE_SIMULATOR_EXTENSIONS) |
71 if( m_currentBuffer ) free( m_currentBuffer ); |
71 if( m_currentBuffer ) free( m_currentBuffer ); |
72 #endif |
72 #endif |
73 if( m_osContext ) |
73 if( m_osContext ) |
74 CEGLOs::DestroyOSWindowContext( m_osContext ); |
74 CEGLOs::DestroyOSWindowContext( m_osContext ); |
75 } |
75 } |
76 |
76 |
77 void* CEGLWindowSurface::CurrentBuffer() |
77 void* CEGLWindowSurface::CurrentBuffer() |
78 { |
78 { |
79 #if defined(EGLI_USE_PLATSIM_EXTENSIONS) |
79 #if defined(EGLI_USE_SIMULATOR_EXTENSIONS) |
80 m_currentBuffer = (m_currentBuffer && m_currentBuffer == m_buffer0) ? m_buffer1 : m_buffer0; |
80 m_currentBuffer = (m_currentBuffer && m_currentBuffer == m_buffer0) ? m_buffer1 : m_buffer0; |
81 EGLI_ASSERT( m_currentBuffer != NULL ); |
81 EGLI_ASSERT( m_currentBuffer != NULL ); |
82 return m_currentBuffer; |
82 return m_currentBuffer; |
83 #else |
83 #else |
84 if( !m_currentBuffer || m_osContext->width != Width() || m_osContext->height != Height() ) |
84 if( !m_currentBuffer || m_osContext->width != Width() || m_osContext->height != Height() ) |