Jump to content

[SOLVED]Look At Wrong During Rendering?


Recommended Posts

Hi All,

 

I am working on a planet scene and I want to add a glow around the planet. I am using the Volume Fog technique  for glow which completely obscures the planet. The initial fog volume is the entire volume of the planet. I want the center, facing the camera to be completely clear of fog or glow. I have added a tube to the scene which intersects the planet sphere. I lowered the tube radius so it can act like a boolean subtract on the fog volume. Fog within the tube will be subtracted.

 

Now the only way this trick will work is if the end of the tube is always facing the camera. So I have used the LookAt shelf tool to accomplish this. I object merge the tube into the glow sphere and use that as a second input on a Volume Mix set to subtract mode. This does work, however at render time it looks like the LookAt rotation axis is getting jacked by about 90 degrees.

 

Can someone take a look at my file and confirm this or explain how to correct this render time LookAt rotation error?

 

Thanks

ap_planet_with_stars_1c.hipnc

post-12295-0-47457200-1441645051_thumb.j

post-12295-0-08105900-1441645235_thumb.j

Edited by Atom
Link to comment
Share on other sites

it's not viewport/render problem

but you are merging local space tube geometry to glow layer object which still inherits planet's rotation on top

therefore while tube itself has correct transform, the objectmerged one has not 

to fix that set object_merge_tube_cutter/Transform to Into This Object, so that it always compensates for transform difference between objects

 

- to speedup things a little bit you can use VDBs instead of isooffset and volumemix

 

- to speedup things much more, compute the volume ring in local space once, then just parent under planet and orient to camera, so that the volume geometry will not need to recompute every frame, just the object's transform will

Link to comment
Share on other sites

Thanks for the information, it was all correct. I forgot about the effects of parenting on transforms and having the static volume ring face the camera makes more sense than having the subtract tube face the camera. The VDB system does seem to be faster than Volume Fog.

 

Getting closer on my planet earth. I have extended the dual map shader to represent day/night better. I have also added two more maps, one just for lights on the night side and an inverted specular for masking ocean reflection.

 

You can obtain the image maps for earth from this CC-0 licensed model at Blendswap. Open the BLEND file and choose File/External Data to extract the embedded image maps.

post-12295-0-62001100-1441676848_thumb.j

ap_planet_with_stars_1f.hipnc

Edited by Atom
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...