[Addon] Mitsuba Blender Plugin (26-Nov-15)

Hi Atom,

this is a classic problem where the way you’ve specified the input just makes it too hard for the renderer to “find” the light. Most of the algorithms that are used these days are pretty dumb, i.e. they cannot figure out by themselves that the only light that actually makes it into the room is coming through the window.

You have two options: switch to a smarter algorithm like MLT or PSSMLT, which have a 1-step memory of “relevant” paths. But you must make sure to set their “directSamples” parameter to -1 so that MLT is even used for the direct illumination component (this is handled with another technique by default which, in your scene, would just add a lot of noise).

The other option is to make an area light which approximates your environment and put it in front of the window.

Cheers,
Wenzel

Great! I will take a look at luxblend code for this.

@Atom: Thank you for your code, I will mix it with the changes I am coding and I will try to add instance support too.

About speedup - best solution would be using area lamp inside room, but JW refused to make transparent area lights , since this is physically incorrect. But maybe if you ask him (again), he will change mind.

I requested earlier today, but WJ still does not want to incorporate non-rendering emitter sources. It is against physical laws, and Mitsuba, is strict about being physically correct.

Mitsuba 0.4.2 has been released.

http://www.mitsuba-renderer.org/devblog/?p=772

  			The next bug-fix release of Mitsuba is available, which has the following improvements:
  • Volumetric path tracers: improved sampling when dealing with index-matched medium transitions. This is essentially a re-implementation of an optimization that Mitsuba 0.3.1 already had, but which got lost in the bidirectional rewrite.
  • Batch tonemapper: due to an unfortunate bug, the batch tonemapper in the last release produced invalid results for images containing an alpha channel. This is now fixed.
  • Shapes: corrected some differential geometry issues in the “cylinder” and “rectangle” shapes.
  • MLT: fixed 2-stage MLT, which was producing incorrect results.
  • MEPT: fixed the handling of directional light sources.
  • Robustness: got rid of various corner-cases that could produce NaNs.
  • Filenames: to facilitate loading scenes created on Windows/OSX, the Linux version now resolves files case-insensitively if they could not be found after a case-sensitive search.
  • Python: added Python bindings for shapes and triangle meshes. The Python plugin should now be easier to load (previously, this was unfortunately rather difficult on several platforms). The documentation was also given an overhaul.
  • Particle tracing: I’ve decided to disable the adjoint BSDF for shading normals in the particle tracer, since it causes an unacceptable amount of variance in scenes containing poorly tesselated geometry. This affects the plugins ptracer, ppm, sppm and photonmapper. See the commit for further details.
  • Subsurface scattering: fixed parallel network renderings involving the dipole model.
  • Homogeneous medium & dipole: added many more material presets by Narasimhan et al.
  • OBJ loader: further robustness improvements to the OBJ loader and the associated MTL material translator.

:eyebrowlift: Good news…

Hi!

Here is an updated version of the addon:

  • zip version, ready to install as any other Blender addon.
  • Mitsuba repository, download archive, uncompress and copy mitsuba folder to Blender addons folder.

First steps towards implementing Shapegroups and Instances.

  • Added support for dupli objects.
  • Export only one of each needed mesh to avoid duplicated meshes on serialized file.
  • Reutilize meshes from serialized file when needed.
  • Export always all cameras.
  • Export only one light of type HEMI or SUN.

Post here or open a ticket in Mitsuba bug tracker if you find any bugs or have a feature request.

Not exporting UVs correctly for me, after unzipping to addons folder for 2.64a.
Reverted to version with file dates of 10/21/2012 from box.com.

Would like to try new features, but unable to ATM gotta get this render done.

i had a similar problem with UV’s, but i think it was related to my own build of COLLADA, or something along those lines. i set the UV scale to 1,-1 respectively for textures and textures would export correctly

I should have run some test scene with UV…

chip4brains, the UVs are inverted like ohsnapitsjoel says? Or is it something else?

Ok, I will prepare a fix for inverted UV.

thanks for your efforts.

“- Export only one light of type HEMI or SUN.”? this doesn’t mean you can only have a hemi OR a sun, does it? (Hemisphere doesn’t work with latest exporter…)

Sun does’t work if rotation is 0,0,0

“- Reutilize meshes from serialized file when needed.” should this mean it doesn’t export already “serialized” meshes? (cause it does re-export)

In the tests scenes I used, Mitsuba terminated with this error when more than one light of type Sun or Hemi was present:

Caught a critical exeption: ERROR main [Scene] The scene may only contain one environment emitter.

What do you mean Hemisphere doesn’t work with latest exporter? What error do you get?
I will check about Sun rotation. Thank you!

It means that if two or more objects (duplis, linked objects) use the same mesh, it’s exported only once and used on both objects. Before that, all objects were exported as unique meshes and the serialized file contained duplicate meshes, which was inefficient but was the fastest way I could implement the serializer to replace collada exporter.

Right now, the scene is always re-exported, I am looking into changing this.

Never mind about hemi, was my fault - it works. sorry

imo it should be possible to use hemi(hdr) plus a sun - i use this all the time in cycles. (but maybe this is not possible with current mitsuba)

The reutilize makes sense. Would be nice to not have to re-export at some point in future.

thanks.

Thanks for update fjuhec
Banshi - ‘Sun does’t work if rotation is 0,0,0’ – this should be fixed in mitusba 4.2 - I haven’t time to test it yet.

you’re right, it’s fixed in 0.4.2. thanks

Uploaded updated version of the plugin, it should export correct UVs now without having to set V scale to -1.

Get files from the same place.

With bug fixes in mitsuba 4.2 I was able to render this in half time compared to previous version in mitsuba 4.1 - 3minutes with PT. And with less noise. Exporter seems to work great - but there in no partial mesh export right? Car is bit heavy, and it get exported every time, even though there is no mesh change.


No, it doesn’t have partial export yet. I’m still learning Blender API and examining LuxBlend to see how it works.

could it use .bvh like Intel embree? its what cycles uses and its fast.
embree is open source.

Also… does the exporter do SSS now?

-1??? Thank you mucho fjuhec!

btw, Jose Conseco your mitsuba renders are always so superb.

all of this looks promising!

Does anyone knows if render passes are a todo feature? For me this is a quite essential feature for a rendering engine…