| View previous topic :: View next topic |
| Author |
Message |
subbie
Joined: 05 May 2005 Posts: 122
|
Posted: Tue Mar 14, 2006 4:43 am Post subject: GU Sync? |
|
|
Hey guys I have a question. I am having a bit of trouble with this.
I am working on an n64 emu (if you dont already know). Anyways the n64 uses a small 4k buffer for textures. This block of memory is commonly overwriten many times while in the process of drawing a frame. So I am having problems of the memory being over writen before the gu draws the display list. So is there a way to sync the GU so it draws whats in the display list befor continuing? I've tried calling GuSync(0,0) but it locks up and crashes the application (and I guess this is because I just call it vs calling finish and gu start again).
So is there a way to sync the gu without having to flush the the display list and start a new? This sounds like it will be costly do. |
|
| Back to top |
|
 |
Jim

Joined: 02 Jul 2005 Posts: 487 Location: Sydney
|
Posted: Tue Mar 14, 2006 7:28 am Post subject: |
|
|
One way might be to allocate LOTS of 4k textures and have one renderlist.
Jim _________________ http://www.dbfinteractive.com |
|
| Back to top |
|
 |
chp
Joined: 23 Jun 2004 Posts: 313
|
Posted: Tue Mar 14, 2006 6:42 pm Post subject: |
|
|
But that 4k storage is temporary for rendering, isn't it? If you have to decode the texture before sending it to be rendered, you have store store it temporarily somewhere. Synchronizing the GE with the CPU is a BAD idea since you will lose a lot of precious time. Do what Jim suggests and use a big buffer of temporary memoryslots to hold the data prepared for upload. Decoupling the GE and the CPU is one of the most important things you have to accomplish to get good speed. _________________ GE Dominator |
|
| Back to top |
|
 |
subbie
Joined: 05 May 2005 Posts: 122
|
Posted: Wed Mar 15, 2006 1:35 am Post subject: |
|
|
| chp wrote: | | But that 4k storage is temporary for rendering, isn't it? If you have to decode the texture before sending it to be rendered, you have store store it temporarily somewhere. Synchronizing the GE with the CPU is a BAD idea since you will lose a lot of precious time. Do what Jim suggests and use a big buffer of temporary memoryslots to hold the data prepared for upload. Decoupling the GE and the CPU is one of the most important things you have to accomplish to get good speed. |
Thats definantly gonna hurt on the memory side. :( |
|
| Back to top |
|
 |
chp
Joined: 23 Jun 2004 Posts: 313
|
Posted: Wed Mar 15, 2006 3:41 am Post subject: |
|
|
You'll simply have to put a threshold how many textures you can cache before you wait for the GE to finish working. _________________ GE Dominator |
|
| Back to top |
|
 |
Jim

Joined: 02 Jul 2005 Posts: 487 Location: Sydney
|
Posted: Thu Mar 16, 2006 6:50 am Post subject: |
|
|
I doubt any N64 scene is big enough to fill the PSP's Video memory with different textures - there just wasn't the bandwidth to do that. But since even with only 4kb texture memory people double buffered a couple of 2k textures or used multiple palettes with the same image you might need to copy the previous texture into the new one each time.
I would guess you'll have about 1Mb of PSP video memory to play with - that's 250x4kb textures. At worst you might have to sync 2 or 3 times.
Jim _________________ http://www.dbfinteractive.com |
|
| Back to top |
|
 |
|