tw0711.pp 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. { %GRAPH }
  2. { %TARGET=go32v2,win32,linux }
  3. program TestGetPutim; {Compiled with the 0.99.13 version under GO32V2!}
  4. uses
  5. graph;
  6. var graphdriver,graphmode :integer;
  7. imsize:longint;
  8. im:pointer;
  9. begin
  10. {$ifdef win32}
  11. graphdriver:=VGA;
  12. graphmode:=detect;
  13. {$else not win32}
  14. graphdriver:=VESA;
  15. graphmode:=$103;
  16. {$endif}
  17. Initgraph(graphdriver,graphmode,'');
  18. {************}
  19. (*
  20. setcolor(6);
  21. moveto(0,0); {Some drawing}
  22. lineto(500,500);
  23. circle(95,95,80);
  24. {************}
  25. {!!!!!!!!!!!!}
  26. imsize:= imagesize(0,0,300,300); {This is the part we have problem with.}
  27. getmem(im,imsize); {The result we get after PutImage is}
  28. getimage(0,0,300,300,im^); {chaotic independently from the graphmode!}
  29. putimage(50,50,im^,0); {We tested this on a S3Trio 3D videcard,}
  30. {which is VESA compatible.}
  31. {!!!!!!!!!!!!}
  32. readln;
  33. {repeat until keypressed;}
  34. *)
  35. closegraph;
  36. end.
  37. {
  38. I. Groma
  39. [email protected]
  40. Budapest 11/24/1999
  41. }