Giter VIP home page Giter VIP logo

io_scene_pbrt's People

Contributors

beltegeuse avatar delepoulle avatar jorgeromeu avatar stig-atle avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

io_scene_pbrt's Issues

AttributeError: 'Scene' object has no attribute 'update'

When I try to export, I have this messsage with the new version.

Traceback (most recent call last):
File "/home/samuel/.config/blender/2.80/scripts/addons/io_scene_pbrt-master/render_panel.py", line 16, in execute
render_exporter.export_pbrt(bpy.data.scenes['Scene'].exportpath, bpy.data.scenes['Scene'], '{0:05d}'.format(frameNumber))
File "/home/samuel/.config/blender/2.80/scripts/addons/io_scene_pbrt-master/render_exporter.py", line 974, in export_pbrt
export_geometry(pbrt_file,scene)
File "/home/samuel/.config/blender/2.80/scripts/addons/io_scene_pbrt-master/render_exporter.py", line 889, in export_geometry
bpy.context.scene.update()
AttributeError: 'Scene' object has no attribute 'update'

location: :-1

Environment map function fails when no map is defined

The function that is going to export the environment map fails if no texture is defined.
This function is currently commented out, need to be enabled and fixed.

Possible fix:
Add a button to the render settings dialog where you specify what texture to use as environment map.

issue with subsurface modifier

When a modifier is used, the mesh is not exported correctly unless the modifier is apply and the mesh turn in edit mode.

I use blender 2.82. The exporter work but if I use the subsurface modifier :

  • if I don't apply it, the exporter dont use it (why not ?)
  • if I apply it, many part of the mesh are not exported ! I read the pbrt file produced and the number of vertex is not changed !
  • if I turn into edit mode, the mesh is now exported correctly

I think there is the same problem with many (all ?) modifier. A very cool solution would to have a checkbox like "apply modifier before export" in order to keep the modifiers in the blend file.

field of view

I have noticed an important difference on the field of view (FOV) on the Blender viewport and the rendered image. I think I know a part of the problem :
For blender, the FOV is the maximum of horizontal angle and vertical angle. But pbrt use the minimum !
So I changed you line 132 in render_exporter.py
from :
fov = bpy.data.cameras[0].angle * 180 / 3.14
to :
fov = bpy.data.cameras[0].angle * 180 / math.pi * bpy.data.scenes['Scene'].render.resolution_y / bpy.data.scenes['Scene'].render.resolution_x

The result is more consistant but not actually the same.

viewport

multiple materials on the same mesh

When I assign multiple materials to one mesh (to different parts of the mesh), only the first one seem to be affect to the whole mesh. I wonder if it's a problem of the exporter or of PBRT itself and if there is a way to do this.

Fix so that custom nodes shows texture in viewport.

I stumbled upon the solution on how to enable textures in the viewport with the custom nodes while working on the pbrt-v4 support, each custom material node class simply has to have 'show_texture = True' in the class definition (for example just below 'bl_icon = 'INFO'').
You can then show the texture from the inputs in the viewport like this:

image

Backport this to the current master branch and test it to make sure you do not have to create new instances of materials to make it work, if new material instances are needed - then update all the sample scenes as well.

Output path issue

When manually setting the output directory (as opposed to choosing it with the dialog), when you don't append a / then the exporter will create new directories ply and textures whose names start with the name of the base directory, so e.g. if output dir is /Username/pbrt then the plugin will create /Username/pbrtply and /Username/pbrttextures instead of /Username/pbrt/ply.

See here:

Fix mesh export bug

Not all geometry with modifiers and editing gets exported the way it should.
Fix so that we are sure the mesh \ depgraph is updated, so that it exports the final geometry.

Typical example of the issue is seen here:

image

Fix so that RGB node can be plugged into the color slot.

The color slot should be overridden if there's a RGB node plugged into a color slot.
Right now it only exports the slot itself, not the one you plug in to override.
Only image texture is being exported if plugged into color slot.

Blender area lights

Hi Stigatle,

Do you have any idea of how to handle the area light source in Blender?

For example, these light sources are pretty common on Blendswap's model (for example, https://www.blendswap.com/blend/17404 with the screenshot below)
image

For now, I have a working prototype that converts this type of light source into rectangular area lights. But the problem is that the light source will be visible (even if I use "none" BSDF!).
test_light

Do you think that the blender needs to export such type of light? Because I think these type of light that are invisible inside the scene is not compatible with PBRT.

How to export?

Trying to test your exporter. Probably the error is sitting in front of the screen, but whenever I hit "Export scene" blender opens the render dialog. Render engine is PBRT_Renderer and I have entered an output folder path. I'm on macOS 10.13, Blender 2.8 beta. When hovering over "Export scene" Blender actually shows a tooltip saying "Render active scene.":

Screen Shot 2019-05-30 at 21 10 59

Spot \ point light settings not exposed

Add all the various settings to the spot \ point light types, with their own GUI for PBRT specific settings. Currently the spotlight's parameters are hard coded (strength etc).

Fix batch export

Currently it just exports a single frame.
Add so that it exports all the data it needs between the start and end frame.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.