cinder / Cinder

Cinder is a community-developed, free and open source library for professional-quality creative coding in C++.
http://libcinder.org
Other
5.3k stars 940 forks source link

FishTornado corruption on AMD platform #1532

Open hustwarhd opened 8 years ago

hustwarhd commented 8 years ago

There is an issue within Allocator.cpp which causes corruption on AMD platform. The mOffset is not set correctly in Allocator::Allocation Allocator::PoolManager::Pool::allocate, following is a patch. Please check it.

diff --git a/src/cinder/vk/Allocator.cpp b/src/cinder/vk/Allocator.cpp index 35cc0c4..1ceb01b 100644 --- a/src/cinder/vk/Allocator.cpp +++ b/src/cinder/vk/Allocator.cpp @@ -133,7 +133,7 @@ Allocator::Allocation Allocator::PoolManager::Pool::allocate( const t mAllocations.push_back( result );

            // Move offset
hustwarhd commented 8 years ago

"mOffset += allocatedSize;" should be "mOffset = alignedOffset + allocatedSize;"

hustwarhd commented 8 years ago

The label should be Vulkan. It's my first time to use it, no idea how to set the label. The patch is attached for your reference.

for_FishTornado.txt