MCPcopy Create free account
hub / github.com/IppClub/Dora-SSR / textureLoad

Function textureLoad

Source/Node/EffekNode.cpp:334–345  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

332}
333
334static int textureLoad(const char* name, int srgb, void* ud) {
335 DORA_UNUSED_PARAM(srgb);
336 Texture2D* texture = SharedTextureCache.load(name);
337 if (texture) {
338 bgfx::setName(texture->getHandle(), name);
339 int texId = s_cast<int>(texture->getHandle().idx);
340 auto manager = r_cast<EffekManager*>(ud);
341 manager->addTexture(texId, texture);
342 return texId;
343 }
344 return -1;
345}
346
347static void textureUnload(int texId, void* ud) {
348 auto manager = r_cast<EffekManager*>(ud);

Callers

nothing calls this directly

Calls 4

loadMethod · 0.65
setNameFunction · 0.50
getHandleMethod · 0.45
addTextureMethod · 0.45

Tested by

no test coverage detected