Cygwin fixes

This commit is contained in:
ehofman
2005-01-31 18:07:40 +00:00
parent 8ed96cad1d
commit 9ab77d65f4

View File

@@ -254,7 +254,7 @@ void PrintExtensionError( char* strMsg, ... )
char strBuffer[512];
va_list args;
va_start(args, strMsg);
#ifdef _WIN32
#if defined _WIN32 && !defined __CYGWIN__
_vsnprintf( strBuffer, 512, strMsg, args );
#else
vsnprintf( strBuffer, 512, strMsg, args );
@@ -264,6 +264,7 @@ void PrintExtensionError( char* strMsg, ... )
fprintf(stderr, strMsg);
}
//---------------------------------------------------------------------------
// Function : RenderTexture::Initialize
// Description :
@@ -294,7 +295,7 @@ bool RenderTexture::Initialize(int width, int height,
if (_bInitialized)
_Invalidate();
#if _WIN32
#ifdef _WIN32
// Get the current context.
HDC hdc = wglGetCurrentDC();
if (NULL == hdc)
@@ -582,7 +583,7 @@ bool RenderTexture::_Invalidate()
glDeleteTextures(1, &_iDepthTextureID);
}
#if _WIN32
#ifdef _WIN32
if ( _hPBuffer )
{
// Check if we are currently rendering in the pbuffer
@@ -675,7 +676,7 @@ bool RenderTexture::Reset(const char *strMode, ...)
va_list args;
char strBuffer[256];
va_start(args,strMode);
#ifdef _WIN32
#if defined _WIN32 && !defined __CYGWIN__
_vsnprintf( strBuffer, 256, strMode, args );
#else
vsnprintf( strBuffer, 256, strMode, args );
@@ -953,7 +954,7 @@ bool RenderTexture::BindBuffer( int iBuffer )
{
glBindTexture(_iTextureTarget, _iTextureID);
#if _WIN32
#ifdef _WIN32
if (RT_RENDER_TO_TEXTURE == _eUpdateMode && _bIsTexture &&
(!_bIsBufferBound || _iCurrentBoundBuffer != iBuffer))
{