Movatterモバイル変換


[0]ホーム

URL:


We bake cookies in your browser for a better experience. Using this site means that you consent.Read More

Menu

Qt Documentation

QGLFramebufferObjectFormat Class

TheQGLFramebufferObjectFormat class specifies the format of anOpenGL framebuffer object.More...

Header:#include <QGLFramebufferObjectFormat>
Since: Qt 4.6

Public Functions

QGLFramebufferObjectFormat()
QGLFramebufferObjectFormat(const QGLFramebufferObjectFormat & other)
~QGLFramebufferObjectFormat()
QGLFramebufferObject::Attachmentattachment() const
GLenuminternalTextureFormat() const
boolmipmap() const
intsamples() const
voidsetAttachment(QGLFramebufferObject::Attachment attachment)
voidsetInternalTextureFormat(GLenum internalTextureFormat)
voidsetMipmap(bool enabled)
voidsetSamples(int samples)
voidsetTextureTarget(GLenum target)
GLenumtextureTarget() const
booloperator!=(const QGLFramebufferObjectFormat & other) const
QGLFramebufferObjectFormat &operator=(const QGLFramebufferObjectFormat & other)
booloperator==(const QGLFramebufferObjectFormat & other) const

Detailed Description

TheQGLFramebufferObjectFormat class specifies the format of anOpenGL framebuffer object.

A framebuffer object has several characteristics:

Note that the desired attachments or number of samples per pixels might not be supported by the hardware driver. CallQGLFramebufferObject::format() after creating aQGLFramebufferObject to find the exact format that was used to create the frame buffer object.

See alsoQGLFramebufferObject.

Member Function Documentation

QGLFramebufferObjectFormat::QGLFramebufferObjectFormat()

Creates aQGLFramebufferObjectFormat object for specifying the format of anOpenGL framebuffer object.

By default the format specifies a non-multisample framebuffer object with no attachments, texture targetGL_TEXTURE_2D, and internal formatGL_RGBA8. OnOpenGL/ES systems, the default internal format isGL_RGBA.

See alsosamples(),attachment(), andinternalTextureFormat().

QGLFramebufferObjectFormat::QGLFramebufferObjectFormat(constQGLFramebufferObjectFormat & other)

Constructs a copy ofother.

QGLFramebufferObjectFormat::~QGLFramebufferObjectFormat()

Destroys theQGLFramebufferObjectFormat.

QGLFramebufferObject::Attachment QGLFramebufferObjectFormat::attachment() const

Returns the configuration of the depth and stencil buffers attached to a framebuffer object. The default isQGLFramebufferObject::NoAttachment.

See alsosetAttachment().

GLenum QGLFramebufferObjectFormat::internalTextureFormat() const

Returns the internal format of a framebuffer object's texture or multisample framebuffer object's color buffer. The default isGL_RGBA8 on desktopOpenGL systems, andGL_RGBA onOpenGL/ES systems.

See alsosetInternalTextureFormat().

bool QGLFramebufferObjectFormat::mipmap() const

Returns true if mipmapping is enabled.

This function was introduced in Qt 4.8.

See alsosetMipmap().

int QGLFramebufferObjectFormat::samples() const

Returns the number of samples per pixel if a framebuffer object is a multisample framebuffer object. Otherwise, returns 0. The default value is 0.

See alsosetSamples().

void QGLFramebufferObjectFormat::setAttachment(QGLFramebufferObject::Attachment attachment)

Sets the attachment configuration of a framebuffer object toattachment.

See alsoattachment().

void QGLFramebufferObjectFormat::setInternalTextureFormat(GLenum internalTextureFormat)

Sets the internal format of a framebuffer object's texture or multisample framebuffer object's color buffer tointernalTextureFormat.

See alsointernalTextureFormat().

void QGLFramebufferObjectFormat::setMipmap(bool enabled)

Enables mipmapping ifenabled is true; otherwise disables it.

Mipmapping is disabled by default.

If mipmapping is enabled, additional memory will be allocated for the mipmap levels. The mipmap levels can be updated by binding the texture and calling glGenerateMipmap(). Mipmapping cannot be enabled for multisampled framebuffer objects.

This function was introduced in Qt 4.8.

See alsomipmap() andQGLFramebufferObject::texture().

void QGLFramebufferObjectFormat::setSamples(int samples)

Sets the number of samples per pixel for a multisample framebuffer object tosamples. The default sample count of 0 represents a regular non-multisample framebuffer object.

If the desired amount of samples per pixel is not supported by the hardware then the maximum number of samples per pixel will be used. Note that multisample framebuffer objects can not be bound as textures. Also, theGL_EXT_framebuffer_multisample extension is required to create a framebuffer with more than one sample per pixel.

See alsosamples().

void QGLFramebufferObjectFormat::setTextureTarget(GLenum target)

Sets the texture target of the texture attached to a framebuffer object totarget. Ignored for multisample framebuffer objects.

See alsotextureTarget() andsamples().

GLenum QGLFramebufferObjectFormat::textureTarget() const

Returns the texture target of the texture attached to a framebuffer object. Ignored for multisample framebuffer objects. The default isGL_TEXTURE_2D.

See alsosetTextureTarget() andsamples().

bool QGLFramebufferObjectFormat::operator!=(constQGLFramebufferObjectFormat & other) const

Returns false if all the options of this framebuffer object format are the same asother; otherwise returns true.

QGLFramebufferObjectFormat & QGLFramebufferObjectFormat::operator=(constQGLFramebufferObjectFormat & other)

Assignsother to this object.

bool QGLFramebufferObjectFormat::operator==(constQGLFramebufferObjectFormat & other) const

Returns true if all the options of this framebuffer object format are the same asother; otherwise returns false.

© 2016 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 theGNU 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.


[8]ページ先頭

©2009-2025 Movatter.jp