Home Image-Pro Plus General Discussions

Tile images macro

I'm trying to tile images (500-600 image Tiff files), and I'm finding that the macro does not load the images properly when I freshly open a file.  It works fine when I've just taken the images, but not if I re-open the Tiff.  It seems to be something with the IpTileAdd line, but I can't find much in the help section on it.    Suggestions please?  


ret = IpTileSetInt(TILE_UPDATEUI, 0, 0)
ret = IpTileAdd(1, 0)
ret = IpTileSetInt(TILE_UPDATEUI, 0, 1)

Thanks.

Answers

  • I suspect the issue is due to using a fixed image ID in IpTileAdd( ). If the loaded image is not ID 1 (which would be the second image created, using Image-Pro's 0-based indexing) your code would fail. 

    If the active image is the one you are trying to tile, I would suggest:

        ret = IpTileAdd( IpDocActive( ), 0 )
Sign In or Register to comment.