Andrew,
I currently use the routine :
WRITE_GRAPHICS_TO_PCX@( FILENAME, ERROR )
can I simply change it to the following with the appropriate declaration ?
WRITE_GRAPHICS_TO_GIF@ ( FILENAME, ERROR )
It is great news if I can, as my images all have less than 256 colours and should be suited to gif compression.
I will probably try it before your reply !!
John
Postscript :
I got the following message that the symbol '__write_graphics_to_gif' was missing. Could you please email me an updated salflibc.dll which has this available.
My screen dump routine, cloned from .pcx and .jpg is:
Subroutine Dump_gif_func (message)
!
! dumps a gif file from active selected region
!
! use mswin
include <clearwin.ins>
!
C_EXTERNAL IMPORT_GIF@ '__import_gif' (INSTRING,REF) :INTEGER*4
C_EXTERNAL EXPORT_GIF@ '__export_gif'(VAL,INSTRING,REF)
C_EXTERNAL WRITE_GRAPHICS_TO_GIF@ '__write_graphics_to_gif' (INSTRING,REF)
!
integer*4 error_gif, file_nn, nx, ny
integer*4 lu, get_file_unit
character file_gif*12, message*(*)
external get_file_unit
data file_nn / 0 /
!
! develop a screen dump file name
!
lu = get_file_unit (90)
close (unit=lu)
!
11 file_nn = file_nn + 1
if (file_nn.gt.999) then
error_gif = 1
goto 100
end if
!
write (file_gif,'(a,i3.3,a)') 'dump',file_nn,'.gif'
open (unit=lu,file=file_gif,status='new',err=11)
close (unit=lu,status='delete')
!
call write_graphics_to_gif@ (file_gif, error_gif)
!
100 call get_graphical_resolution@ ( nx, ny )
write (98,1000) file_gif, nx, ny, lu, error_gif
1000 format ('gif DUMP file ',a, &
' Size :',i6,' x',i6,' (lu',i3,' error',i4,')')
!
if (error_gif.eq.0) then
message = 'gif dump to '//file_gif
else if (error_gif.eq.1) then
message = 'Unable to open '//file_gif
else if (error_gif.eq.3) then
message = 'Unable to dump to '//file_gif
else
message = 'Unable to use '//file_gif
end if
!
end subroutine Dump_gif_func