当前位置:网站首页>Mr developed by unity3d realizes model occlusion and transparent ground receiving shadow
Mr developed by unity3d realizes model occlusion and transparent ground receiving shadow
2022-06-10 12:53:00 【Leoysq】
One 、 Realize the occlusion model of real scene
principle : Build a patch and place it at the corresponding position to block the virtual model, and then make the patch transparent and not display
structure Shader Code , Will change shader Assign to material , Give the material to the patch that needs to block others . The following methods do not apply to baking .
effect :

The code is as follows :
Shader "Custom/mask"
{SubShader
{
Tags{ "RenderType" = "Opaque" "Queue" = "Geometry-3" }ColorMask 0
ZWrite onCGINCLUDE
#include "UnityCG.cginc"struct appdata
{
float4 vertex : POSITION;
};struct v2f
{
float4 pos : SV_POSITION;
};v2f vert(appdata v)
{
v2f o;
o.pos = UnityObjectToClipPos(v.vertex);
边栏推荐
- 【FLinlk】Flink小坑之kerberos动态认证
- CMakeLists.txt 如何编写
- 通过反射获取枚举值
- C# 均衡权重分配
- Creating basic stacks and queues in C language
- Element close and destroy the pop-up box: clear the data cache in the pop-up box (organize)
- ASP.NET 利用ImageMap控件设计导航栏
- Colmap source code reading notes [1] threading cc
- 性能测试方案(计划)模板
- Shadergraph - 302 swimming Dragon
猜你喜欢

无代码五月大事件|微软低代码矩阵更新;多份行业报告发布...

别把“IT信息化”不当“超级工程”

Software project management 6.10 Cost budget

向数据库中注册用户名和密码的功能

Driver. JS - open source and independent interactive guidance tool library for web novices, powerful and highly customizable

FM4057S单节锂电池线性充电芯片的学习

使用SoapUI工具生成发送短信接口代码

ASP. Net using imagemap control to design navigation bar

蚂蚁金服杨军:蚂蚁数据分析平台的演进及数据分析方法的应用

Shadergraph - 302 swimming Dragon
随机推荐
已拿offer,进阶学习
IQR box diagram
文档提升计划第二期|OceanBase 邀您一起进行文档共建
Learning of cc2642r Bluetooth MCU chip
TIDB 初级课程体验 8 (集群的管理维护, 添加一个TIKV节点)
(11) Const decorated member function
【抬杠C#】如何实现接口的base调用
Summary of Kitti related information
Vdo-slam source code reading notes [2] local optimization and global optimization
STM32 learning notes (2) -usart (basic application 1)
无代码五月大事件|微软低代码矩阵更新;多份行业报告发布...
UML类图
STM32F407学习笔记(1)-EXTI中断事件与NVIC寄存器
六石编程学:以文字处理的位置,谈谈命名
使用unique快速删除重复元素
通过反射获取枚举值
2022年浙江省赛
实战案例,深入剖析
(4) Classes and objects (1)
JS array de duplication: de duplication of two-dimensional arrays, removal of the same value, and removal of the same array