| View previous topic :: View next topic |
| Author |
Message |
subbie
Joined: 05 May 2005 Posts: 122
|
Posted: Tue Apr 04, 2006 3:04 pm Post subject: strange 3d issue (please help) |
|
|
Is there any special reason or case why sending a triangle list as GU_TRANSFORMED_2D would work yet sending them as GU_TRANSFORMED_3D would not?
Now before you say its a matrix problem. Consider this. I directly ripped an put the cube code into my code. So insted of running my stuff it instantly runs the cube demo (including the cube psp setup code). Yet I get the exact same issue (3d wont work but 2d does).
Any though on this? |
|
| Back to top |
|
 |
__count
Joined: 23 Mar 2006 Posts: 22
|
Posted: Wed Apr 05, 2006 2:32 am Post subject: |
|
|
Define 'wont work'. You don't see anything?
If so, I say its likely a Z-buffer, culling or a matrix transform issue.
Z-buffer seems especially likely since that could be caused by your gu init code.
Also try to memset your display list to 0 before you run your app. |
|
| Back to top |
|
 |
subbie
Joined: 05 May 2005 Posts: 122
|
Posted: Wed Apr 05, 2006 2:46 am Post subject: |
|
|
| __count wrote: | Define 'wont work'. You don't see anything?
If so, I say its likely a Z-buffer, culling or a matrix transform issue.
Z-buffer seems especially likely since that could be caused by your gu init code.
Also try to memset your display list to 0 before you run your app. |
It's definantly not a Z issue because like I said. I pasted the full cube demo into my files and ran the cube demo at the start and did not run anything else. Yet still I get no 3d.
It seems like a memory issue where my display list is located maybe? I dont get why. I tried recoding the main (starting from scrach) and I got 3d going but once I started to add more of my old files back it went back to breaking the 3d again (and this was still by running the sample code and not mine).
--edit--
Wont Work == No triangles show on screen when I do GumDrawArray with 3d_Transoformation flag set. Yet if I set 2D_transormation flag I get polygons on screen. |
|
| Back to top |
|
 |
fish
Joined: 08 Feb 2006 Posts: 25
|
Posted: Wed Apr 05, 2006 5:08 am Post subject: |
|
|
Could be a lot of things really,
What direction is culling set to? try turning it off totally.
Can you render the cube then call your function and see anything?
Does your function(s) change or set any flags or states?
That's only a few of the more common things that it could be, post some code and maybe you'll be able to get a more specific answer. |
|
| Back to top |
|
 |
memon
Joined: 03 Oct 2005 Posts: 63
|
Posted: Wed Apr 05, 2006 5:15 am Post subject: |
|
|
| Drawing black triangles on black background? Maybe you just have the lighting turned on, and you specify no normals or no lights, and suddenly they start to affect when rendering in 3D? IIRC the 2D mode does support lighting, where the 3D definitely does. What is the size of your triangles and how you set your matrices? I think it wouild help if you would show how you pass your data and how you initialise your rendering. |
|
| Back to top |
|
 |
subbie
Joined: 05 May 2005 Posts: 122
|
Posted: Wed Apr 05, 2006 7:48 am Post subject: |
|
|
Heh, I dont think people understod what I ment.
In my Main(), Insted of calling my code. I directly call the Cube demo code. None of my code is executed. If the cube demo works, Mine should to.
My only assumptions is it has something to do with static varibles in the project or maybe allignment. |
|
| Back to top |
|
 |
|