Rockbox.org home
Downloads
Release release
Dev builds dev builds
Extras extras
themes themes
Documentation
Manual manual
Wiki wiki
Device Status device status
Support
Forums forums
Mailing lists mailing lists
IRC IRC
Development
Bugs bugs
Patches patches
Dev Guide dev guide
Search



Donate

Rockbox Technical Forums


Login with username, password and session length
Home Help Search Staff List Login Register
News:

Welcome to the Rockbox Technical Forums!

+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Theming and Appearance Customization
| | |-+  Is there any way to tell how much memory a theme is taking up?
« previous next »
  • Print
Pages: [1]

Author Topic: Is there any way to tell how much memory a theme is taking up?  (Read 2891 times)

Offline akadewboy

  • Member
  • *
  • Posts: 22
Is there any way to tell how much memory a theme is taking up?
« on: September 11, 2007, 06:28:36 PM »
I'm trying to code a memory efficent WPS theme, and I was wondering if there's anyway to tell how much memory a particular WPS takes up.
Logged

Offline Bagder

  • Member
  • *
  • Posts: 1452
    • Daniel's site
Re: Is there any way to tell how much memory a theme is taking up?
« Reply #1 on: September 11, 2007, 06:48:29 PM »
All WPSes use the exact same amount of memory since the buffers reserved in Rockbox are fixed-size...
Logged

Offline akadewboy

  • Member
  • *
  • Posts: 22
Re: Is there any way to tell how much memory a theme is taking up?
« Reply #2 on: September 12, 2007, 05:05:59 AM »
Oh ok I guess I can be as sloppy as I want then  ;)

One more question, do transparent pixels (255, 0, 255) in images fill up the buffer and take up memory or are they just skipped over?
Logged

Offline bascule

  • Rockbox Expert
  • Member
  • *
  • Posts: 1298
Re: Is there any way to tell how much memory a theme is taking up?
« Reply #3 on: September 12, 2007, 05:45:41 AM »
Quote from: akadewboy on September 12, 2007, 05:05:59 AM
Oh ok I guess I can be as sloppy as I want then  ;)

Well, no you can't, because if you exceed the buffer, you will just lose your WPs content after that point. For example:

The first picture is my current WPS. If I replace the standard progress bar with a text-based one using %?px, then I start to lose some of the graphics ...

[attachment deleted by admin for age]
Logged
DataBase fanboy and author of the totally overhauled Rockbox Sync Tool

Offline akadewboy

  • Member
  • *
  • Posts: 22
Re: Is there any way to tell how much memory a theme is taking up?
« Reply #4 on: September 12, 2007, 06:01:57 AM »
Yes I understand that, but if my WPS works fine now, there's no reason for me to go over it with a fine tooth comb to make it more memory efficent. I'll just leave it all sloppy.

I'm still curious if transparent pixels are loaded into memory or just skipped over. Anyone know the answer?
Logged

Offline Bagder

  • Member
  • *
  • Posts: 1452
    • Daniel's site
Re: Is there any way to tell how much memory a theme is taking up?
« Reply #5 on: September 12, 2007, 06:33:58 AM »
A pixel is still a pixel and since BMP files are loaded as whole entities it doesn't matter if they are treated as transparent or not. They take the same amount of memory.
Logged

Offline Multiplex

  • Member
  • *
  • Posts: 440
Re: Is there any way to tell how much memory a theme is taking up?
« Reply #6 on: September 23, 2007, 06:34:04 AM »
Quote from: Bagder on September 12, 2007, 06:33:58 AM
A pixel is still a pixel and since BMP files are loaded as whole entities it doesn't matter if they are treated as transparent or not. They take the same amount of memory.
Does this mean that the coulour depth of the BMP doesn't matter?

I'm trying to fix up a WPS that runs out of image memory - all the BMPs are 24 bit, I was wondering if I could save memory by saving them as 16 or 8 bit, with pallette (not that I've worked out how yet)

I'm assuming that the images are stored in the native format format for the LCD so this won't help but if it will I should do it.

Edit: just revisited the WPS wiki page and it seems only 24bit or 1 bit is permitted... any other ideas are welcome...
« Last Edit: September 23, 2007, 06:40:58 AM by Multiplex »
Logged

Offline Multiplex

  • Member
  • *
  • Posts: 440
Re: Is there any way to tell how much memory a theme is taking up?
« Reply #7 on: September 24, 2007, 08:40:28 AM »
To find out when images were not loading I used the simulator and its wpsdebug option as detailed herehttp://forums.rockbox.org/index.php?topic=12858.msg97260#msg97260 it tells you when images are not loaded due to space limitations (or typos in the filename ;-)

I can write up some notes on how I got the space requirements down for the WPS I was working on if folks want.
Logged

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Theming and Appearance Customization
| | |-+  Is there any way to tell how much memory a theme is taking up?
 

  • SMF 2.0.17 | SMF © 2019, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.088 seconds with 16 queries.