// why would you do this exception? This is only true for the datastream,
a memory or filestream can grow.
kind regards
Alexander
bool Texture::ToStream( Texture^ texture, ImageFileFormat format, Stream^
stream )
{
ID3D10Blob* blob = 0;
HRESULT hr = D3DX10SaveTextureToMemory( texture-
>InternalPointer, (D3DX10_IMAGE_FILE_FORMAT) format, &blob, 0 );
if( RECORD_D3D10( hr ).IsFailure )
return false;
if( static_cast<SIZE_T>( stream->Length - stream-
>Position ) < blob->GetBufferSize() )
throw gcnew InvalidOperationException( "The
specified stream does not have sufficient capacity for the specified
texture." );
Original issue reported on code.google.com by amuylaer...@gmail.com on 11 Jan 2009 at 4:49
Original issue reported on code.google.com by
amuylaer...@gmail.com
on 11 Jan 2009 at 4:49