Free Add-on for Blender
Scrubs started this discussion in Model Export and Render
Avatar of Scrubs
Administrator

Mecabricks Add-on for Blender

About this thread
You will find in this section everything needed to easily make photorealistic renderings of Mecabricks models with Blender.

Software and files needed
Blender
Blender Add-on by Mecabricks
• Environment images [e.g. zbyg Packs]

More…
653 replies · Page 4 of 33

That seemed to fix the problem, thanks!

I have a pretty simple export with 4 minifigs and nothing else, but the decorations (just faces and shirts) aren't loading in Blender, and when I open the drop down in the materials menu to try to select another png file, Blender is crashing immediately. I've tried this on two different computers now with the same result! Is there something simple I'm missing? And thanks for all your work on this, you've made something amazing here!

I have successfully brought many models into blender and run the script however, once the script has been run once, I can't seem to be able to run it again when I have imported another .dae even when selecting the parent and all children of the 2nd import.

I have looked through the code and can't seem to see any reason why it wouldn't work a second time. I also tried changing this variable from
parent = bpy.data.objects['Model']
to
parent = bpy.data.objects['name_of_new_parent']

All I get is the "python script fail: check in the console for now", in the console there is nothing to be seen.

Any thoughts on how to run it again? Has anyone been able to import 2 seperate models or run the script twice?

Avatar of Scrubs
Administrator

I did not try it but I am pretty sure it is an issue with material naming.
First because some material names might already exist ('cycles_xxx')
Secondly because material name parsing might fail when the loop is run a second time.

for mat in materials:
    
    splitName = mat.name.split('_', 1)
    
    # Colour material
    if splitName[0] == 'Colour':
        
        # Colour ID
        colour = colours[splitName[1]]
        
        # Create replacement material
        matTemplate = materials[colour['type']]

Hi and thank you for this tutorial.

I'm searching how to add a background image, a world image but I can't find how.

Can someone help me please.

Thanks.

I'm doing my first steps in blender. I only opened the 1.05 template but all those 1x1 bricks are tinted pink in the render preview window. I googled about this issue and found lots of articles about missing textures and I should try File / External data / Find missing files. In the system console window only appears the following message:

WARNING: attempting to set parameter with wrong type: Normal (exepected 'normal', 'received 'point')

For me it doesn't seem to be a missing file problem. Can someone guide me in the right direction? I'm lost in all those blender checkboxes 😦 I'm using the 64-bit blender version 2.74 in Windows 10.

Hi Hogi! It's a simple problem 😃
You don't have any Environment Texture setted, so Blender says: "There's something missing! 😮 ".

Just go to the Node Editor, then click on the icon of the World 🌏 , you'll see the Environment Texture node. Now you have to click on Open 📁 and use the HDR file you want.

You can find a lot of environment images here 😉

Avatar of Scrubs
Administrator

Hello, it is pinkish because you did not select an hdri image that is used to light the scene. I did not provide any in the template. Just follow the link in the first post to download a nice pack and check the part about lighting in my youtube tutorial 😉

Avatar of Scrubs
Administrator

Oh zanna beat me on this one and was even more helpful 😉

Got it. The pink is gone. Thanks zanna and Scrubs for your support.

Hi everyone! So, I followed the tutorial step by step - but with any of the sets that I built, when I click on 'run script' it says "python script fail: check in the console for now". The rendered bricks also don't have any reflection/shine to them. Do I have to put certain parameters in the workshop to allow this, or is it something to do with Blender (or something else entirely)? I'm using Blender v2.74 on Windows 10 64-bit, if that info helps

Avatar of Scrubs
Administrator

Not too sure. No you don't have anything special to do in the workshop. Did you export in collada? Did you add all the pieces in the "Model" group? You can only run the script once. After that it will throw errors.

Sometimes the script faits for some reasons.
Did you grouped all the pieces together with the plain axes called Model?
Have you renamed or move any folder downloaded from Mecabricks?
Can you upload a screenshot of your Blender window and another one of your files?
😉

(edit: this time Scrubs stole a march on me 😛 )

Ah, that's it - I forgot to add to the "model" group. It's working great now! Thanks 😄

Hello I just joined this website last night to blender some photos. When I go to export the file in Collada .dae file it says my browser does not support that function. What can I do to fix that? 😄

Avatar of Scrubs
Administrator

Hello, use another browser. I assume that you are using Safari that does not support this function. Chrome/Chromium and Firefox are working well to export.

Ok does that include Google Chrome. Currently I am using Internet Explorer. Anyway thanks for the help. I am trying to figure out this whole website and blender. 😄

Avatar of Scrubs
Administrator

Everything else other than Safari and Internet Explorer shall work to export the models 😉

Awesome! Your help is greatly appreciated. Now I must watch your video then start the process. 😄

Avatar of Scrubs
Administrator

Looking forward to seing you renders!

Advertising
160 participants
Avatar of Scrubs
Avatar of NGCHunter2
Avatar of wlange
Avatar of ArmoredBricks
Avatar of Masman8675
Avatar of StepsiPepsi
Avatar of LoneCoyote
Avatar of zanna
Avatar of SaitoGray
Avatar of LukeSkywalker
Avatar of _deleted_
Avatar of TheGecko7
Avatar of UmbraManis
Avatar of Legosim
Avatar of Sealund
Avatar of adambrickover
Avatar of MARTIXTAPEATTACKER
Avatar of kl3w_lego
Avatar of [deleted]
Avatar of SiMaI
Avatar of nu_montag
Avatar of dtriangle
and others

LEGO, the LEGO logo, the Minifigure, and the Brick and Knob configurations are trademarks of the LEGO Group of Companies. ©2024 The LEGO Group.

Mecabricks, the Mecabricks logo and all content not covered by The LEGO Group's copyright is, unless otherwise stated, ©2011-2024 Mecabricks.