• Welcome to Vampyre Imaging Library Forum. Please login or sign up.
 

How to read TIFF tags in Lazarus with Vampyre lib

Started by jus, 11 June 2011, 01:13:21

Previous topic - Next topic

jus

Hi,

  I used the function "TIFFGetField" located in Imaging/Extras/Extensions/LibTiff/LibTiffDelphi.pas from vampyre in Delphi to extract the embedded ICC profile (TIFFTAG_ICCPROFILE). Now I'm trying to port the app to Mac OSX with Lazarus and the vampyre lib. As I understand vampyre uses for Lazarus the LCL functions. So how can I read the TIFF-tag?   :-[

Thanks!

jus 

jus

I have figured out a solution, which is sufficient for me.
First of all I loaded with fink a compiled binary libtiff library, which has the file "libtiff.dylib" included.
Then just load "libiff.dylib" as a external dynamic library into lazarus e.g. like the following code:
LibTiffHandle:=loadlibrary('/sw/lib/libtiff.dylib');
pointer(TIFFOpen) := GetProcedureAddress(LibTiffHandle, 'TIFFOpen');
pointer(TIFFGetField) := GetProcedureAddress(LibTiffHandle, 'TIFFGetField');
pointer(TIFFClose) := GetProcedureAddress(LibTiffHandle, 'TIFFClose');

That's it.

jus

Quick Reply

With Quick-Reply you can write a post when viewing a topic without loading a new page. You can still use bulletin board code and smileys as you would in a normal post.

Name:
Email:

Shortcuts: ALT+S save/post or ALT+P preview

SMF spam blocked by CleanTalk