Skip to content

Commit ba11833

Browse files
committed
Fixed a bug in a sanity check in SHWDeepImageWriter.
1 parent 4a92103 commit ba11833

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/IECoreRI/SHWDeepImageWriter.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//////////////////////////////////////////////////////////////////////////
22
//
3-
// Copyright (c) 2012, Image Engine Design Inc. All rights reserved.
3+
// Copyright (c) 2012-2014, Image Engine Design Inc. All rights reserved.
44
//
55
// Redistribution and use in source and binary forms, with or without
66
// modification, are permitted provided that the following conditions are
@@ -49,7 +49,7 @@ const DeepImageWriter::DeepImageWriterDescription<SHWDeepImageWriter> SHWDeepIma
4949

5050
SHWDeepImageWriter::SHWDeepImageWriter()
5151
: DeepImageWriter( "Writes 3delight SHW deep shadow file format." ),
52-
m_outputFile( 0 ), m_dtexCache( 0 ), m_dtexImage( 0 ), m_dtexPixel( 0 )
52+
m_outputFile( 0 ), m_dtexCache( 0 ), m_dtexImage( 0 ), m_dtexPixel( 0 ), m_alphaOffset( 0 )
5353
{
5454
std::vector<std::string> channels( 1, "A" );
5555
m_channelsParameter->setValue( new StringVectorData( channels ) );
@@ -60,7 +60,7 @@ SHWDeepImageWriter::SHWDeepImageWriter()
6060

6161
SHWDeepImageWriter::SHWDeepImageWriter( const std::string &fileName )
6262
: DeepImageWriter( "Writes 3delight SHW deep shadow file format." ),
63-
m_outputFile( 0 ), m_dtexCache( 0 ), m_dtexImage( 0 ), m_dtexPixel( 0 )
63+
m_outputFile( 0 ), m_dtexCache( 0 ), m_dtexImage( 0 ), m_dtexPixel( 0 ), m_alphaOffset( 0 )
6464
{
6565
m_fileNameParameter->setTypedValue( fileName );
6666

@@ -164,7 +164,7 @@ void SHWDeepImageWriter::open()
164164
throw InvalidArgumentException( std::string( "Tile size must be equal to or less than resolution." ) );
165165
}
166166

167-
if ( ( ( tileSize.x & ( tileSize.x - 1 ) ) != 0 ) || ( ( tileSize.x & ( tileSize.x - 1 ) ) != 0 ) )
167+
if ( ( ( tileSize.x & ( tileSize.x - 1 ) ) != 0 ) || ( ( tileSize.y & ( tileSize.y - 1 ) ) != 0 ) )
168168
{
169169
throw InvalidArgumentException( std::string( "Tile width and height must be a power of two." ) );
170170
}

0 commit comments

Comments
 (0)