1
$\begingroup$

I have a mesh to import of a part designed in Mastercam. I have saved it in Mastercam as an stl file. It is a very complicated mesh so I want to use facets normals so I check the box, but 2.81 throws this error:

bpy.ops.object.select_all(action='DESELECT') bpy.ops.transform.translate(value=(-0, -0, -0.286018), orient_type='GLOBAL', orient_matrix=((1, 0, 0), (0, 1, 0), (0, 0, 1)), orient_matrix_type='GLOBAL', constraint_axis=(False, False, True), mirror=True, use_proportional_edit=False, proportional_edit_falloff='SMOOTH', proportional_size=1, use_proportional_connected=False, use_proportional_projected=False, release_confirm=True) bpy.ops.transform.translate(value=(10.1709, 0, 0), orient_type='GLOBAL', orient_matrix=((1, 0, 0), (0, 1, 0), (0, 0, 1)), orient_matrix_type='GLOBAL', constraint_axis=(True, False, False), mirror=True, use_proportional_edit=False, proportional_edit_falloff='SMOOTH', proportional_size=1, use_proportional_connected=False, use_proportional_projected=False, release_confirm=True) Traceback (most recent call last):   File "C:\Program Files\Blender Foundation\Blender
2.81\2.81\scripts\addons\io_mesh_stl\__init__.py", line 150, in execute
    blender_utils.create_and_link_mesh(objName, tris, tri_nors, pts, global_matrix)   File "C:\Program Files\Blender Foundation\Blender
2.81\2.81\scripts\addons\io_mesh_stl\blender_utils.py", line 55, in create_and_link_mesh
    mesh.show_edge_sharp = True AttributeError: 'Mesh' object has no attribute 'show_edge_sharp'

location: <unknown location>:-1

I have tried to delve into the python files and add 'show_edge_sharp' attributes to the mesh object in the init.py and blender_utils.py files, but this doesn't seem to work.

As far as posting the code goes, I have not as these are just the standard add-on files that come with the install.

Any ideas?

$\endgroup$
4
  • $\begingroup$ HI @Mark, I was playing with this today, 2.81 can certainly import STL, I've tested it today. Try one of these sample STL files. $\endgroup$
    – Moog
    Nov 26 '19 at 17:16
  • $\begingroup$ Hi @Merlin thanks for reply. I have updated the question as I forgot the "facet normal" twist. Does yours work with checking the facet normal box? $\endgroup$
    – Mark
    Nov 26 '19 at 17:23
  • $\begingroup$ Nope, that causes an error for me too. Funny I was going to ask about that :) $\endgroup$
    – Moog
    Nov 26 '19 at 17:28
  • $\begingroup$ Just checked on one of your files, problem here too :-) $\endgroup$
    – Mark
    Nov 26 '19 at 17:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.