17 INLINE TextureContext::
85 return _properties_modified;
94 return _image_modified;
103 return _simple_image_modified;
139 update_modified(std::max(_properties_modified, _simple_image_modified));
150 _properties_modified = UpdateSeq::old();
151 _image_modified = UpdateSeq::old();
152 _simple_image_modified = UpdateSeq::old();
164 _image_modified = UpdateSeq::old();
Texture * get_texture() const
Returns the pointer to the associated Texture object.
bool was_image_modified() const
Returns true if the texture image has been modified since the last time mark_loaded() was called.
UpdateSeq get_simple_image_modified() const
Returns a sequence number which is guaranteed to change at least every time the texture's "simple" im...
int get_view() const
Returns the specific view of a multiview texture this context represents.
bool was_properties_modified() const
Returns true if the texture properties (unrelated to the image) have been modified since the last tim...
This is a base class for those kinds of SavedContexts that occupy an easily-measured (and substantial...
Represents a texture object, which is typically a single 2-d image but may also represent a 1-d or 3-...
void set_lru_size(size_t lru_size)
Specifies the size of this page, presumably in bytes, although any unit is possible.
get_properties_modified
Returns a sequence number which is guaranteed to change at least every time the texture properties (u...
void mark_needs_reload()
Should be called to indicate the texture should be reloaded at the nearest opportunity.
UpdateSeq get_image_modified() const
Returns a sequence number which is guaranteed to change at least every time the texture image data (i...
bool was_simple_image_modified() const
Returns true if the texture's "simple" image has been modified since the last time mark_simple_loaded...
A table of objects that are saved within the graphics context for reference by handle later.
UpdateSeq get_properties_modified() const
Returns a sequence number which is guaranteed to change at least every time the texture properties (u...
void update_data_size_bytes(size_t new_data_size_bytes)
Should be called (usually by a derived class) when the on-card size of this object has changed.
void set_resident(bool flag)
Changes the resident flag associated with this object.
One atomic piece that may be managed by a AdaptiveLru chain.
void update_data_size_bytes(size_t new_data_size_bytes)
Should be called (usually by a derived class) when the on-card size of this object has changed.
void mark_loaded()
Should be called after the texture has been loaded into graphics memory, this updates the internal fl...
get_image_modified
Returns a sequence number which is guaranteed to change at least every time the texture image data (i...
get_simple_image_modified
Returns a sequence number which is guaranteed to change at least every time the texture's "simple" im...
void update_modified(UpdateSeq new_modified)
Should be called (usually by a derived class) when the modified counter for this object has changed.
void mark_unloaded()
Should be called after the texture has been forced out of texture memory.
This is a sequence number that increments monotonically.
void mark_simple_loaded()
Should be called after the texture's "simple" image has been loaded into graphics memory.
bool was_modified() const
Returns true if the texture properties or image have been modified since the last time mark_loaded() ...