Added reading of next IFD entry offset in order to make it convenient to read all IFD entries in a TIFF file
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@3897 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
93e1f7dfd0
commit
6cef630541
@ -97,6 +97,16 @@ TiffIfd::LoadFields(uint32 offset, BPositionIO &io, swap_action swp)
|
||||
finitStatus = fpfields[i]->InitCheck();
|
||||
return;
|
||||
}
|
||||
} // for (i = 0; i < ffieldCount; i++, offset += 12)
|
||||
|
||||
// Read address of next IFD entry
|
||||
if (io.ReadAt(offset, &fnextIFDOffset, 4) != 4) {
|
||||
finitStatus = B_IO_ERROR;
|
||||
return;
|
||||
}
|
||||
if (swap_data(B_UINT32_TYPE, &nextIFDOffset, 4, swp) != B_OK) {
|
||||
finitStauts = B_ERROR;
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -66,6 +66,8 @@ public:
|
||||
bool HasField(uint16 tag);
|
||||
uint32 GetCount(uint16 tag);
|
||||
// throws: TiffIfdFieldNotFoundException()
|
||||
|
||||
uint32 GetNextIfdOffset() { return fnextIFDOffset; };
|
||||
|
||||
uint32 GetUint(uint16 tag, uint32 index = 0);
|
||||
// index is the base one index for the desired
|
||||
|
Loading…
Reference in New Issue
Block a user