hold method

void hold(
  1. Object thing
)

Counts one more user of thing — a mesh from meshFor, or a material from materialFor — until it calls release.

Implementation

void hold(Object thing) {
  final entry = _entryOf(thing);
  if (entry != null) {
    entry.holders++;
  } else if (thing is GpuMaterial) {
    library?.hold(thing);
  }
}