3ds Max to Glowstick
Use 3ds Max to create scenes that can be exported to OpenUSD for rendering inside Glowstick. When done correctly (i.e. understanding the current limitations of Glowstick), rendering seamlessly is possible.
Things to Know Before You Start
Save you 3ds Max file outside of Ubuntu.
Before adding textures to your scene, place the textures you want to use in the folder you intend to export the final USD file. Otherwise, 3ds Max will put relative links to the texture files. For example both the Laundry.usd file and the LaundryMaterials folder are in the same export location:
Displacement maps are not yet supported in Glowstick, including them in your materials will cause a segfault and prevent rendering.
Multiple viewports can be set on the left side by clicking on the right arrow. This is helpful for setting up cameras, lights, and moving geometry around the scene.
Preview your render by selecting Active Shade using Arnold. This is helpful for setting up lights. Note if you’re in a physical camera viewport, you can not move around the scene.
Setting up cameras using a physical camera.
Click on the plus icon, select camera, and click on physcial camera.
Click to place your camera and drag towards your geometry.
You can move the camera, but also the area of focus (below).
When creating Lights, you must select Photometric Lights
Target or free lights both work
Point lights do not export correctly with USD. Change the shape of the target or free light by clicking on your light in the viewport and selecting Modify.
In the Shape/Area Shadows, Emit Light from (Shape) should be set to one of the following:
Sphere (with a radius)
Rectangles (with length + width)
Disc (with a radius)
Setting up Materials & Textures
Materials and textures must be set up in 3ds Max with USD Preview Surface.
To create a USD Preview Surface, open the Material Editor at the top of the navigation bar or by hitting (M) on your keyboard.
(M)
Select Materials on the left, go to USD, and click on USD Preview Surface. You can also right click in the View 1 tab as well. This will create a USD Preview Surface box.
Next, we will create a bitmap by going to the Maps tab on the left. Click on General and select Bitmap. You can also right click in the View 1 tab as well. This will create a Bitmap for you to select your texture.
Select the texture you want to use. Make sure the material is in the correct folder. The material folder must be in the same location as the final USD export.
(Materials folder and USD export are in the same export folder)
Connect the Bitmap to the USD Preview Surface box by clicking on the right nub and dragging over to Diffuse Color Map
Apply the material to an object in your scene. Select an object in the viewport. Open the Material Editor (M) and click the Assign Material to Selection button. Make sure you have the USD Preview Surface box selected if the icon is greyed out.
Your material should now appear on the object.
Exporting USD from 3ds Max
If you don’t see USD as an export option, you may be running on an older version of 3ds Max that will require you to download an extension from Autodesk. (.usdz will not work for Glowstick)
Sign in to your Autodesk account. Go to the Products & Services tab under your Account folder. Click on 3ds Max and select the year of your 3ds Max you’re running. Click on extensions and choose the most recent USD for 3ds Max download.
When exporting to USD inside 3ds Max, ensure the following options are set (in order as they appear in the dialog box):
Under File, choose “ASCII” to make the USD output human readable
Under Include, choose “Convert to Triangles” as the Mesh Format
Under Materials, choose “USD Preview Surface”
Rendering with Glowstick
Loading your scene onto the server
Open Ubuntu.
Copy your design files to your Linux home folder.
Linux\Ubuntu-22.04\home\jill
Render by entering the code below. Switch the .usd file, HDRI, and resolution to your files and render settings.
bolt_server --backend /usr/share/bolt_server/libbolt_embree_backend.so -i ./Laundry3.usd --bgcolor 0,0,0 -h 1080 -w 1920 --iters 400 --bounces 5
When rendering with an HDRI, use
--hdriYou must specify which folder your HDRI is in like below since HDRIs are not part of the USD export.
--hdri ./LaundryMaterials/pillars_4k.exr./foldername/hdrifilename.exrbolt_server --backend /usr/share/bolt_server/libbolt_embree_backend.so -i ./Laundry7.usd --hdri ./LaundryMaterials/pillars_4k.exr -h 1080 -w 1920 --iters 400 --bounces 5
You can hide the HDRI image by using:
--alphacolor 1This also exports a -alpha image that you can use as a mask for replacing the background in a photo editor
You can change the location of your render output with
--dest ./foldername/Be sure to include the
/at the end of the path to avoid exporting one level up
Lighting Differences
Lights can be blown out when rendering with Glowstick. Set
--lightmulto a value like0.01to reduce.
bolt_server --helpfor documentation on commands and how to use them