1. -- 
  2. -- Copyright (c) 2012 Kevin Wellwood 
  3. -- All rights reserved. 
  4. -- 
  5. -- This source code is distributed under the Modified BSD License. For terms and 
  6. -- conditions, see license.txt. 
  7. -- 
  8.  
  9. -- The procedures in this package are not part of Allegro but are helper 
  10. -- routines for providing direct access to memory bitmaps. 
  11. -- 
  12. -- Warning: 
  13. -- No checking is done for the type of bitmap- it MUST be a memory bitmap- 
  14. -- and no bounds checking is done on the pixel coordinates. Be sure you 
  15. -- know what you're doing! 
  16. package Allegro.Bitmaps.Direct_Access is 
  17.  
  18.     function Memory_Getpixel_15_or_16_bpp( bmp  : not null A_Bitmap; 
  19.                                            x, y : Natural ) return Color_Type; 
  20.  
  21.     function Memory_Getpixel_32( bmp  : not null A_Bitmap; 
  22.                                  x, y : Natural ) return Color_Type; 
  23.  
  24.     procedure Memory_Putpixel_15_or_16_bpp( bmp   : not null A_Bitmap; 
  25.                                             x, y  : Natural; 
  26.                                             color : Color_Type ); 
  27.  
  28.     procedure Memory_Putpixel_32( bmp   : not null A_Bitmap; 
  29.                                   x, y  : Natural; 
  30.                                   color : Color_Type ); 
  31.  
  32. private 
  33.  
  34.     pragma Import( C, Memory_Getpixel_15_or_16_bpp, "memory_getpixel_15_or_16_bpp" ); 
  35.     pragma Import( C, Memory_Getpixel_32,           "memory_getpixel_32" ); 
  36.     pragma Import( C, Memory_Putpixel_15_or_16_bpp, "memory_putpixel_15_or_16_bpp" ); 
  37.     pragma Import( C, Memory_Putpixel_32,           "memory_putpixel_32" ); 
  38.  
  39. end Allegro.Bitmaps.Direct_Access;