diff options
Diffstat (limited to 'indra/llrender/llcubemap.h')
| -rw-r--r-- | indra/llrender/llcubemap.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/indra/llrender/llcubemap.h b/indra/llrender/llcubemap.h index 9ce4a94bca..b9e081cea3 100644 --- a/indra/llrender/llcubemap.h +++ b/indra/llrender/llcubemap.h @@ -41,11 +41,15 @@ public: LLCubeMap(bool init_as_srgb); void init(const std::vector<LLPointer<LLImageRaw> >& rawimages); + // initialize as an undefined cubemap at the given resolution + // used for render-to-cubemap operations + // avoids usage of LLImageRaw + void initReflectionMap(U32 resolution, U32 components = 3); + // init from environment map images // Similar to init, but takes ownership of rawimages and makes this cubemap // respect the resolution of rawimages // Raw images must point to array of six square images that are all the same resolution - // For example usage, see LLEnvironmentMap void initEnvironmentMap(const std::vector<LLPointer<LLImageRaw> >& rawimages); void initGL(); void initRawData(const std::vector<LLPointer<LLImageRaw> >& rawimages); @@ -62,6 +66,12 @@ public: void setMatrix(S32 stage); void restoreMatrix(); + U32 getResolution() { return mImages[0].notNull() ? mImages[0]->getWidth(0) : 0; } + + // generate mip maps for this Cube Map using GL + // NOTE: Cube Map MUST already be resident in VRAM + void generateMipMaps(); + GLuint getGLName(); void destroyGL(); |
