The best way to save multiple images? - Printable Version +- Qbasicnews.com (http://qbasicnews.com/newforum) +-- Forum: Qbasic "like" compilers/interpreters (http://qbasicnews.com/newforum/forum-5.html) +--- Forum: FB Discussion & Programming Help (http://qbasicnews.com/newforum/forum-15.html) +--- Thread: The best way to save multiple images? (/thread-9057.html) |
The best way to save multiple images? - wallace - 03-22-2006 If you have seen my site recently you know that I am working on my sprite editor, which can have up to 200 frames each. I need a good way to save them together. Each image can be a different size, and there is no way of knowing beforehand how many frames there will be (1 - 200). I have many thoughts.: 1) BSAVEing every single one into one sprite file. 2) BSAVEing each image into a bitmap and saving the path to the bitmap in the sprite file. 3) stacking multiple images into bitmaps, creating less of them with more images in each and saving the paths and positions into the sprite file. 4) stacking all images into one bitmap and saving just one path and positions and sized in the sprite file. each has advantages and disadvantages. I need to have a nice balance of simplicity, speed, and memory usage. Which do you think is best? Is there another way? The best way to save multiple images? - Anonymous - 03-23-2006 i save all pics from ll into seperate bmps, each bmp includes all frames for that one object, then i store a header with the data, saying the frame x/y size and the number of frames in the image. works fine. The best way to save multiple images? - DirkFist - 03-23-2006 how bout collecting the frames of the animation into a single file ? animation header number of frames pointer to frame headers ' . . . this is just a placeholder version ' . . . for backward compatibility frame header(0) stuff offset/pointer to frame(0) data frame header(1) . . . frame header(number of frames) frame(0).data frame(1).data etc . . . This demonstrates loading an animation saving left as excersize for the reader Code: type image_header field=1 |