QGLXContext Struct

struct QNativeInterface::QGLXContext

Native Schnittstelle zu einem GLX-Kontext. Mehr...

Kopfzeile: #include <QOpenGLContext>
CMake: find_package(Qt6 REQUIRED COMPONENTS Gui)
target_link_libraries(mytarget PRIVATE Qt6::Gui)
qmake: QT += gui
Seit: Qt 6.0

Öffentliche Funktionen

int nativeContext() const

Statische öffentliche Mitglieder

QOpenGLContext *fromNative(int configBasedContext, QOpenGLContext *shareContext = nullptr)
QOpenGLContext *fromNative(int visualBasedContext, void *visualInfo, QOpenGLContext *shareContext = nullptr)

Detaillierte Beschreibung

Zu erreichen über QOpenGLContext::nativeInterface().

Dokumentation der Mitgliedsfunktionen

[static] QOpenGLContext *QGLXContext::fromNative(int configBasedContext, QOpenGLContext *shareContext = nullptr)

Übernimmt einen GLXContext configBasedContext, der aus einer FBConfig erstellt wurde.

Der Kontext muss mit der Funktion glXCreateNewContext aus einer Framebuffer-Konfiguration erstellt werden.

Das Eigentum an dem erstellten QOpenGLContext shareContext wird an den Aufrufer übertragen.

[static] QOpenGLContext *QGLXContext::fromNative(int visualBasedContext, void *visualInfo, QOpenGLContext *shareContext = nullptr)

Übernimmt einen GLXContext, der aus einem X-Visual erstellt wurde.

Der Kontext muss aus einem Bildmaterial mit der Funktion glXCreateContext erstellt werden. Das gleiche Bildmaterial muss als Zeiger auf eine XVisualInfo -Struktur im Argument visualInfo übergeben werden.

Das Eigentum an dem erstellten QOpenGLContext wird an den Aufrufer übertragen.

int QGLXContext::nativeContext() const

Gibt den zugrunde liegenden GLXContext zurück.

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.