Author Topic: [solved] blender exporter & an older scene  (Read 8634 times)

2016-10-20, 01:46:16

burnin

  • Active Users
  • **
  • Posts: 924
    • View Profile
Am doing a revision on an exemplary test scene provided by chocofur.com to be concurrent with latest releases (Blender, Corona SA) but have stumbled upon a deal breaker. Doesn't render, tho with Material Override it does.

Error:

Code: [Select]
Traceback (most recent call last):
  File "C:\Users\UserName\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\engine.py", line 353, in render
    render_start( self, scene)
  File "C:\Users\UserName\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\engine.py", line 38, in render_start
    render_scene( engine, scene)
  File "C:\Users\UserName\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\engine.py", line 189, in render_scene
    bpy.ops.corona.export_mat()
  File "C:\Programs\b278\2.78\scripts\modules\bpy\ops.py", line 189, in __call__
    ret = op_call(self.idname_py(), None, kw)
RuntimeError: Error: Traceback (most recent call last):
  File "C:\Users\UserName\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\operators\export.py", line 117, in execute
    write_mtl( root, default_mat, mat, None, mtl_mat_name, True)
  File "C:\Users\UserName\AppData\Roaming\Blender Foundation\Blender\2.78\scripts\addons\render_corona\outputs.py", line 233, in write_mtl
    addTexture(xml_col, crn_map.map_ke)
NameError: name 'crn_map' is not defined

location: C:\Programs\b278\2.78\scripts\modules\bpy\ops.py:189



location: <unknown location>:-1


Any help appreciated...


source:   
Corona & Blender (Setting & Rendering with Corona)

         
« Last Edit: 2016-11-20, 21:55:02 by burnin »

2016-10-21, 05:33:06
Reply #1

burnin

  • Active Users
  • **
  • Posts: 924
    • View Profile
No worry, don't hurry... ;) Guess it doesn't matter anymore.
So since i couldn't find a culprit, have decided to just go through the whole thing.
... re-do to fit the present situation.

Tho if anyone's got a clue, i'd be happy to know

bye bye
« Last Edit: 2016-10-21, 05:37:36 by burnin »

2016-10-24, 00:49:03
Reply #2

jKLman

  • Active Users
  • **
  • Posts: 66
    • View Profile
It is more of a change in the Blender API rather than a bug I think (scene is done in Blender 2.72 compared to the new version 2.78.
A lot of update need to be done in the corona blender integration, one is the material and the other one is ies support.Update also to Corona standalone
had bring this new "bug" as you call it.

Though the blender exporter is working when you do a new scene in Blender 2.78, but not in an old scene. ;)
"Jack of all trade, but messing up with 3D"
Blender 2.78 Corona Standalone 1.5 / 2016-10-24 Alpha
Win 10 64bit

2016-10-24, 03:43:37
Reply #3

burnin

  • Active Users
  • **
  • Posts: 924
    • View Profile
Hi,
Yes, had suspected same as you note, as i tried to get something viable with it.
Got IES disabled & found the other missing feature that's causing error in this case - textures on emitters.
Also there are no light/emission material nodes and lots more to do.

Am checking & correcting this scene as is ready & freely available, to give back in hope there will be some more exposure, help and testing on the way. Since things are going slow on the front, yet do look promising.
As there's no IPR in SA, got set @24 samples + pinch of denoise. Fast preview...

2016-10-26, 07:42:46
Reply #4

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 412
    • View Profile
    • Blender exporter for Corona
Hi @burnin,

Apologies I have only just seen this now.  I have created an issue and provided a fix https://bitbucket.org/coronablender/render_corona/issues/34/crn_map-material-bug

Thanks for reporting!


2016-10-27, 17:02:19
Reply #5

burnin

  • Active Users
  • **
  • Posts: 924
    • View Profile
Hi, no problem... thanks for looking into it. I really appreciate your work.

I also noticed that corona node trees are not connected (selected) along with Material selected in Properties.
i.e. If a material that has node tree assigned is selected, user has to find&select that node tree in the Node editor also for further manipulation... making it easy & prone to human mistakes (by editing different node tree) if not being extra careful. Also renaming a tree disconnects it from the material.
With huge material list, this soon becomes very distracting & counterproductive.
Is it by design? If anything can be done about it would be more than welcome, thinking it's a big turnoff for starters.
While in LuxRender & RenderMan nodetree selection works per material selected.

Thanks again for everything
:)


2016-11-05, 05:16:44
Reply #7

jKLman

  • Active Users
  • **
  • Posts: 66
    • View Profile
Hi @blanchg

Reflection is not updating correctly as you can see from the image below.
When I increase fresnel value then reflection shows.
Is this suppose to be the correct reflection behavior?...or need to fix it in the exporter?

Thank you.

"Jack of all trade, but messing up with 3D"
Blender 2.78 Corona Standalone 1.5 / 2016-10-24 Alpha
Win 10 64bit

2016-11-06, 22:15:27
Reply #8

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 412
    • View Profile
    • Blender exporter for Corona
I believe that is the behavior of Corona.  The chocofur website has some amazing material content http://www.chocofur.com/5-materials.html with some solid base material types that work great with Corona


2016-11-07, 01:56:22
Reply #10

jKLman

  • Active Users
  • **
  • Posts: 66
    • View Profile
Thanks for that references that follows major rendering engines.
What I am actually looking for is that when you adjust reflection value
without touching fresnel you can already see a default sheen that the material
is reflecting.

Of couse fresnel is just going to kick in when you increase or lower its value.
Hope it makes sense. Not really a major thing.

"Jack of all trade, but messing up with 3D"
Blender 2.78 Corona Standalone 1.5 / 2016-10-24 Alpha
Win 10 64bit

2016-11-07, 21:50:20
Reply #11

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 412
    • View Profile
    • Blender exporter for Corona
Do you mean the default reflection Fresnel value should be higher so that you can see the reflection immediately?

2016-11-08, 00:47:33
Reply #12

jKLman

  • Active Users
  • **
  • Posts: 66
    • View Profile
Do you mean the default reflection Fresnel value should be higher so that you can see the reflection immediately?

Ok I got it, we are using a general CoronaMtl here that is why all the values are default to diffuse material.
To get glossy, glass, etc one need to key-in all the values that corresponds to material type.

Sorry for that. Preset will be helpful specially that there is no documentation at the moment (feature request).
Thanks.



"Jack of all trade, but messing up with 3D"
Blender 2.78 Corona Standalone 1.5 / 2016-10-24 Alpha
Win 10 64bit

2016-11-10, 13:11:27
Reply #13

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 412
    • View Profile
    • Blender exporter for Corona
Yes exactly, apologies,  Having some sample materials was one of the first things I identified as needing attention (https://bitbucket.org/coronablender/render_corona/issues/4), though getting all the features working first has taken priority.

The creator of chocofur has kindly given me permission to include some of his base material setups in the exporter, that should happen fairly soon.

2016-11-11, 08:40:28
Reply #14

jKLman

  • Active Users
  • **
  • Posts: 66
    • View Profile
That will be great!

Well understood if you are following a roadmap.
We can wait for certain feature integration.

At the moment we will play around with the latest update.
Thanks....
"Jack of all trade, but messing up with 3D"
Blender 2.78 Corona Standalone 1.5 / 2016-10-24 Alpha
Win 10 64bit

2016-11-12, 02:43:12
Reply #15

jKLman

  • Active Users
  • **
  • Posts: 66
    • View Profile
Corona Blender  rocks!
Just some few items to mention.
1. emission texture is not working. Should this be show in the coronamtl properties or coronalight properties?
2. Ray Invisibility is missing or disabled. Previously this is working.
"Jack of all trade, but messing up with 3D"
Blender 2.78 Corona Standalone 1.5 / 2016-10-24 Alpha
Win 10 64bit

2016-11-12, 13:14:17
Reply #16

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 412
    • View Profile
    • Blender exporter for Corona
Excellent tests.

The node versions of the materials are much more tested usually but I will fix any issues you find asap. 

Ray invisibility will be removed from the simple material panel as it can't be easily supported there.  It is supported through the node tree.

Keep the issues coming

2016-11-12, 13:41:11
Reply #17

jKLman

  • Active Users
  • **
  • Posts: 66
    • View Profile
I will take a look at the material node system again, I was trying to enable it but could not
find the material node system or could not enable it? Any idea?
When I click node material at material properties, it does not shown inside node viewport.
« Last Edit: 2016-11-12, 13:45:50 by jKLman »
"Jack of all trade, but messing up with 3D"
Blender 2.78 Corona Standalone 1.5 / 2016-10-24 Alpha
Win 10 64bit

2016-11-12, 13:45:13
Reply #18

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 412
    • View Profile
    • Blender exporter for Corona
Click the add material node tree button and on another view set it to the node editor. Then there are three buttons on the node editors toolbar to choose the texture icon. I can't send a screenshot right now but maybe tomorrow.

2016-11-12, 13:48:12
Reply #19

jKLman

  • Active Users
  • **
  • Posts: 66
    • View Profile
Oh my, I did not try to click the texture icon coz I was looking for the material icon.
Thanks.

But here is what I've got!

Material node is working perfectly.....
« Last Edit: 2016-11-12, 17:06:12 by jKLman »
"Jack of all trade, but messing up with 3D"
Blender 2.78 Corona Standalone 1.5 / 2016-10-24 Alpha
Win 10 64bit

2016-11-15, 00:14:12
Reply #20

jKLman

  • Active Users
  • **
  • Posts: 66
    • View Profile
@blanchg

You really did a great job in updating Blender integration with Corona.
After trying testing the old chocofur file WITHOUT touching or updating any object to the latest exporter, ie material, maps, texture etc,
it just did work! No crashes and any errors in the Blender console.

Though there are few changes or that are not compatible maybe with the new Corona Standalone that did not render correctly but the exporter is almost backward compatible with what Joel has greatly done and shared with us.

Here is the test.

"Jack of all trade, but messing up with 3D"
Blender 2.78 Corona Standalone 1.5 / 2016-10-24 Alpha
Win 10 64bit

2016-11-15, 00:19:11
Reply #21

blanchg

  • Moderator
  • Active Users
  • ***
  • Posts: 412
    • View Profile
    • Blender exporter for Corona
@jKLman, thanks, I did build on the awesome work that Joel did and tried to keep the changes to a minimum where possible.

There were lots of changes to the material definitions so not surprised that some features didn't make it across to the newer versions of Corona.

That is a great scene and the chocofur website has some great information on working with corona and blender.

2016-11-16, 16:18:21
Reply #22

burnin

  • Active Users
  • **
  • Posts: 924
    • View Profile
Ohhh, great results and It's all working out-of-the-box now.
Thanks for everything.