driver.bmx 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. Strict
  2. Import BRL.Pixmap
  3. Import BRL.Graphics
  4. 'modes for SetBlend
  5. Const MASKBLEND=1
  6. Const SOLIDBLEND=2
  7. Const ALPHABLEND=3
  8. Const LIGHTBLEND=4
  9. Const SHADEBLEND=5
  10. 'flags for frames/images
  11. Const MASKEDIMAGE= $1
  12. Const FILTEREDIMAGE= $2
  13. Const MIPMAPPEDIMAGE= $4
  14. Const DYNAMICIMAGE= $8
  15. 'current driver
  16. Global _max2dDriver:TMax2DDriver
  17. Type TImageFrame
  18. Method Draw( x0#,y0#,x1#,y1#,tx#,ty#,sx#,sy#,sw#,sh# ) Abstract
  19. End Type
  20. Type TMax2DDriver Extends TGraphicsDriver
  21. Method CreateFrameFromPixmap:TImageFrame( pixmap:TPixmap,flags ) Abstract
  22. Method SetBlend( blend ) Abstract
  23. Method SetAlpha( alpha# ) Abstract
  24. Method SetColor( red,green,blue ) Abstract
  25. Method SetClsColor( red,green,blue ) Abstract
  26. Method SetViewport( x,y,width,height ) Abstract
  27. Method SetTransform( xx#,xy#,yx#,yy# ) Abstract
  28. Method SetLineWidth( width# ) Abstract
  29. Method Cls() Abstract
  30. Method Plot( x#,y# ) Abstract
  31. Method DrawLine( x0#,y0#,x1#,y1#,tx#,ty# ) Abstract
  32. Method DrawRect( x0#,y0#,x1#,y1#,tx#,ty# ) Abstract
  33. Method DrawOval( x0#,y0#,x1#,y1#,tx#,ty# ) Abstract
  34. Method DrawPoly( xy#[],handlex#,handley#,originx#,originy# ) Abstract
  35. Method DrawPixmap( pixmap:TPixmap,x,y ) Abstract
  36. Method GrabPixmap:TPixmap( x,y,width,height ) Abstract
  37. Method SetResolution( width#,height# ) Abstract
  38. End Type