Home > Database > Mysql Tutorial > 用2个摄像机做水印

用2个摄像机做水印

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-07 15:09:42
Original
1398 people have browsed it

在unity项目中,经常会遇到截屏后分享图片的功能,为了防止内容的侵权和加强传播能力,我们需要水印功能。在unity中,如此这般实现: 1、需要有两个正交相机 2、两个相机采用不同的depth 3、depth小一点的因为渲染的时间比大的早,所以作为主图的渲染 4、dep

在unity项目中,经常会遇到截屏后分享图片的功能,为了防止内容的侵权和加强传播能力,我们需要水印功能。在unity中,如此这般实现:


1、需要有两个正交相机

2、两个相机采用不同的depth

3、depth小一点的因为渲染的时间比大的早,所以作为主图的渲染

4、depth大的渲染的时间在上面的相机后,因此负责把水印图(或者是字)渲染到上面的相机的输出上

5、在Unity中新建一个RenderTarget,然后在两个相机的Target Texture部分,把这个RenderTarget拖入


这样RenderTarget中渲染出来的图就是我们需要的水印图。


Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
2 different flyer popup styles
From 1970-01-01 08:00:00
0
0
0
90%22=2 What kind of model is this?
From 1970-01-01 08:00:00
0
0
0
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template