Saving Images
Blitz3D Forums/Blitz3D Beginners Area/Saving Images
| ||
Just getting into using some of the 2d commands. I have an image with quite a few frames but I don't see any commands to save them as one BMP and then load them via loadanimimage. Please tell me I don't have to save them all individually?? |
| ||
All you need to do is create a new image (CreateImage) that is big enough to store all of the images, and then copy all the images to the correct position on that image (copyrect/ copybuffer) save that image (saveimage/ savebuffer) |
| ||
Thought that might be the case - thanks. What is the correct position though? Say if my bigger image was wide enough to hold 4 smaller images are they referenced like this? 00 01 02 03 04 05 06 07 08 etc.. |
| ||
That gets defined when you create it. CreateImage (100,100,5) Now, internally, i don't know how that would be layed out. Probably side by side, never really tried it, but you don't need to worry about that. Copyrect has am optional frame parameter, you use for selecting which frame of the image, you wish to copy to. |
| ||
That's not what I mean Ross. I've made 80 or so images using the frames flag already - the question is what positions do I copy them to on the bigger image i.e. the one I'm going to save. |
| ||
Side by side would be the simplist. #= image frame ________ |######| |######| -------- You could do it like that. It doesn't matter, as long as their is enough frames. The way in which it works is left to right, then down and back to the left. Like reading text in a book :) |
| ||
Cheers Ross - makes sense. |