Commit cb93d832 authored by BRAMAS Berenger's avatar BRAMAS Berenger

debug group attach leaf (still something wrong with cheb)

parent e6db870b
...@@ -46,9 +46,8 @@ public: ...@@ -46,9 +46,8 @@ public:
positionsPointers[1] = reinterpret_cast<FReal*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition); positionsPointers[1] = reinterpret_cast<FReal*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition);
positionsPointers[2] = reinterpret_cast<FReal*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition*2); positionsPointers[2] = reinterpret_cast<FReal*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition*2);
unsigned char* symAttributes = reinterpret_cast<unsigned char*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition*3);
for(unsigned idxAttribute = 0 ; idxAttribute < NbSymbAttributes ; ++idxAttribute){ for(unsigned idxAttribute = 0 ; idxAttribute < NbSymbAttributes ; ++idxAttribute){
attributes[idxAttribute] = reinterpret_cast<AttributeClass*>(symAttributes + idxAttribute*inLeadingAttributes); attributes[idxAttribute] = reinterpret_cast<AttributeClass*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition*(idxAttribute+3));
} }
// Redirect pointers to data // Redirect pointers to data
......
...@@ -37,9 +37,8 @@ public: ...@@ -37,9 +37,8 @@ public:
positionsPointers[1] = reinterpret_cast<FReal*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition); positionsPointers[1] = reinterpret_cast<FReal*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition);
positionsPointers[2] = reinterpret_cast<FReal*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition*2); positionsPointers[2] = reinterpret_cast<FReal*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition*2);
unsigned char* symAttributes = reinterpret_cast<unsigned char*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition*3);
for(unsigned idxAttribute = 0 ; idxAttribute < NbSymbAttributes ; ++idxAttribute){ for(unsigned idxAttribute = 0 ; idxAttribute < NbSymbAttributes ; ++idxAttribute){
attributes[idxAttribute] = reinterpret_cast<AttributeClass*>(symAttributes + idxAttribute*inLeadingAttributes); attributes[idxAttribute] = reinterpret_cast<AttributeClass*>(reinterpret_cast<unsigned char*>(inPositionBuffer) + inLeadingPosition*(idxAttribute+3));
} }
// Redirect pointers to data // Redirect pointers to data
......
...@@ -216,9 +216,8 @@ struct FOpenCLGroupAttachedLeaf BuildFOpenCLGroupAttachedLeaf(const int inNbPart ...@@ -216,9 +216,8 @@ struct FOpenCLGroupAttachedLeaf BuildFOpenCLGroupAttachedLeaf(const int inNbPart
leaf.positionsPointers[1] = (__global FReal*)(((__global unsigned char*)inPositionBuffer) + inLeadingPosition); leaf.positionsPointers[1] = (__global FReal*)(((__global unsigned char*)inPositionBuffer) + inLeadingPosition);
leaf.positionsPointers[2] = (__global FReal*)(((__global unsigned char*)inPositionBuffer) + inLeadingPosition*2); leaf.positionsPointers[2] = (__global FReal*)(((__global unsigned char*)inPositionBuffer) + inLeadingPosition*2);
unsigned char* symAttributes = (__global unsigned char*)(((__global unsigned char*)inPositionBuffer) + inLeadingPosition*3);
for(unsigned idxAttribute = 0 ; idxAttribute < NbSymbAttributes ; ++idxAttribute){ for(unsigned idxAttribute = 0 ; idxAttribute < NbSymbAttributes ; ++idxAttribute){
leaf.attributes[idxAttribute] = (__global FParticleValueClass*)(symAttributes + idxAttribute*inLeadingAttributes); leaf.attributes[idxAttribute] = (__global FParticleValueClass*)(((__global unsigned char*)inPositionBuffer) + inLeadingPosition*(idxAttribute+3));
} }
// Redirect pointers to data // Redirect pointers to data
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment