STEAM 组
Blender Source Tools BleST
STEAM 组
Blender Source Tools BleST
290
游戏中
1,935
在线
成立于
2013 年 11 月 8 日
所有讨论 > Help > 主题详情
Taco 2018 年 4 月 29 日 上午 6:12
Question regarding custom normals and shape keys on DMX export
I'm testing a model that has heavily modified vertex normals on the face in order to achieve anime-style shading, the problem Im having is when the base normals are modified this much, any shape keys on the model end up with distorted normals that pretty much ruin the shading for the flexes.

I recorded a short video just to demonstrate: https://puu.sh/AcDld/1713314db3.mp4
(normals being calculated after triangulization)

I'm able to get around this by exporting a VTA file instead and compiling the old way, but I absolutely need to have corrector shapes for the kind of flex setup Im doing, which VTA has no support for.

This seems to just be how Blender handles vertex normals on shape keys, I'm wondering if there is any way at all around this issue, a way to possibly export the DMX file without the normals on the shape keys imploding?
最后由 Taco 编辑于; 2018 年 4 月 29 日 上午 6:20
< >
正在显示第 1 - 5 条,共 5 条留言
Zappy 2018 年 4 月 29 日 上午 6:24 
If by "corrector" shapes, you mean something like using flex sliders A, B, and C applies shape keys A, B, C, A_B, A_C, B_C, and A_B_C, VTA fully supports that.
%a = a %b = a %c = a %a_b = a * b %a_c = a * c %b_c = b * c %a_b_c = a * b * c
The above code should yield the same flex result with VTA as having shape keys with the left names in a "simple" flex format DMX export.

But I would guess that the VTA export is actually what's wrong here, because if it looks broken in Blender, it's supposed to look broken in exports too, as exports are supposed to look the same as in Blender. Which means that Blender itself is probably the "wrong" thing here, not the DMX export. You may want to see if it's possible to supply manual custom normals per shape key in Blender. If it is, I'd imagine that that would allow the DMX export to look as you want it to, too, but I don't know if that's possible in Blender.
Taco 2018 年 4 月 29 日 上午 6:46 
Oh I completely forgot you could do that, but the corrector flexes then would still have to be triggered manually right? I suppose that is a solution, although far less elegant than having it automatically blend them in when the parent shapes become active.

Wether or not the VTA export is calculating normals as intended or not I am unsure of, they do store the direction of the normal in addition to the world position translation I think, so Blender's solutions for the flexed vertex normals before exporting is probably causing the problem.

Would it be possible to have an option to make the DMX export behave the same as the VTA, broken or not?
Zappy 2018 年 4 月 29 日 上午 6:54 
引用自 Taco
Oh I completely forgot you could do that, but the corrector flexes then would still have to be triggered manually right? -
Again, if by "corrector flexes" you mean what's more commonly called "corrective flexes", you can use math to have them be applied automatically, as such:
$Model ModelName "ModelFileName.smd" { FlexFile "FlexFileName.vta" { Flex "A" Frame 1 Decay 0 Flex "B" Frame 2 Decay 0 Flex "C" Frame 3 Decay 0 Flex "A_B" Frame 4 Decay 0 Flex "A_C" Frame 5 Decay 0 Flex "B_C" Frame 6 Decay 0 Flex "A_B_C" Frame 7 Decay 0 } FlexController X "A" "B" "C" %A = A %B = B %C = C %A_B = A * B %A_C = A * C %B_C = B * C %A_B_C = A * B * C }
This loads shape keys A, B, C, A_B, A_C, B_C, and A_B_C from FlexFileName.vta, and creates flex controllers/sliders named A, B, and C.

When using flex slider A and B, shape keys A, B, and A_B are applied. (As you can see, the A_B shape key is set up to be applied with a scale of the A slider multiplied by the B slider.)
最后由 Zappy 编辑于; 2018 年 4 月 29 日 上午 6:55
Taco 2018 年 4 月 29 日 上午 7:03 
Ahh okay, these controller lines always confused the hell out of me but I see what you're saying now. Never even crossed my mind to set it up that way. I'll utilize that, thank you.
Taco 2018 年 5 月 31 日 下午 5:44 
In case anyone else is wondering about this topic, I discovered the issue can be circumvented entirely by duplicating the mesh, and using data transfer to transfer the normals from the dupe specifically with the "Topology" setting. Simply export with the modifier enabled.
< >
正在显示第 1 - 5 条,共 5 条留言
每页显示数: 1530 50

所有讨论 > Help > 主题详情
发帖日期: 2018 年 4 月 29 日 上午 6:12
回复数: 5