home *** CD-ROM | disk | FTP | other *** search
/ SPACE 2 / SPACE - Library 2 - Volume 1.iso / demos / 275 / pascal / getpixel.pas < prev    next >
Encoding:
Pascal/Delphi Source File  |  1988-07-14  |  531 b   |  25 lines

  1. PROCEDURE Get_Pixel_Value( X, Y : Short_Integer ;
  2.                            VAR PV, CI : Short_Integer ) ;
  3.  
  4.     VAR
  5.         Ctrl : Ctrl_Parms ;
  6.         Int_In : Int_In_Parms ;
  7.         Int_Out : Int_Out_Parms ;
  8.         Pts_In : Pts_In_Parms ;
  9.         Pts_Out : Pts_Out_Parms ;
  10.  
  11.     BEGIN { Get_Pixel_Value }
  12.         
  13.         Ctrl[1] := 1 ;
  14.         Ctrl[3] := 0 ;
  15.         Pts_In[0] := X ;
  16.         Pts_In[1] := Y ;
  17.  
  18.         VDI_Call( 105, 0, 0, 2, Ctrl, Int_In, Int_Out,
  19.                   Pts_In, Pts_Out, False ) ;
  20.  
  21.         PV := Int_Out[0] ;
  22.         CI := Int_Out[1] ;
  23.  
  24.     END ; { Get_Pixel_Value }
  25.