 |
forums.ps2dev.org Homebrew PS2, PSP & PS3 Development Discussions
|
| View previous topic :: View next topic |
| Author |
Message |
Calv!n

Joined: 13 Aug 2007 Posts: 10
|
Posted: Wed Oct 28, 2009 11:57 am Post subject: Mipmapping |
|
|
Ok, so I'm not sure what the deal with mipmapping on psp is, but it seems to have its own special way of doing things.
First off let me say I've been searching through the forums thoroughly to find any help and it looks like mipmapping has be a recurring problem.
I'm using 3 different texture levels. 128x128, 64x64, and 32x32. Each texture has a different color with its texel width/height stamped on the textures. I did this to help visually see the mipmapping taking affect, but the only texture I'm seeing is the 32x32.
My code:
| Code: |
sceGuColor(0xffffffff);
sceGuPatchDivide(u, v);
sceGuTexFunc(GU_TFX_MODULATE, GU_TCC_RGB);
sceGuTexFilter(GU_LINEAR_MIPMAP_LINEAR, GU_LINEAR_MIPMAP_LINEAR);
sceGuTexScale(1.0f, 1.0f);
sceGuTexOffset(0.0f, 0.0f);
sceGuTexWrap(GU_REPEAT, GU_REPEAT);
sceGuTexLevelMode(GU_TEXTURE_SLOPE, 0.0f);
sceGuTexSlope(0.3f);
sceGuTexMode(GU_PSM_8888, 2, 0, 0);
selectTgaTexture(texture_128);
sceGuTexImage(0, texture_128->imageWidth, texture_128->imageHeight, texture_128->imageWidth, texture_128->image);
selectTgaTexture(texture_64);
sceGuTexImage(1, texture_64->imageWidth, texture_64->imageHeight, texture_64->imageWidth, texture_64->image);
selectTgaTexture(texture_32);
sceGuTexImage(2, texture_32->imageWidth, texture_32->imageHeight, texture_32->imageWidth, texture_32->image);
sceGumDrawBezier(GU_VERTEX_32BITF|GU_TEXTURE_32BITF|GU_TRANSFORM_3D, 4, 4, 0, bpatchArray[i].nodes);
|
It would be a great help if someone could explain to me what is incorrect and why. Thanks for the forums and the help. :) _________________ http://jj.iamjunkie.net/ |
|
| Back to top |
|
 |
a_noob
Joined: 17 Sep 2006 Posts: 97 Location: _start: jr 0xDEADBEEF
|
Posted: Fri Oct 30, 2009 2:23 am Post subject: |
|
|
sceGuTexLevelMode(GU_TEXTURE_SLOPE, 0.0f);
I know that that line may cause problems, because the 0.0f means use 0% of the slope, so in effect it would never change. However when I tried making my own small sample the mip mapping still didn't work. Also what does selectTgaTexture do?? Thats all I can see. Hmm maybe someone else has a better answer. _________________
| Code: | .øOº'ºOø.
'ºOo.oOº' |
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|