
// Script function: Create an image with a constant pixel value of 10.

// Unless named starting with GlobalSino, EM, My, Self, the function commands are defined 
//by Gatan DM, please see at link: http://www.globalsino.com/EM/page2597.html



number EMWidth=500, EMHeight=500
Image GlobalSinoImage
   number EMx,EMy
   GlobalSinoImage:= CreateFloatImage("GlobalSino Image",EMWidth, EMHeight);
   for (EMx=0; EMx< EMWidth; EMx++) 
   {
   for (EMy=0; EMy<EMHeight; EMy++) 
     {
   SetPixel(GlobalSinoImage, EMx, EMy, 10) // set constant value for all pixels.
     }
   }    
showimage(GlobalSinoImage)

// Comparison with another case of creating an image at:
// http://www.globalsino.com/EM/page2597_uu.s
// http://www.globalsino.com/EM/page2597_ConstantPixelValue.s