Page MenuHome

Remesh-triangulation and transparency do NOT go together
Closed, ArchivedPublic

Description

Windows 7 (x64)
ATI Radeon HD 5800

When a remesh modifier and a triangulating one is applied to an object, it looks meshed up if it is transparent. I am providing you a simple script to get my point across.

import bpy

bpy.ops.mesh.primitive_monkey_add()
monkey=bpy.context.scene.objects[0]

remesh=monkey.modifiers.new('Remesh','REMESH')
remesh.mode='SMOOTH'
remesh.octree_depth=6 # e.g
bpy.ops.object.modifier_apply(apply_as='DATA', modifier='Triangulate')

triang=monkey.modifiers.new('tria','TRIANGULATE')
bpy.ops.object.modifier_apply(apply_as='DATA', modifier='Triangulate')

mastermat=bpy.data.materials.new("Master")
mastermat.diffuse_color=[0.75,0.7,0.4]
mastermat.diffuse_intensity=1
mastermat.use_transparency=True
mastermat.alpha=0.65
monkey.show_transparent=True
monkey.data.materials.append(mastermat)

Why does the object look like that? It is as if the color is applied to a part of the mesh.. Hope i helped. Thank you.

Event Timeline

This looks as expected to me. Viewport transparency is dependent on Z-order, and there's no guarantee from these operations that you'll have a good Z order.

If you apply the modifiers, you can sort the elements with the editmode "Sort Mesh Elements" operator (make sure to sort faces).

Nicholas Bishop (nicholasbishop) changed the task status from Unknown Status to Archived.Jan 26 2013, 6:32 PM