Jump to content

  • Log In with Google      Sign In   
  • Create Account

Interested in a FREE copy of HTML5 game maker Construct 2?

We'll be giving away three Personal Edition licences in next Tuesday's GDNet Direct email newsletter!

Sign up from the right-hand sidebar on our homepage and read Tuesday's newsletter for details!


Mesh unhoped-for transparency.


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 ab_saratov   Members   -  Reputation: 104

Like
0Likes
Like

Posted 01 April 2013 - 12:44 AM

Hello

I'm learning to load meshes from files.

My problem is that my result has some unhoped-for transparency.
Well, sorry for my English, I'll better show it in pictures.

Right picture- is how it should be(from DirectX SDK Viewer), and left – is what I have.

carbi.jpg
Why tires are always full visible?
I realized that it is unrelated to Lights and unrelated to different material types. Same problems with meshes containing only one material, some planes are visible trough others.

Help please. Any directions about what's could be wrong? Or what did I forget?



Sponsor:

#2 Paradigm Shifter   Crossbones+   -  Reputation: 5405

Like
1Likes
Like

Posted 01 April 2013 - 02:38 AM

Looks like you are culling the wrong winding order of polygons... change your cull mode to the oposite one. Make sure all your meshes have consistent winding order as well otherwise weird reults like that can happen as well (turn backface culling off to test that, should look the same with and without back face culling). Note that using a transform matrix with negative determinant also flips the winding order (typically if you mirror an object).

 

Could also be you disabled the depth buffer but I think the cull mode is most likely.


"Most people think, great God will come from the sky, take away everything, and make everybody feel high" - Bob Marley

#3 ab_saratov   Members   -  Reputation: 104

Like
0Likes
Like

Posted 01 April 2013 - 03:25 AM

Solved.

Thanks.

I've disabled Z-buffer.

Not disabled in fact, but disrupted it work by setting ZnearPlane =0, when setting Perspective. I thought it is ok. but it's not.

Me doing it wrong. smile.png






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS