1. package Allegro.Bitmaps.Direct_Access is 
  2.  
  3.     -- The following procedures are not part of Allegro but are helper routines 
  4.     -- for providing direct access to memory bitmaps. 
  5.     -- 
  6.     -- Warning: 
  7.     -- No checking is done for the type of bitmap- it MUST be a memory bitmap- 
  8.     -- and no bounds checking is done on the pixel coordinates. Be sure you 
  9.     -- know what you're doing! 
  10.  
  11.     function Memory_Getpixel_15_or_16_bpp( bmp  : not null A_Bitmap; 
  12.                                            x, y : Natural ) return Color_Type; 
  13.  
  14.     function Memory_Getpixel_32( bmp  : not null A_Bitmap; 
  15.                                  x, y : Natural ) return Color_Type; 
  16.  
  17.     procedure Memory_Putpixel_15_or_16_bpp( bmp   : not null A_Bitmap; 
  18.                                             x, y  : Natural; 
  19.                                             color : Color_Type ); 
  20.  
  21.     procedure Memory_Putpixel_32( bmp   : not null A_Bitmap; 
  22.                                   x, y  : Natural; 
  23.                                   color : Color_Type ); 
  24.  
  25. private 
  26.  
  27.     pragma Import( C, Memory_Getpixel_15_or_16_bpp, "memory_getpixel_15_or_16_bpp" ); 
  28.     pragma Import( C, Memory_Getpixel_32,           "memory_getpixel_32" ); 
  29.     pragma Import( C, Memory_Putpixel_15_or_16_bpp, "memory_putpixel_15_or_16_bpp" ); 
  30.     pragma Import( C, Memory_Putpixel_32,           "memory_putpixel_32" ); 
  31.  
  32. end Allegro.Bitmaps.Direct_Access;