strange 3d issue (please help)

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
subbie
Posts: 122
Joined: Thu May 05, 2005 4:14 am

strange 3d issue (please help)

Post by subbie »

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?
__count
Posts: 22
Joined: Thu Mar 23, 2006 8:40 pm

Post by __count »

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.
subbie
Posts: 122
Joined: Thu May 05, 2005 4:14 am

Post by subbie »

__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.
fish
Posts: 25
Joined: Wed Feb 08, 2006 5:12 am

Post by fish »

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.
memon
Posts: 63
Joined: Mon Oct 03, 2005 10:51 pm

Post by memon »

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.
subbie
Posts: 122
Joined: Thu May 05, 2005 4:14 am

Post by subbie »

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.
Post Reply