<div dir="ltr"><div><div><div><div><div>Hello, list! <br></div>I've been struggling for a long time with Mash and how to get a model looking somewhat natural. <br></div>The only way a model will look is either flat shaded or something that looks like transparent, but not quite.. <br><br></div>I have recently extended Mash to also be able to load .STL models in addition to .PLY since this is going to be used for a 3D-printer UI, but my limited knowledge of 3D-graphics, shaders and blend strings has caused my work to come to a halt. <br><br></div>Is there something in the new pipeline API that can cause not visible faces to be drawn as well as the visible ones by default? If I set backface culling to 1 (COGL_PIPELINE_CULL_FACE_MODE_BACK is not exposed for some reason...), then the symptoms disappear, at least for simple model like a cube, more complex models still have some "transparency", perhaps since there are faces facing the camera...<br><br></div><div><div><div><div><div>Or is there something wrong with the shader: <a href="https://github.com/clutter-project/mash/blob/master/mash/mash-light-set.c#L264">https://github.com/clutter-project/mash/blob/master/mash/mash-light-set.c#L264</a><br><br></div><div>See attachments (hopefully) for with/without backface culling. <br clear="all"></div><div><div><div class="gmail_signature"><div dir="ltr">Kind regards, <div>-Elias</div></div></div></div>
</div></div></div></div></div></div>