You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
//! shrinks byte size of all output buffers, so they are large enough to fit currently allocated contents. Call this function before `instantiateDataStorage`
160
-
voidshrinkOutputBuffersSize()
159
+
voidshrinkOutputBuffersSize()// TODO: shrink isn't special, can only happen before data storage is instantiated, so do it in the base class
// TODO: SHRINK ACTUAL ALLOCATORS AND THEIR RESERVED SPACES! (CREATE NEW ALLOCATORS WITH NEW RESERVED SPACES, THEN DELETE OLD RESERVED, THEN SWAP ALLOCATOR AND RESERVED MEMBERS)
166
166
}
167
167
168
168
private:
@@ -173,7 +173,7 @@ class CCPUMeshPackerV1 final : public IMeshPacker<ICPUMeshBuffer, MDIStructType>
173
173
174
174
uint32_t m_vtxSize;
175
175
uint32_t m_perInsVtxSize;
176
-
AllocationParams m_allocParams;
176
+
AllocationParams m_allocParams;// TODO: only track the min sizes, the other stuff is redundant with allocators
177
177
178
178
bool isInstancingEnabled;
179
179
void* m_perInsVtxBuffAlctrResSpc;
@@ -233,6 +233,7 @@ CCPUMeshPackerV1<MDIStructType>::CCPUMeshPackerV1(const SVertexInputParams& preD
233
233
);
234
234
}
235
235
236
+
// TODO: why cant this implementation of `alloc` be common to both CPU and CPU?
236
237
template <typename MDIStructType>
237
238
//`Iterator` may be only an Iterator or pointer to pointer
//allocation should be happening even if processed mesh buffer doesn't have attribute that was declared in pre defined `SVertexInputParams`, if mesh buffer has any attributes that are not declared in pre defined `SVertexInputParams` then these should be always ignored
Copy file name to clipboardExpand all lines: include/nbl/asset/utils/CCPUMeshPackerV2.h
+4-3Lines changed: 4 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -40,9 +40,10 @@ class CCPUMeshPackerV2 final : public IMeshPackerV2<ICPUBuffer, ICPUMeshBuffer,
40
40
//! shrinks byte size of all output buffers, so they are large enough to fit currently allocated contents. Call this function before `instantiateDataStorage`
// TODO: SHRINK ACTUAL ALLOCATORS AND THEIR RESERVED SPACES! (CREATE NEW ALLOCATORS WITH NEW RESERVED SPACES, THEN DELETE OLD RESERVED, THEN SWAP ALLOCATOR AND RESERVED MEMBERS)
0 commit comments