Skip to content

Commit

Permalink
Remove deprecated argument to getChunkOffsetTableSize() (#988)
Browse files Browse the repository at this point in the history
* Remove deprecated argument to getChunkOffsetTableSize()

Signed-off-by: Cary Phillips <cary@ilm.com>

* Remove mention of deprecated_attribute from comment

Signed-off-by: Cary Phillips <cary@ilm.com>
  • Loading branch information
cary-ilm authored Mar 28, 2021
1 parent b930cc3 commit 217140e
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 9 deletions.
2 changes: 1 addition & 1 deletion src/bin/exrmaketiled/makeTiled.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -561,7 +561,7 @@ makeTiled (const char inFileName[],
// set tileDescription, type, and chunckcount for multipart
//
header.setType(TILEDIMAGE);
int chunkcount = getChunkOffsetTableSize(header, true);
int chunkcount = getChunkOffsetTableSize(header);
header.setChunkCount(chunkcount);

headers.push_back(header);
Expand Down
2 changes: 1 addition & 1 deletion src/lib/OpenEXR/ImfMisc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1843,7 +1843,7 @@ int
getTiledChunkOffsetTableSize(const Header& header);

int
getChunkOffsetTableSize(const Header& header,bool)
getChunkOffsetTableSize(const Header& header)
{
//
// if there is a type in the header which indicates the part is not a currently supported type,
Expand Down
11 changes: 5 additions & 6 deletions src/lib/OpenEXR/ImfMisc.h
Original file line number Diff line number Diff line change
Expand Up @@ -434,15 +434,14 @@ bool usesLongNames (const Header &header);

//
// compute size of chunk offset table - for existing types, computes
// the chunk size from the image size, compression type, and tile description
// (for tiled types). If the type is not supported, uses the chunkCount attribute
// if present, or throws an exception otherwise
// deprecated_attribute is no longer used by this function
//
// the chunk size from the image size, compression type, and tile
// description (for tiled types). If the type is not supported, uses
// the chunkCount attribute if present, or throws an exception
// otherwise
//

IMF_EXPORT
int getChunkOffsetTableSize(const Header& header,bool deprecated_attribute=false);
int getChunkOffsetTableSize(const Header& header);


OPENEXR_IMF_INTERNAL_NAMESPACE_HEADER_EXIT
Expand Down
2 changes: 1 addition & 1 deletion src/test/OpenEXRTest/testFutureProofing.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ generateRandomHeaders (int partCount, vector<Header>& headers)
// future types MUST have a chunkCount attribute - ommitting causes the library
// to raise an exception (can't compute chunkOffsetTable) and prevents us from reading
// the rest of the image
header.setChunkCount(getChunkOffsetTableSize(header,true));
header.setChunkCount(getChunkOffsetTableSize(header));
headers.push_back(header);
}
}
Expand Down

0 comments on commit 217140e

Please sign in to comment.