Mercurial > octave-libtiff
diff scripts/io/Tiff.m @ 31202:be6ccdcd5775
Tiff: added isBigEndian and getDirectoryOffset methods to the class
* scripts/io/Tiff.m: added isBigEndian and getDirectoryOffset methods
to the class.
* libtinterp/corefcn/tiff.cc: added __tiff_is_big_endian__ and
__tiff_get_directory_offset__ as internal functions for isBigEndian
and getDirectoryOffset repectively.
* scripts/image/private/__tiff_imfinfo__.m: used the two new methods
to get the corresponding info fields.
author | magedrifaat <magedrifaat@gmail.com> |
---|---|
date | Fri, 02 Sep 2022 21:20:56 +0200 |
parents | 30b28458bb06 |
children | df8ee95752aa |
line wrap: on
line diff
--- a/scripts/io/Tiff.m Fri Sep 02 20:52:47 2022 +0200 +++ b/scripts/io/Tiff.m Fri Sep 02 21:20:56 2022 +0200 @@ -227,6 +227,10 @@ stripLength = __tiff_default_strip_length__ (t.tiff_handle); endfunction + function tf = isBigEndian (t) + tf = __tiff_is_big_endian__ (t.tiff_handle); + endfunction + function dirNum = currentDirectory (t) dirNum = __tiff_current_directory__ (t.tiff_handle); endfunction @@ -255,6 +259,10 @@ __tiff_set_sub_directory__ (t.tiff_handle, offset); endfunction + function offset = getDirectoryOffset (t) + offset = __tiff_get_directory_offset__ (t.tiff_handle); + endfunction + % TODO(maged): add documentation and make print_usage work endmethods