next up previous 231
Next: Using ``images'' which are not 2-dimensional
Up: Examples of using IMG from C
Previous: Modifying a copy of an image

Getting images as workspace

This example (shadow.c) shows how to create temporary images. The HDS (SUN/92) manual describes some reasons why you might consider using temporary images rather than ``malloc'd'' memory in your programs.
  /*  Access the input image. */
  imgIn( "in", &nx, &ny, &ipin, istat );

  /*  Get a same sized temporary image as workspace. */
  imgTmp( "temp", nx, ny, &iptemp, istat );

  /*  Free all images (this deletes the temporary image). */
  imgFree( "*", istat );



next up previous 231
Next: Using ``images'' which are not 2-dimensional
Up: Examples of using IMG from C
Previous: Modifying a copy of an image

IMG Simple Image Data Access
Starlink User Note 160
P.W. Draper
R.F. Warren-Smith
3 March 2003
E-mail:P.W.Draper@durham.ac.uk

Copyright © 2000-2003 Council for the Central Laboratory of the Research Councils