Code for PVR capabilities

If you have any questions on programming, this is the place to ask them, whether you're a newbie or an experienced programmer. Discussion on programming in general is also welcome. We will help you with programming homework, but we will not do your work for you! Any porting requests must be made in Developmental Ideas.
Post Reply
q_006
Mental DCEmu
Mental DCEmu
Posts: 415
https://www.artistsworkshop.eu/meble-kuchenne-na-wymiar-warszawa-gdzie-zamowic/
Joined: Thu Oct 10, 2002 7:18 pm
Has thanked: 0
Been thanked: 0
Contact:

Code for PVR capabilities

Post by q_006 »

I read articles and posts that say the PVR is capable of:
Bump Mapping, Fog, Alpha-Bending (transparency), Mip Mapping (polygon-texture auto switch), Tri-Linear Filtering, Anti-Aliasing, Environment Mapping, and Specular Effect.
Does KOS (any versions) have the code to utilize or invoke all of these hardware capabilities? If not, then which ones are available right now?

I would ask for code or functions but I think that would be pushing it....
User avatar
GyroVorbis
Elysian Shadows Developer
Elysian Shadows Developer
Posts: 1874
Joined: Mon Mar 22, 2004 4:55 pm
Location: #%^&*!!!11one Super Sonic
Has thanked: 81 times
Been thanked: 64 times
Contact:

Post by GyroVorbis »

Off the top of my head KOS has

Alpha blending, Trilinear filtering, and (pretty sure anti aliasing)

I know somebody at Boob! (quarn?) managed to do bump mapping, but I don't know if KOS covers that.

Hopefully somebody could elaborate/correct me?
User avatar
Quzar
Dream Coder
Dream Coder
Posts: 7499
Joined: Wed Jul 31, 2002 12:14 am
Location: Miami, FL
Has thanked: 4 times
Been thanked: 10 times
Contact:

Post by Quzar »

i know there were multiple bump mapping demos, but at least one was fully software.
"When you post fewer lines of text than your signature, consider not posting at all." - A Wise Man
User avatar
GyroVorbis
Elysian Shadows Developer
Elysian Shadows Developer
Posts: 1874
Joined: Mon Mar 22, 2004 4:55 pm
Location: #%^&*!!!11one Super Sonic
Has thanked: 81 times
Been thanked: 64 times
Contact:

Post by GyroVorbis »

Okay, while we're talking about bump mapping, could somebody point me to the location of one of these demos?
quarn
DC Developer
DC Developer
Posts: 80
Joined: Wed Oct 17, 2001 7:44 pm
Location: Sweden
Has thanked: 0
Been thanked: 1 time

Post by quarn »

Bump Mapping, Fog, Alpha-Bending (transparency), Mip Mapping (polygon-texture auto switch), Tri-Linear Filtering, Anti-Aliasing, Environment Mapping, and Specular Effect.
Fog, Alpha-blending, Mip Mapping and Tri-Linear filtering is standard in KOS. I think you can easily enable Anti-Aliasing aswell, Although I didn't really see any effect in using it (it's only 2x1 AA).

Environment Mapping, well, AFAIK there is no way to send normals down the pipeline, but if you want something simple it's so easy to calculate the texture coordinates yourself. Just set u = 0.5 + 0.5 * normal.x and v = 0,5 + 0,5 * normal.y.

Specular highlight, use the oargb to set it, but you need to enable some bit in the pvr-header first. I'm not sure if this was ever implemented in KOS or if there was just some demos floating around showing it.

Bump-mapping, yes, I was the first one to figure it out and show how to use it. A (very) simple demo using bump-mapping: http://www.boob.co.uk/files/bump.tar.gz
A tool for creating bumpmaps suitable for the DC from standard heightmaps: http://www.boob.co.uk/files/dcbumpgen.tar.gz
These users thanked the author quarn for the post:
spencer723
c99koder
DC Developer
DC Developer
Posts: 200
Joined: Wed Oct 17, 2001 7:44 pm
Location: East Windsor, NJ
Has thanked: 0
Been thanked: 0
Contact:

Post by c99koder »

I just spent way too much time watching that bump map demo, well done :P

-Sam
Image
Post Reply