Blender V4.3
SeqCache Struct Reference

Public Attributes

Mainbmain
 
GHashhash
 
ThreadMutex iterator_mutex
 
BLI_mempoolkeys_pool
 
BLI_mempoolitems_pool
 
SeqCacheKeylast_key
 
SeqDiskCachedisk_cache
 

Detailed Description

Sequencer Cache Design Notes

Function: All images created during rendering are added to cache, even if the cache is already full. This is because:

  • One image may be needed multiple times during rendering.
  • Keeping the last rendered frame allows us for faster re-render when user edits strip in stack.
  • We can decide if we keep frame only when it's completely rendered. Otherwise we risk having "holes" in the cache, which can be annoying.

If the cache is full all entries for pending frame will have is_temp_cache set.

Linking: We use links to reduce number of iterations over entries needed to manage cache. Entries are linked in order as they are put into cache. Only permanent (is_temp_cache = 0) cache entries are linked. Putting SEQ_CACHE_STORE_FINAL_OUT will reset linking

Only entire frame can be freed to release resources for new entries (recycling). Once again, this is to reduce number of iterations, but also more controllable than removing entries one by one in reverse order to their creation.

User can exclude caching of some images. Such entries will have is_temp_cache set.

Definition at line 64 of file image_cache.cc.

Member Data Documentation

◆ bmain

Main* SeqCache::bmain

Definition at line 65 of file image_cache.cc.

Referenced by seq_cache_cleanup_sequence(), and seq_cache_create().

◆ disk_cache

SeqDiskCache* SeqCache::disk_cache

◆ hash

◆ items_pool

BLI_mempool* SeqCache::items_pool

◆ iterator_mutex

ThreadMutex SeqCache::iterator_mutex

◆ keys_pool

BLI_mempool* SeqCache::keys_pool

◆ last_key


The documentation for this struct was generated from the following file: