This is more of a question for Falco, or any other DC Devver.
I finally found out how to load and display graphics and move them around with user input. Now I need to make sure I'm not using too much memory the way I display these graphics.
So my question is, how do I display the RAM and VRAM usage on the Dreamcast?
Thanks,
~EpicAsian
Printing out the RAM and VRAM usage on Dreamcast?
Moderator: Coders of Rage
- Falco Girgis
- Elysian Shadows Team
- Posts: 10294
- Joined: Thu May 20, 2004 2:04 pm
- Current Project: Elysian Shadows
- Favorite Gaming Platforms: Dreamcast, SNES, NES
- Programming Language of Choice: C/++
- Location: Studio Vorbis, AL
- Contact:
Re: Printing out the RAM and VRAM usage on Dreamcast?
I'll have to get back to you on that.
There is a simple pvr_get_vram() call or something you can make. Maybe you can find it faster than I can?
I believe there's also a way to check how much has been allocated on the heap at runtime... I don't think there's anything for the stack, but you can always subtract an offset from your main for a decent approximation and add that to your heap allocated space...
There is a simple pvr_get_vram() call or something you can make. Maybe you can find it faster than I can?
I believe there's also a way to check how much has been allocated on the heap at runtime... I don't think there's anything for the stack, but you can always subtract an offset from your main for a decent approximation and add that to your heap allocated space...
- epicasian
- Chaos Rift Junior
- Posts: 232
- Joined: Mon Feb 22, 2010 10:32 pm
- Current Project: Gigazilla Engine
- Favorite Gaming Platforms: Dreamcast, SNES, PS2, PC
- Programming Language of Choice: C/++
- Location: WoFo, KY
Re: Printing out the RAM and VRAM usage on Dreamcast?
How did you print out the VRAM usage, poly and texture count in episode 15.5? Or was that build never working on Dreamcast?
~EpicAsian
~EpicAsian
- Falco Girgis
- Elysian Shadows Team
- Posts: 10294
- Joined: Thu May 20, 2004 2:04 pm
- Current Project: Elysian Shadows
- Favorite Gaming Platforms: Dreamcast, SNES, NES
- Programming Language of Choice: C/++
- Location: Studio Vorbis, AL
- Contact:
Re: Printing out the RAM and VRAM usage on Dreamcast?
I knew the VRAM usage, because I was loading every image as a 16-bit PNG. So each image became width * height * 2 (16 bits = 2 bytes) bytes.epicasian wrote:How did you print out the VRAM usage, poly and texture count in episode 15.5? Or was that build never working on Dreamcast?
~EpicAsian
I found out later that KOS actually had some kind of functionality for returning it. That VRAM-o-meter also didn't take into account the fact that the framebuffer is a 1024 x 1024 texture eating something like 4MB of VRAM...