Документ взят из кэша поисковой машины. Адрес
оригинального документа
: http://astro.uni-altai.ru/~aw/stellarium/api/classStelQGLTextureBackend.html
Дата изменения: Unknown Дата индексирования: Fri Feb 28 07:48:38 2014 Кодировка: |
Stellarium 0.12.3
|
Texture backend based on QGL, usable with both GL1 and GL2. More...
#include <StelQGLTextureBackend.hpp>
Public Member Functions | |
~StelQGLTextureBackend () | |
Destroy the StelQGLTextureBackend. Must be called before the Renderer is destroyed. More... | |
void | bind (const int textureUnit) |
Called by QGLRenderer to bind the texture to specified texture unit. More... | |
void | startAsynchronousLoading () |
Start asynchrounously loading the texture in a separate thread. More... | |
Public Member Functions inherited from StelTextureBackend | |
virtual | ~StelTextureBackend () |
Destroy the texture. More... | |
TextureStatus | getStatus () const |
Get the current texture status. More... | |
const QString & | getName () const |
Get the "name" of this texture. More... | |
QSize | getDimensions () const |
Get texture dimensions in pixels. More... | |
const QString & | getErrorMessage () const |
Get a human-readable message describing the error that happened during loading (if any). More... | |
Static Public Member Functions | |
static StelQGLTextureBackend * | constructFromImage (class StelQGLRenderer *renderer, const QString &path, const TextureParams ¶ms, QImage &image) |
Construct a StelQGLTextureBackend from an image. More... | |
static StelQGLTextureBackend * | constructFromPVR (class StelQGLRenderer *renderer, const QString &path, const TextureParams ¶ms) |
Construct a StelQGLTextureBackend from a PVR (compressed texture on some mobile platforms) file. More... | |
static StelQGLTextureBackend * | constructAsynchronous (class StelQGLRenderer *renderer, const QString &path, const TextureParams ¶ms) |
Construct a StelQGLTextureBackend asynchronously (in a separate thread). More... | |
static StelQGLTextureBackend * | fromFBO (StelQGLRenderer *renderer, class QGLFramebufferObject *fbo) |
Construct a StelQGLTextureBackend from a framebuffer object. More... | |
static StelQGLTextureBackend * | fromViewport (StelQGLRenderer *renderer, const QSize viewportSize, const QGLFormat &viewportFormat) |
Construct a StelQGLTextureBackend from the viewport. More... | |
static StelQGLTextureBackend * | fromRawData (StelQGLRenderer *renderer, const void *data, const QSize size, const TextureDataFormat format, const TextureParams ¶ms) |
Construct a texture from raw data. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from StelTextureBackend | |
StelTextureBackend (const QString &path) | |
Construct a StelTextureBackend with specified texture path/url. More... | |
void | startedLoading () |
Must be called before loading an image (whether normally or asynchronously). More... | |
void | finishedLoading (const QSize dimensions) |
Must be called after succesfully loading an image (whether normally or asynchronously). More... | |
void | errorOccured (const QString &error) |
Must be called when an error occurs during loading. More... | |
Protected Attributes inherited from StelTextureBackend | |
const QString | path |
Full file system path or URL of the texture file. More... | |
Texture backend based on QGL, usable with both GL1 and GL2.
Definition at line 31 of file StelQGLTextureBackend.hpp.
StelQGLTextureBackend::~StelQGLTextureBackend | ( | ) |
Destroy the StelQGLTextureBackend. Must be called before the Renderer is destroyed.
void StelQGLTextureBackend::bind | ( | const int | textureUnit | ) |
Called by QGLRenderer to bind the texture to specified texture unit.
|
static |
Construct a StelQGLTextureBackend asynchronously (in a separate thread).
Will return a StelQGLTextureBackend in Uninitialized state - if not lazy loading, caller must start loading themselves.
renderer | Renderer this texture belongs to. |
path | Full path of image file in the file system (or a URL pointing to the image). |
params | Texture parameters (e.g. filtering, wrapping, etc.). |
|
static |
Construct a StelQGLTextureBackend from an image.
renderer | Renderer this texture belongs to. |
path | Full path of the image file in the filesystem. |
params | Texture parameters (e.g. filtering, wrapping, etc.). |
image | Image to load from. |
|
static |
Construct a StelQGLTextureBackend from a PVR (compressed texture on some mobile platforms) file.
This includes loading the texture from file, which might fail if the file does not exist, creating a texture with Error status.
renderer | Renderer this texture belongs to. |
path | Full path of the PVR image file in the filesystem. |
params | Texture parameters (e.g. filtering, wrapping, etc.). |
|
static |
Construct a StelQGLTextureBackend from a framebuffer object.
This will simply wrap a texture of a framebuffer object in a StelQGLTextureBackend and return it. The texture itself will still be owned by the framebuffer object, and destroyed with the framebuffer objects, not with the StelQGLTextureBackend.
renderer | Renderer this texture belongs to. |
fbo | Framebuffer object to get the texture from. |
|