summaryrefslogtreecommitdiff
path: root/win/Print.cpp
diff options
context:
space:
mode:
authorleo2000-12-18 12:42:31 +0000
committerleo2000-12-18 12:42:31 +0000
commit9f945b3fe2361205ba6a58f92dc976ded7bccb60 (patch)
tree54db9efd1c083ac06128e4f9d8f1f4e2044d832c /win/Print.cpp
parente679694a7bcb61ffee8351bad0396944716b81d4 (diff)
Fixes for win2k crash
git-svn-id: http://svn.leocad.org/trunk@183 c7d43263-9d01-0410-8a33-9dba5d9f93d6
Diffstat (limited to 'win/Print.cpp')
-rw-r--r--win/Print.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/win/Print.cpp b/win/Print.cpp
index 2c62f80..03a3753 100644
--- a/win/Print.cpp
+++ b/win/Print.cpp
@@ -179,9 +179,9 @@ static void PrintCatalogThread (CWnd* pParent, CFrameWnd* pMainFrame)
1,PFD_DRAW_TO_BITMAP | PFD_SUPPORT_OPENGL | PFD_SUPPORT_GDI,
PFD_TYPE_RGBA, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16,
0, 0, PFD_MAIN_PLANE, 0, 0, 0, 0 };
- int pixelformat = pfnwglChoosePixelFormat(pMemDC->m_hDC, &pfd);
- pfnwglDescribePixelFormat(pMemDC->m_hDC, pixelformat, sizeof(PIXELFORMATDESCRIPTOR), &pfd);
- pfnwglSetPixelFormat(pMemDC->m_hDC, pixelformat, &pfd);
+ int pixelformat = OpenGLChoosePixelFormat(pMemDC->m_hDC, &pfd);
+ OpenGLDescribePixelFormat(pMemDC->m_hDC, pixelformat, sizeof(PIXELFORMATDESCRIPTOR), &pfd);
+ OpenGLSetPixelFormat(pMemDC->m_hDC, pixelformat, &pfd);
// Creating a OpenGL context
HGLRC hmemrc = pfnwglCreateContext(pMemDC->GetSafeHdc());
@@ -563,9 +563,9 @@ static void PrintPiecesThread(void* pv)
PIXELFORMATDESCRIPTOR pfd = { sizeof(PIXELFORMATDESCRIPTOR),1,PFD_DRAW_TO_BITMAP | PFD_SUPPORT_OPENGL | PFD_SUPPORT_GDI,
PFD_TYPE_RGBA, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, PFD_MAIN_PLANE, 0, 0, 0, 0 };
- int pixelformat = pfnwglChoosePixelFormat(pMemDC->m_hDC, &pfd);
- pfnwglDescribePixelFormat(pMemDC->m_hDC, pixelformat, sizeof(PIXELFORMATDESCRIPTOR), &pfd);
- pfnwglSetPixelFormat(pMemDC->m_hDC, pixelformat, &pfd);
+ int pixelformat = OpenGLChoosePixelFormat(pMemDC->m_hDC, &pfd);
+ OpenGLDescribePixelFormat(pMemDC->m_hDC, pixelformat, sizeof(PIXELFORMATDESCRIPTOR), &pfd);
+ OpenGLSetPixelFormat(pMemDC->m_hDC, pixelformat, &pfd);
HGLRC hmemrc = pfnwglCreateContext(pMemDC->GetSafeHdc());
pfnwglMakeCurrent(pMemDC->GetSafeHdc(), hmemrc);
double aspect = (float)picw/(float)h;