当前位置:网站首页>Record a stroke skin bone error of the skirt
Record a stroke skin bone error of the skirt
2022-07-07 08:02:00 【Mercury Note】
As shown in the figure , The skirt has this kind of problem , My first thought was when animating skirt swing , The back of the skirt is too close to the front , But there is no front through the back , So my first thought was to use point multiplication to judge the angle between the opposite direction of the line of sight and the normal direction , If the included angle is close 90 degree , Before the expansion , Otherwise, no outward expansion .
float3 normalWS = TransformObjectToWorldNormal(normal);
float3 positionWS = mul(unity_ObjectToWorld, input.positionOS);
float3 viewDir = normalize((_WorldSpaceCameraPos - positionWS));
float angleNormalView = dot(normalize(normalWS), normalize(viewDir));
// View direction and smooth normal direction
float isShow = angleNormalView < 0.01 ? 1 : 0;
isShow = 0;
outlineWidth *= isShow;
In fact, this method should be useful if it is tracing and adopting the way of positive outward expansion , The way to expand the back is that the direction of the back normal will not let the expanded surface penetrate the front
But at the end of the experiment, I found , Even if I set the stroke width to 0, He still has such dark spots , Then the back armor on the back has no black spots
Then in order to eliminate the problem of transparency , I also set the back armor to be transparent , There are no black spots on the back armor , Set the skirt to opaque , There are still black spots .
In fact, the skirt was not covered properly , It causes the back of the skirt to penetrate into the front .
Back culling is on by default , The penetrating part cannot be seen , But when using tracing, because it is the back tracing , So the back of it can be seen .
边栏推荐
- Operation suggestions for today's spot Silver
- [advanced digital IC Verification] command query method and common command interpretation of VCs tool
- JS quick start (I)
- Paddlepaddle 29 dynamically modify the network structure without model definition code (relu changes to prelu, conv2d changes to conv3d, 2D semantic segmentation model changes to 3D semantic segmentat
- 【数字IC验证快速入门】17、SystemVerilog学习之基本语法4(随机化Randomization)
- [webrtc] m98 Screen and Window Collection
- Implementation of replacement function of shell script
- What is the interval in gatk4??
- pytest+allure+jenkins环境--填坑完毕
- Rust versus go (which is my preferred language?)
猜你喜欢
JS quick start (I)
Hands on deep learning (IV) -- convolutional neural network CNN
图解GPT3的工作原理
Main window in QT learning 27 application
Codeforce c.strange test and acwing
Problem solving: unable to connect to redis
[Matlab] Simulink 自定义函数中的矩阵乘法工作不正常时可以使用模块库中的矩阵乘法模块代替
2022年全国最新消防设施操作员(初级消防设施操作员)模拟题及答案
Technology cloud report: from robot to Cobot, human-computer integration is creating an era
Linux server development, SQL statements, indexes, views, stored procedures, triggers
随机推荐
Custom class loader loads network class
有 Docker 谁还在自己本地安装 Mysql ?
【数字IC验证快速入门】12、SystemVerilog TestBench(SVTB)入门
You Li takes you to talk about C language 6 (common keywords)
[VHDL parallel statement execution]
Common validation comments
[matlab] when matrix multiplication in Simulink user-defined function does not work properly, matrix multiplication module in module library can be used instead
SQL优化的魅力!从 30248s 到 0.001s
C语言二叉树与建堆
LeetCode 40:组合总和 II
Open source ecosystem | create a vibrant open source community and jointly build a new open source ecosystem!
Mysql高低版本切换需要修改的配置5-8(此处以aicode为例)
Chip information website Yite Chuangxin
芯片 设计资料下载
The configuration that needs to be modified when switching between high and low versions of MySQL 5-8 (take aicode as an example here)
MySQL multi column index (composite index) features and usage scenarios
Rust Versus Go(哪种是我的首选语言?)
misc ez_ usb
Thinkcmf6.0安装教程
C language flight booking system