View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000669VTK(No Category)public2004-03-10 17:182011-01-13 17:00
ReporterAlex 
Assigned ToMathieu Malaterre 
PrioritynormalSeveritymajorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0000669: Exception in vtkWin32OpenGLRenderWindow::MakeCurrent
DescriptionI developed ActiveX control using VTK and after the container form is closed, I always get an exception.

I traced it do the following code in the vtkWin32OpenGLRenderWindow::MakeCurrent()
if (wglMakeCurrent(this->DeviceContext, this->ContextId) != TRUE)
        {
        LPVOID lpMsgBuf;
        ::FormatMessage(
          FORMAT_MESSAGE_ALLOCATE_BUFFER |
          FORMAT_MESSAGE_FROM_SYSTEM |
          FORMAT_MESSAGE_IGNORE_INSERTS,
          NULL,
          GetLastError(),
          MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), // Default language
          (LPTSTR) &lpMsgBuf,
          0,
          NULL
          );

       vtkErrorMacro("wglMakeCurrent failed in MakeCurrent(), error: "
                      << (LPCTSTR)lpMsgBuf); The reason for the excaption is that FormatMessage fails and the lpMsgBuf is NULL.
The FormatMessage failed because "The system cannot find message text for message number 0x%1 in the message file for %2."

The possible solution will be to check the result of FormatMessage
TagsNo tags attached.
Project
Type
Attached Files

 Relationships

  Notes
(0000756)
Mathieu Malaterre (developer)
2004-03-10 18:41

Alexf, thanks for report. This has been fixed in the CVS only as we don't officially support ActiveX. You can apply those change to your local VTK build.

 Issue History
Date Modified Username Field Change
2010-11-29 17:59 Mathieu Malaterre Source_changeset_attached => VTK master f091ce77
2011-01-13 17:00 Source_changeset_attached => VTK master a2bd8391
2011-01-13 17:00 Source_changeset_attached => VTK master 020ef709
2011-06-16 13:11 Zack Galbreath Category => (No Category)


Copyright © 2000 - 2018 MantisBT Team