MCPcopy Create free account
hub / github.com/NVIDIAGameWorks/Falcor / SDFSBS

Method SDFSBS

Source/Falcor/Scene/SDFs/SparseBrickSet/SDFSBS.cpp:76–86  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

74 static SharedCache<SDFSBS::SharedData, Device*> sSharedCache;
75
76 SDFSBS::SDFSBS(ref<Device> pDevice, uint32_t brickWidth, bool compressed, uint32_t defaultGridWidth)
77 : SDFGrid(pDevice)
78 , mDefaultGridWidth(defaultGridWidth)
79 , mBrickWidth(brickWidth)
80 , mCompressed(compressed)
81 {
82 FALCOR_CHECK(!compressed || (brickWidth + 1) % 4 == 0, "'brickWidth' ({}) must be a multiple of 4 minus 1 for compressed SDFSBSs", brickWidth);
83
84
85 mpSharedData = sSharedCache.acquire(mpDevice.get(), [this]() { return std::make_shared<SharedData>(mpDevice); });
86 }
87
88 size_t SDFSBS::getSize() const
89 {

Callers

nothing calls this directly

Calls 2

acquireMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected