Pulp 1.88.0
Cross-platform audio plugin framework
Loading...
Searching...
No Matches
pulp::render::GradientAtlas Class Reference

Gradient atlas — caches evaluated gradient ramps as GPU textures. More...

#include <texture_atlas.hpp>

Classes

struct  Entry

Public Member Functions

bool has (uint64_t key) const
bool allocate (uint64_t key, int &row)
void mark_used (uint64_t key, uint64_t frame)
size_t evict_stale (uint64_t current_frame, uint64_t max_age=120)
size_t entry_count () const
int row_capacity () const
 Read-only introspection for the inspector's atlas viewer.
int rows_used () const
float occupancy () const

Detailed Description

Gradient atlas — caches evaluated gradient ramps as GPU textures.

Gradients are keyed by a hash of their stops/colors.

Member Function Documentation

◆ allocate()

bool pulp::render::GradientAtlas::allocate ( uint64_t key,
int & row )

◆ entry_count()

size_t pulp::render::GradientAtlas::entry_count ( ) const
inline

◆ evict_stale()

size_t pulp::render::GradientAtlas::evict_stale ( uint64_t current_frame,
uint64_t max_age = 120 )

◆ has()

bool pulp::render::GradientAtlas::has ( uint64_t key) const
inline

◆ mark_used()

void pulp::render::GradientAtlas::mark_used ( uint64_t key,
uint64_t frame )

◆ occupancy()

float pulp::render::GradientAtlas::occupancy ( ) const
inline

◆ row_capacity()

int pulp::render::GradientAtlas::row_capacity ( ) const
inline

Read-only introspection for the inspector's atlas viewer.

A GradientAtlas is row-packed (one ramp per row) rather than shelf-packed, so occupancy is simply allocated rows over the row budget.

◆ rows_used()

int pulp::render::GradientAtlas::rows_used ( ) const
inline

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