18 #ifndef ION_GFX_CUBEMAPTEXTURE_H_
19 #define ION_GFX_CUBEMAPTEXTURE_H_
40 kNegativeYMipmapChanged = kNegativeXMipmapChanged + kMipmapSlotCount,
41 kNegativeZMipmapChanged = kNegativeYMipmapChanged + kMipmapSlotCount,
42 kPositiveXMipmapChanged = kNegativeZMipmapChanged + kMipmapSlotCount,
43 kPositiveYMipmapChanged = kPositiveXMipmapChanged + kMipmapSlotCount,
44 kPositiveZMipmapChanged = kPositiveYMipmapChanged + kMipmapSlotCount,
45 kNumChanges = kPositiveZMipmapChanged + kMipmapSlotCount
62 if (GetImmutableImage().Get())
63 LOG(
ERROR) <<
"ION: SetImage() called on immutable texture \""
65 <<
"\". Use SetSubImage() to update an immutable texture.";
67 faces_[face].SetImage(level, image,
this);
70 return faces_[face].HasImage(level);
73 return faces_[face].GetImage(level);
76 return faces_[face].GetImageCount();
80 faces_[face].SetSubImage(level, offset, image);
84 faces_[face].SetSubImage(level, offset, image);
87 return faces_[face].GetSubImages();
90 faces_[face].ClearSubImages();
120 #endif // ION_GFX_CUBEMAPTEXTURE_H_
const base::AllocVector< SubImage > & GetSubImages(CubeFace face) const
#define LOG(severity)
Logs the streamed message unconditionally with a severity of severity.
A Notifier both sends notifications to and receives notifications from other Notifiers.
base::ReferentPtr< CubeMapTexture >::Type CubeMapTexturePtr
Convenience typedef for shared pointer to a CubeMapTexture.
CubeFace
The names of faces of the cube map.
Changes
Changes that affect this resource.
void SetSubImage(CubeFace face, size_t level, const math::Point3ui offset, const ImagePtr &image)
void ClearSubImages(CubeFace face) const
const Grid & image
The original monochrome image data, as doubles (0 - 1).
size_t GetImageCount(CubeFace face) const
void SetImage(CubeFace face, size_t level, const ImagePtr &image)
See comments in TextureBase::Face.
void SetSubImage(CubeFace face, size_t level, const math::Point2ui offset, const ImagePtr &image)
This is an internal base class for all texture types.
A CubeMapTexture object represents the image data and mipmaps associated with the six faces of a cube...
bool HasImage(CubeFace face, size_t level) const
A SharedPtr is a smart shared pointer to an instance of some class that implements reference counting...
This class can be used in place of std::vector to allow an Ion Allocator to be used for memory alloca...
const ImagePtr GetImage(CubeFace face, size_t level) const