|
ImageId | nextImageId () |
| Get the next dyname ImageId.
|
|
void | setImage (ImageId imageId, gm::Texture &&texture) |
| Set, or reset the Texture associated with the ImageId.
|
|
bool | exists (ImageId imageId) |
| Test to see if a Texture is associated with an ImageId.
|
|
Size | size (ImageId imageId) |
| Get the size of the Texture associated with an ImageId. More...
|
|
int | renderCopy (gm::Context &context, ImageId imageId, Rectangle dst) |
| Render the Texture associated with an Image Id. More...
|
|
int | renderCopy (gm::Context &context, ImageId imageId, Rectangle src, Rectangle dst) |
| Render the Texture associated with an Image Id. More...
|
|
int | renderCopyEx (gm::Context &context, ImageId imageId, Rectangle src, Rectangle dst, double angle, gm::RenderFlip flip) |
| Render the Texture associated with an Image Id with with optional rotation and flipping. More...
|
|
|
void | createIcon (gm::Context &context, IconImage iconImage) |
| Create an Icon using the Entypo font.
|
|
template<typename Iterator > |
void | createIcons (gm::Context &context, Iterator first, Iterator last) |
| Create many Icons using a container of IconImage structures.
|
|
void | initialize (gm::Context &context) |
| Initialize the ImageStore.
|
|
void | createSquareCorners (gm::Context &context, int radius, int borderWidth, color::RGBA top, color::RGBA bot, color::RGBA left, color::RGBA right) |
|
void | createRoundCorners (gm::Context &context, int scale, int radius, int borderWidth, color::RGBA top, color::RGBA bot, color::RGBA left, color::RGBA right) |
|
void | createCenters (gm::Context &context, int scale, int radius) |
|
|
bool | mInitialized {false} |
| True after initialization.
|
|
int | mNextImageId {static_cast<int>(ImageId::DynamicIdStart)} |
| The next ImageId for storage of dynamic images.
|
|
std::map< ImageId, gm::Texture > | mImageMap {} |
| The Texture storage map.
|
|
◆ getStore() [1/2]
◆ getStore() [2/2]
Get access to, and initialize, the Singleton ImageStore.
This must be called by the application after the GraphicModel and Context have been initialized but before any access to the image storage.
- Parameters
-
context | The graphics Context used to create some icons. |
- Returns
- A reference to the ImageStore.
◆ renderCopy() [1/2]
Render the Texture associated with an Image Id.
The source rectangle is set to the full Texture,
- Parameters
-
context | The Context to use. |
imageId | The ImageId. |
dst | The destination Rectangle. |
- Returns
- The return status code from the SDL API.
◆ renderCopy() [2/2]
Render the Texture associated with an Image Id.
- Parameters
-
context | The Context to use. |
imageId | The ImageId. |
src | The source Rectangel. |
dst | The destination Rectangle. |
- Returns
- The return status code from the SDL API.
◆ renderCopyEx()
Render the Texture associated with an Image Id with with optional rotation and flipping.
- Parameters
-
context | The Context to use. |
imageId | The Id of the image in the ImageStore. |
src | The source Rectangle. |
dst | The destination Rectangle. |
angle | The rotation Angle. |
flip | Flipping parameters |
- Returns
- The return status code from the SDL API.
◆ size()
Size rose::ImageStore::size |
( |
ImageId |
imageId | ) |
|
|
inline |
Get the size of the Texture associated with an ImageId.
It is not an error for there to be no associated Texture. When this is the case Size::Zero is returned.
- Parameters
-
- Returns
- A Size object.
The documentation for this class was generated from the following files: