Changes to support non-C++0x compilers.

This commit is contained in:
David Williams
2010-09-01 22:01:52 +00:00
parent 40d26b4361
commit 7f2518e6c8
14 changed files with 49 additions and 39 deletions

View File

@ -30,7 +30,7 @@ namespace PolyVox
//Note: we don't do much error handling in here - exceptions will simply be propergated up to the caller.
//FIXME - think about pointer ownership issues. Or could return volume by value if the copy constructor is shallow
template <typename VoxelType>
std::shared_ptr< Volume<VoxelType> > loadVolumeRaw(std::istream& stream, VolumeSerializationProgressListener* progressListener)
polyvox_shared_ptr< Volume<VoxelType> > loadVolumeRaw(std::istream& stream, VolumeSerializationProgressListener* progressListener)
{
//Read volume dimensions
uint8_t volumeWidthPower = 0;
@ -45,7 +45,7 @@ namespace PolyVox
uint16_t volumeDepth = 0x0001 << volumeDepthPower;
//FIXME - need to support non cubic volumes
std::shared_ptr< Volume<VoxelType> > volume(new Volume<VoxelType>(volumeWidth, volumeHeight, volumeDepth));
polyvox_shared_ptr< Volume<VoxelType> > volume(new Volume<VoxelType>(volumeWidth, volumeHeight, volumeDepth));
//Read data
for(uint16_t z = 0; z < volumeDepth; ++z)
@ -126,7 +126,7 @@ namespace PolyVox
//Note: we don't do much error handling in here - exceptions will simply be propergated up to the caller.
//FIXME - think about pointer ownership issues. Or could return volume by value if the copy constructor is shallow
template <typename VoxelType>
std::shared_ptr< Volume<VoxelType> > loadVolumeRle(std::istream& stream, VolumeSerializationProgressListener* progressListener)
polyvox_shared_ptr< Volume<VoxelType> > loadVolumeRle(std::istream& stream, VolumeSerializationProgressListener* progressListener)
{
//Read volume dimensions
uint8_t volumeWidthPower = 0;
@ -141,7 +141,7 @@ namespace PolyVox
uint16_t volumeDepth = 0x0001 << volumeDepthPower;
//FIXME - need to support non cubic volumes
std::shared_ptr< Volume<VoxelType> > volume(new Volume<VoxelType>(volumeWidth, volumeHeight, volumeDepth));
polyvox_shared_ptr< Volume<VoxelType> > volume(new Volume<VoxelType>(volumeWidth, volumeHeight, volumeDepth));
//Read data
bool firstTime = true;