当前位置:网站首页>The display problem of gltf model with transparent map
The display problem of gltf model with transparent map
2022-04-21 09:35:00 【Discussion on Geographic Information Technology】
3D model with transparency map , Will involve when displaying , According to the transparency on the picture , To display irregular shapes , When making a 3D model , Regular shapes are imported , A rectangle or square , If transparency is not processed , The result displayed is incorrect , For example, the 3D model settings of the trees below :

Processing software through model , Set the material (material) Properties of , When the model can be displayed in the engine , The transparent position is not displayed , So as to achieve the correct display mode :

The specific way of operation is before the official account. :Blender Export with transparency map gltf Model
In practice , 3D model with multiple maps , It will be slow to modify attribute information one by one , have access to Blender Medium python Batch modification of scripts , See official account. :Blender Script development , attach : How to modify the properties of all materials in a model (material) Of python Code :
//bpy.data Model data in the scene
materials = bpy.data.materials
for (k1,v1) in materials.items():
v1.blend_method = ‘BLEND’
Set the exported 3D model in this way , Set the materials to BLEND attribute , When the material in the model has transparent channels ( for example png Format ), stay three.js perhaps cesium When displayed in the , There will be the problem of mixing with the background , The model display penetrates the background , Here's the picture :

Material without transparent channel , for example jpg Format , Can avoid such problems , therefore , When setting the map of the model , According to different situations , Set different properties , stay gltf Model format description , You can also set the transparency property of the model to mask, This can also avoid such problems .
attach gltf Description of model material parameter settings (blend and mask):
MASK - The rendered output is either fully opaque or fully transparent depending on the alpha value and the specified alpha cutoff value; the exact appearance of the edges MAY be subject to implementation-specific techniques such as “Alpha-to-Coverage”.
BLEND - The rendered output is combined with the background using the “over” operator as described in Compositing digital images.

版权声明
本文为[Discussion on Geographic Information Technology]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204210932365518.html
边栏推荐
- 1163: 亲和串(字符串)
- 1149: combine two of three digits
- 日本小哥开源“自虐神器”一夜爆火:用手柄控制自己的脸,代码自取,后果自负
- 1168: 账单(指针专题)
- 计算器(力扣)
- My life of Honker Security Commando
- Simulation implementation vector
- Kali:sqlmap :[10:39:37] [CRITICAL] unable to connect to the target URL
- Yuanshu training dance room, cyberpunk cool style, waiting for you to dance
- 【云驻共创】华为云数据库之数据库原理及应用课程11、数据库系统控制
猜你喜欢

常用文本处理命令

ESP32 寻迹模块测试

VR panorama is suitable for those industries

CC10000. CloudJenkins—————————————

C语言简单的【栈和队列】(括号匹配问题)

又涨了,4月全国程序员薪资出炉,竟成行业薪资天花板?看完我心动了

【ACM】131. 分割回文串
Open3d reads and writes ply point cloud files
![Kali:sqlmap :[10:39:37] [CRITICAL] unable to connect to the target URL](/img/bf/123e6f5eadb8d502e135a7cff9b120.png)
Kali:sqlmap :[10:39:37] [CRITICAL] unable to connect to the target URL

2022制冷与空调设备运行操作考试题模拟考试题库及答案
随机推荐
Download the first analysis report on China's database industry!
CC00026. CloudJenkins—————————————
On the three paradigms of database design
1150: how many integers
1163: affinity string (string)
How to uninstall SQL server2012 database_ Cad2014 cannot be uninstalled
1167: 逆转数(指针专题)
Operation of simulation test platform for test questions of refrigeration and air conditioning equipment operation test in 2022
控制另一个程序的启动、隐藏、显示、关闭
【ACM】131. Split palindrome string
1147: 查找子数组
【愚公系列】2022年04月 微信小程序-地图的使用之API相关函数案例
[Netty ]自己实现一个redis客户端难吗?
使用LamdbaUpdateWrapper的setSql作用及风险
1169: large integer (pointer)
vr全景适合那些行业
ESP32 寻迹模块测试
CC10000. CloudJenkins—————————————
M3u8 Video Downloader IDM breaks through the failure to download protected data and cannot be restricted
ZABBIX 5.4 server installation