mirror of
https://github.com/godotengine/godot.git
synced 2025-11-11 02:51:25 +00:00
2D: Fix CanvasTexture rendering when updating channels
This commit is contained in:
parent
b0655dc86f
commit
663917449b
4 changed files with 55 additions and 0 deletions
|
|
@ -485,9 +485,14 @@ class RendererCanvasRenderRD : public RendererCanvasRender {
|
|||
|
||||
static void _before_evict(RendererCanvasRenderRD::RIDSetKey &p_key, RID &p_rid);
|
||||
static void _uniform_set_invalidation_callback(void *p_userdata);
|
||||
static void _canvas_texture_invalidation_callback(bool p_deleted, void *p_userdata);
|
||||
|
||||
typedef LRUCache<RIDSetKey, RID, HashableHasher<RIDSetKey>, HashMapComparatorDefault<RIDSetKey>, _before_evict> RIDCache;
|
||||
RIDCache rid_set_to_uniform_set;
|
||||
/// Maps a CanvasTexture to its associated uniform sets, which must
|
||||
/// be invalidated when the CanvasTexture is updated, such as changing the
|
||||
/// diffuse texture.
|
||||
HashMap<RID, TightLocalVector<RID>> canvas_texture_to_uniform_set;
|
||||
|
||||
struct Batch {
|
||||
// Position in the UBO measured in bytes
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue