CopyImage.htm 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <html>
  2. <head>
  3. <title>Blitz3D Docs</title>
  4. <link rel=stylesheet href=../css/commands.css type=text/css>
  5. </head>
  6. <body>
  7. <h1>CopyImage (handle)</h1>
  8. <h1>Parameters</h1>
  9. <table>
  10. <tr>
  11. <td>
  12. handle=the variable you gave the handle to when you loaded the image
  13. </td>
  14. </tr>
  15. </table>
  16. <h1>Description</h1>
  17. <table>
  18. <tr>
  19. <td>
  20. Instead of loading a graphic twice in two different handles, you can load the image ONCE then use the CopyImage command to make as many copies in memory as you want. <br />
  21. <br />
  22. Why would you want to do this? So you still have a copy of the original image in case you want to alter a copy later for another purpose.
  23. </td>
  24. </tr>
  25. </table>
  26. <h1><a href=../2d_examples/CopyImage.bb>Example</a></h1>
  27. <table>
  28. <tr>
  29. <td>
  30. ; CopyImage Example <br />
  31. <br />
  32. ; Load an image and give its handle to gfxOld variable <br />
  33. gfxOld=LoadImage("mypicture.bmp") <br />
  34. <br />
  35. ; Duplicate the gfxOld image to a new handle variable <br />
  36. gfxNew=CopyImage(gfxOld) <br />
  37. </td>
  38. </tr>
  39. </table>
  40. <br>
  41. <a target=_top href=../index.htm>Index</a><br>
  42. <br>
  43. Click <a href=http://www.blitzbasic.co.nz/b3ddocs/command.php?name=CopyImage&ref=comments target=_blank>here</a> to view the latest version of this page online</body>
  44. </html>