# Blender does not render OBJ and MTL import

I am trying to render a set of lines through an OBJ file and the matching MTL file. The import does not give an error and the MTL seem to be correctly imported. But the render image is empty. I am a noob to blender and any help is highly appreciated. I have attached the links to the files below. Thanks.

• You have to create proper materials for the imported objects, MTL materials are temporary stubs for placeholder basic texturing, not final materials. You can't rely on them for actual production images. Also what do you mean "render a set of lines through an OBJ" you can't really render just lines, there has to be actual renderable geometry to be able to produce images. – Duarte Farrajota Ramos Oct 25 '16 at 22:42
• – Duarte Farrajota Ramos Oct 25 '16 at 22:44

Your object only consists of connected vertices, it does not have any faces.

Blender needs faces to render an image.

• The object is a set of lines. If I delete the MTL file links from the OBJ file, I can add a single color to the whole object and render that. Also, if I put a environment light, will it help? – ssm Oct 25 '16 at 22:57
• As I said, you need faces to get something to render. Vertices and lines aren't enough. Try it. Take the cube of the default scene, go to edit mode, hit "A" to select everything, then "X" and select "only Faces". Add a material and try to render that. Nothing will appear. No faces, no geometry to get light bounces from, no image. – metaphor_set Oct 26 '16 at 0:37
• Hi, I can get something to bounce light if I select the material as wire. Am I wrong? And I can render that and get a color. – ssm Oct 26 '16 at 13:08

I was able to get a render out of the OBJ and MTL file finally by following the folowing steps. Granted I had to modify the OBJ file tool. OBJ modification: Add g mtl_i above each usemtl mtl_i line.

I also used the following script in blender to change material properties.

for i in D.objects:
if i.name.startswith('mtl'):
i.active_material.type='WIRE'
i.active_material.use_transparency=True
i.active_material.alpha=0.4
i.active_material.transparency_method='Z_TRANSPARENCY'