mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2025-06-17 18:27:56 -05:00
Add dynamic allocation alignment to be able to load T6 MemoryBlock asset which isnt used at all so why am i doing this again
This commit is contained in:
@ -8,10 +8,10 @@
|
||||
class IZoneInputStream : public IZoneStream
|
||||
{
|
||||
public:
|
||||
virtual void* Alloc(int align) = 0;
|
||||
virtual void* Alloc(unsigned align) = 0;
|
||||
|
||||
template<typename T>
|
||||
T* Alloc(const int align)
|
||||
T* Alloc(const unsigned align)
|
||||
{
|
||||
return static_cast<T*>(Alloc(align));
|
||||
}
|
||||
|
@ -30,7 +30,7 @@ XBlockInputStream::~XBlockInputStream()
|
||||
assert(m_block_stack.empty());
|
||||
}
|
||||
|
||||
void XBlockInputStream::Align(const int align)
|
||||
void XBlockInputStream::Align(const unsigned align)
|
||||
{
|
||||
assert(!m_block_stack.empty());
|
||||
|
||||
@ -78,7 +78,7 @@ block_t XBlockInputStream::PopBlock()
|
||||
return poppedBlock->m_index;
|
||||
}
|
||||
|
||||
void* XBlockInputStream::Alloc(const int align)
|
||||
void* XBlockInputStream::Alloc(const unsigned align)
|
||||
{
|
||||
assert(!m_block_stack.empty());
|
||||
|
||||
|
@ -19,7 +19,7 @@ class XBlockInputStream final : public IZoneInputStream
|
||||
int m_block_bit_count;
|
||||
XBlock* m_insert_block;
|
||||
|
||||
void Align(int align);
|
||||
void Align(unsigned align);
|
||||
|
||||
public:
|
||||
XBlockInputStream(std::vector<XBlock*>& blocks, ILoadingStream* stream, int blockBitCount, block_t insertBlock);
|
||||
@ -28,7 +28,7 @@ public:
|
||||
void PushBlock(block_t block) override;
|
||||
block_t PopBlock() override;
|
||||
|
||||
void* Alloc(int align) override;
|
||||
void* Alloc(unsigned align) override;
|
||||
|
||||
void LoadDataRaw(void* dst, size_t size) override;
|
||||
void LoadDataInBlock(void* dst, size_t size) override;
|
||||
|
Reference in New Issue
Block a user