|
Baush, Sr. Member
Posted: 15 August 2012 02:47 AM Total Posts: 135
I apologize if this was already answered somewhere before (could not find any)
As the dynamic shadows are somewhat hard on the GPU/CPU, would it be possible to have them rendered for nearby objects only instead of the far clipping value?
I tought perhaps we could have the castShadows attribute dynamically changed based on the distance with the camera as another way to approach the problem.
Any idea on the most effective way to handle this?
Thanks!
-Matt
|
|
John Brookes, Moderator
Posted: 15 August 2012 02:09 PM Total Posts: 732
[ # 2 ]
Sweet jebus how long as that method been hiding in Away and never answered :/
From a little play am I right in thinking it doesn’t cast shadows on itself?
As in, say you have 1 mesh carbody and interior. The interior wont get shadow from the outer body/frame/
|
loth, Sr. Member
Posted: 15 August 2012 02:26 PM Total Posts: 236
[ # 3 ]
all i want is smooth shadow on ground and is done
you have to test by yourself
|
Richard Olsson, Administrator
Posted: 16 August 2012 09:29 AM Total Posts: 1192
[ # 4 ]
Note that if you have a big scene with only some moving objects (e.g. a city) you should use baked shadows for the static objects, and only dynamic shadow (using NearShadowMapMethod) for those objects that are near the camera, like your car or character in a game.
|
synkarius, Member
Posted: 22 August 2012 04:39 AM Total Posts: 64
[ # 5 ]
Is there a way to only calculate shadows once per object, or bake via code? I have a large scene full of objects which do not move, but get added and removed dynamically. It’d be nice if I could just render the shadows to the secondary UV channel or something. Can I?
Edit: I can’t just bake in Blender b/c the shadows aren’t the same for every copy of a given object.
|
Richard Olsson, Administrator
Posted: 22 August 2012 06:32 AM Total Posts: 1192
[ # 6 ]
You can’t bake them in Away3D, and you wouldn’t get as good results as if you did it in Blender either. So I would encourage you to set up the entire scene in Blender, and then bake the shadows there.
Note that I’m suggesting that you set up all static objects just the way you want your scene to look at real-time. You don’t bake them one by one, but everything in one scene.
You can theoretically use a secondary UV channel for this, but there are no file formats that will carry that across to Away3D. So if you want to use a secondary UV channel you will have to export two copies of each mesh, and move over their UV channel from one copy to the other once in Away3D.
|
synkarius, Member
Posted: 22 August 2012 07:34 AM Total Posts: 64
[ # 7 ]
Thank you for the quick reply and the suggestion. However, that solution doesn’t fit our project. Not only do objects get added and removed dynamically, but the arrangement of the objects itself is procedurally generated. So I can’t bake the scene in Blender beforehand and get satisfactory results because I don’t know what the nth generated arrangement is going to look like.
Thus, it’d be nice to just add a mesh to the scene, calculate its shadows once, and be done with it. See my problem?
|
|
synkarius, Member
Posted: 22 August 2012 05:14 PM Total Posts: 64
[ # 9 ]
Thank you for the confirmation. Request filed.
|