Skip to content

PythonQt.QtGui.QSurfaceFormat · declarations 002

Back to PythonQt.QtGui.QSurfaceFormat

setOptions

setOptions(options: Any) -> None

X.setOptions(options)

Supplemental documentation: Qt 5 reference:

void QSurfaceFormat::setOptions(QSurfaceFormat::FormatOptions options)

Sets the format options to options.

This function was introduced in Qt 5.3.

See also options() and testOption().

Upstream PySide2 reference signatures (binding differences may apply):

setOptions(self, options: PySide2.QtGui.QSurfaceFormat.FormatOptions) -> None

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#setOptions

setProfile

setProfile(profile: Any) -> None

X.setProfile(profile)

Supplemental documentation: Qt 5 reference:

void QSurfaceFormat::setProfile(QSurfaceFormat::OpenGLContextProfile profile)

Sets the desired OpenGL context profile.

This setting is ignored if the requested OpenGL version is less than 3.2.

See also profile().

Upstream PySide2 reference signatures (binding differences may apply):

setProfile(self, profile: PySide2.QtGui.QSurfaceFormat.OpenGLContextProfile) -> None

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#setProfile

setRedBufferSize

setRedBufferSize(size: int) -> None

X.setRedBufferSize(size)

Supplemental documentation: Qt 5 reference:

void QSurfaceFormat::setRedBufferSize(int size)

Set the desired size in bits of the red channel of the color buffer.

See also redBufferSize().

Upstream PySide2 reference signatures (binding differences may apply):

setRedBufferSize(self, size: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#setRedBufferSize

setRenderableType

setRenderableType(type: Any) -> None

X.setRenderableType(type)

Supplemental documentation: Qt 5 reference:

void QSurfaceFormat::setRenderableType(QSurfaceFormat::RenderableType type)

Sets the desired renderable type.

Chooses between desktop OpenGL, OpenGL ES, and OpenVG.

See also renderableType().

Upstream PySide2 reference signatures (binding differences may apply):

setRenderableType(self, type: PySide2.QtGui.QSurfaceFormat.RenderableType) -> None

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#setRenderableType

setSamples

setSamples(numSamples: int) -> None

X.setSamples(numSamples)

Supplemental documentation: Qt 5 reference:

void QSurfaceFormat::setSamples(int numSamples)

Set the preferred number of samples per pixel when multisampling is enabled to numSamples. By default, multisampling is disabled.

See also samples().

Upstream PySide2 reference signatures (binding differences may apply):

setSamples(self, numSamples: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#setSamples

setStencilBufferSize

setStencilBufferSize(size: int) -> None

X.setStencilBufferSize(size)

Supplemental documentation: Qt 5 reference:

void QSurfaceFormat::setStencilBufferSize(int size)

Set the preferred stencil buffer size to size bits.

See also stencilBufferSize().

Upstream PySide2 reference signatures (binding differences may apply):

setStencilBufferSize(self, size: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#setStencilBufferSize

setStereo

setStereo(enable: bool) -> None

X.setStereo(enable)

Supplemental documentation: Qt 5 reference:

void QSurfaceFormat::setStereo(bool enable)

If enable is true enables stereo buffering; otherwise disables stereo buffering.

Stereo buffering is disabled by default.

Stereo buffering provides extra color buffers to generate left-eye and right-eye images.

See also stereo().

Upstream PySide2 reference signatures (binding differences may apply):

setStereo(self, enable: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#setStereo

setSwapBehavior

setSwapBehavior(behavior: Any) -> None

X.setSwapBehavior(behavior)

Supplemental documentation: Qt 5 reference:

void QSurfaceFormat::setSwapBehavior(QSurfaceFormat::SwapBehavior behavior)

Set the swap behavior of the surface.

The swap behavior specifies whether single, double, or triple buffering is desired. The default, DefaultSwapBehavior, gives the default swap behavior of the platform.

See also swapBehavior().

Upstream PySide2 reference signatures (binding differences may apply):

setSwapBehavior(self, behavior: PySide2.QtGui.QSurfaceFormat.SwapBehavior) -> None

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#setSwapBehavior

setSwapInterval

setSwapInterval(interval: int) -> None

X.setSwapInterval(interval)

Supplemental documentation: Qt 5 reference:

void QSurfaceFormat::setSwapInterval(int interval)

Sets the preferred swap interval. The swap interval specifies the minimum number of video frames that are displayed before a buffer swap occurs. This can be used to sync the GL drawing into a window to the vertical refresh of the screen.

Setting an interval value of 0 will turn the vertical refresh syncing off, any value higher than 0 will turn the vertical syncing on. Setting interval to a higher value, for example 10, results in having 10 vertical retraces between every buffer swap.

The default interval is 1.

Changing the swap interval may not be supported by the underlying platform. In this case, the request will be silently ignored.

This function was introduced in Qt 5.3.

See also swapInterval().

Upstream PySide2 reference signatures (binding differences may apply):

setSwapInterval(self, interval: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#setSwapInterval

setVersion

setVersion(major: int, minor: int) -> None

X.setVersion(major, minor)

Supplemental documentation: Qt 5 reference:

void QSurfaceFormat::setVersion(int major, int minor)

Sets the desired major and minor OpenGL versions.

The default version is 2.0.

See also version().

Upstream PySide2 reference signatures (binding differences may apply):

setVersion(self, major: int, minor: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#setVersion

stencilBufferSize

stencilBufferSize() -> int

X.stencilBufferSize() -> int

Supplemental documentation: Qt 5 reference:

int QSurfaceFormat::stencilBufferSize() const

Returns the stencil buffer size in bits.

See also setStencilBufferSize().

Upstream PySide2 reference signatures (binding differences may apply):

stencilBufferSize(self) -> int

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#stencilBufferSize

stereo

stereo() -> bool

X.stereo() -> bool

Supplemental documentation: Qt 5 reference:

bool QSurfaceFormat::stereo() const

Returns true if stereo buffering is enabled; otherwise returns false. Stereo buffering is disabled by default.

See also setStereo().

Upstream PySide2 reference signatures (binding differences may apply):

stereo(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#stereo

swapBehavior

swapBehavior() -> Any

X.swapBehavior()

Supplemental documentation: Qt 5 reference:

QSurfaceFormat::SwapBehavior QSurfaceFormat::swapBehavior() const

Returns the configured swap behaviour.

See also setSwapBehavior().

Upstream PySide2 reference signatures (binding differences may apply):

swapBehavior(self) -> PySide2.QtGui.QSurfaceFormat.SwapBehavior

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#swapBehavior

swapInterval

swapInterval() -> int

X.swapInterval() -> int

Supplemental documentation: Qt 5 reference:

int QSurfaceFormat::swapInterval() const

Returns the swap interval.

This function was introduced in Qt 5.3.

See also setSwapInterval().

Upstream PySide2 reference signatures (binding differences may apply):

swapInterval(self) -> int

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#swapInterval

testOption

testOption(opt: Any) -> bool

X.testOption(opt) -> bool

Supplemental documentation: Qt 5 reference:

bool QSurfaceFormat::testOption(QSurfaceFormat::FormatOption option) const

Returns true if the format option option is set; otherwise returns false.

This function was introduced in Qt 5.3.

See also options().

Upstream PySide2 reference signatures (binding differences may apply):

testOption(self, opt: PySide2.QtGui.QSurfaceFormat.FormatOptions) -> bool
testOption(self, option: PySide2.QtGui.QSurfaceFormat.FormatOption) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#testOption

version

version() -> Any

X.version()

Supplemental documentation: Qt 5 reference:

QPair\<int, int> QSurfaceFormat::version() const

Returns a QPair\<int, int> representing the OpenGL version.

Useful for version checks, for example format.version() >\= qMakePair(3, 2)

See also setVersion().

Upstream PySide2 reference signatures (binding differences may apply):

version(self) -> typing.Tuple[int, int]

Source: https://doc.qt.io/archives/qt-5.15/qsurfaceformat.html#version