diff --git a/src/osg/TextureBuffer.cpp b/src/osg/TextureBuffer.cpp index 91eea6c51..05187932a 100644 --- a/src/osg/TextureBuffer.cpp +++ b/src/osg/TextureBuffer.cpp @@ -35,7 +35,9 @@ TextureBuffer::TextureBuffer(const TextureBuffer& text,const CopyOp& copyop): Texture(text,copyop), _textureWidth(text._textureWidth) { - setBufferData(osg::clone(text._bufferData.get(), copyop)); + if (text._bufferData.valid()) { + setBufferData(osg::clone(text._bufferData.get(), copyop)); + } } TextureBuffer::~TextureBuffer()