|
Forum Index : Microcontroller and PC projects : picovga if load few image from sdcard run out of memory
| Author | Message | ||||
| tenij000 Regular Member Joined: 30/05/2025 Location: NetherlandsPosts: 72 |
picovga if load few image from sdcard run out of memory is there a way free up the memory again after you done whit the picture |
||||
| matherp Guru Joined: 11/12/2012 Location: United KingdomPosts: 10965 |
I appreciate this is second language for you, but you need to give us more information in order to help. Do the following. Load image then include MEMORY command. This will show the memory used. Then load another image and run MEMORY. You shouldn't see the memory usage increasing unless there is a memory leak that needs fixing. I don't see any sign of a memory leak in my testing so it may be something your program is doing. If you do see memeory increasing please post the images that cause the problem as it may be something to do with the specific encoding used. |
||||
| JohnS Guru Joined: 18/11/2011 Location: United KingdomPosts: 4244 |
Probably a good idea to post a small program to show the problem. And ZIP with images if not too big for the forum. John |
||||
| JulesO Newbie Joined: 08/09/2025 Location: FrancePosts: 19 |
It's weird i'm working on a small game that uses lot of .bmp (that I've not optimized at all) and I dont meet that problem. How do you use images inside the code ? |
||||
| Volhout Guru Joined: 05/03/2018 Location: NetherlandsPosts: 5703 |
Hi JulesO, Below work is not mine, I just share it here since it gives an idea how you can work with pictures in a program. It is a start of a graphics adventure. Unzip it and run cca5.bas on a picomiteVGA. cca.zip The essence of showing pictures is in "ccapictures.bas". Volhout P.S. this work is from Martin.H here at this forum. If you are impressed, send him the compliments. P.P.S. in picomite 6.02.00 you can also use JPG images. Edited 2026-02-03 00:39 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
| JulesO Newbie Joined: 08/09/2025 Location: FrancePosts: 19 |
Hi Volhout, Thanks, it really is impressive indeed, i "almost" understand it but it actually goes beyond what I need for my small project. I kind of "reinvent" the wheel (with chatgpt) so I "have" a function to "list" rooms and display text + bmp + events happening in the room BUT with spaghetti code (but for 9 rooms < 350 lines of codes) I’ll share what will be more of a quick 'demo' of the idea I had in mind very soon! Edited 2026-02-03 05:32 by JulesO |
||||
| Martin H. Guru Joined: 04/06/2022 Location: GermanyPosts: 1357 |
@tenij000 First of all, you should add a sample file or provide the details: height, width, how it was saved (4, 8, 24 bits), with or without RLL compression? All of this would make it much quicker to provide helpful answers; as it is, we are all just groping in the dark. Cheers Martin Edited 2026-02-03 22:50 by Martin H. 'no comment |
||||
| The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2026 |