Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

QOpenGLContext::functions(), the d-pointer is null (was QScopedPointer exception) #8209

Closed
271812697 opened this issue May 16, 2024 · 5 comments
Assignees
Milestone

Comments

@271812697
Copy link

Please use the following template to help us solving your issue.

Issue Details

I build CGAL with Cmake,After building, all project concerning with Qt will appear exception,for example when i run AABB_demo, an exception occurs as follow

Picture

异常

Environment

  • Operating system (Windows/Mac/Linux, 32/64 bits):
  • Compiler:
  • Release or debug mode:
  • Specific flags used (if any):
  • CGAL version:
  • Boost version:
  • Other libraries versions if used (Eigen, TBB, etc.):
@lrineau
Copy link
Member

lrineau commented May 17, 2024

Hi buranya (@271812697), from what I can see, and guess, from your issue report, the error is probably on your side. It seems you generated a Visual Studio project, using CMake, as it should be. Probably from CGAL-5.6.1, but I am not sure.

We need the following information, to help you:

Environment

  • Operating system (Windows/Mac/Linux, 32/64 bits): It seems to be Windows. 32 or 64 bits?
  • Compiler: probably Visual C++, right? Which version of Visual Studio, and which compiler toolkit?
  • Release or debug mode: ?
  • Specific flags used (if any): unless you specified additional flags yourself, forget this.
  • CGAL version: CGAL-5.6.1, please confirm
  • Boost version:
  • Other libraries versions if used (Eigen, TBB, etc.): please tell us which Qt version

@271812697
Copy link
Author

Thank you so much,I compile CGAL with following environment:

Environment

  • Operation system(Windows,64 bits)
  • Compiler:Visual C++,Visual Studio 2022
  • Debug
  • Specific flags used: use CMake GUI'default settings,with demo selected,with examples selected
  • CGAL verison:CGAL-5.6.1
  • Boost version:1.7.2
  • Other libraries version:Qt 6.7.0

The projects concerning with Qt compile successfully,but will occur exception,the stack is as following:
image
image

image

@lrineau
Copy link
Member

lrineau commented May 21, 2024

@CGAL/geometryfactory I see in the stack of the error that it is probably QOpenGLContext::functions() that is called on an QOpenGLContext that is not correctly initialized (because its d-pointer is null).

@271812697 It seems to be related to your OpenGL driver, and the way the CGAL application does not initialize the Qt6 OpenGL support correct. Do you have a way to tell us more about your OpenGL driver?

  • What is the graphic card?
  • What is the driver, and its version?
  • And if you manage to know, the list of versions of OpenGL that the driver supports?

That would help us.

@lrineau lrineau changed the title QScopedPointer exception QOpenGLContext::functions(), the d-pointer is null (was QScopedPointer exception) May 21, 2024
@lrineau lrineau added this to the 5.6.2 milestone May 21, 2024
@lrineau
Copy link
Member

lrineau commented May 21, 2024

@271812697 Thanks for the information. There is an issue, though: you mention that you are use CGAL-5.6.1, and Qt-6.7.0. However, CGAL-5.6.1 is not compatible with Qt6, but only with Qt5. Can you please verify?

@271812697
Copy link
Author

Thank you so much,as you say, This exception is indeed caused by the incompatibility of the Qt version.
When I changed the Qt version, the problem was solved!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants