Callchain Rendering

Discuss the development of software, tools, libraries and anything else that helps make ps2dev happen.

Moderators: cheriff, Herben

Post Reply
User avatar
emoon
Posts: 91
Joined: Sun Jan 18, 2004 10:03 pm
Location: Stockholm, Sweden
Contact:

Callchain Rendering

Post by emoon »

Here is the deal.

Im about rendering all my stuff building one huge callchain for the dma. Same goes for textures on path3 using mskpath3 to do texture syncing.

The real problem happens if i need to reupload a texture. For each texture i got a offset into the dmachain to change the loacation of the BLITBUF for texture and palette (and mipmaps if used) this is all fine if I only upload once as i cant change any of these values again once rendering is taken place as the texture may (most likely) end up on a diffrent vram location than the previous adress it was on.

One way to solve this issue would be to make a copy of the callchain and use that copy with the new vram location and so on.

The problem for objects is almost the same but its about vu0/1 programs that needs to be called, each object has a mesh, a mesh is simply a bunch of dma/viftags, it allso includes some MSCAL tags that need to be changed in to the correct location of the place it has in microram, same thing goes here as many objects can have the same meshpointer (ie instances of the same mesh in the scene).

One way to deal with this may be to always have a MSCAL to 0 and always make sure that the needed program is always there and sort the objects to be render (after sorting on texture basis) on the vuprog it uses

Anyone got any idea how to deal with this?

.emoon
Post Reply