Stencil

  The stencil buffer can be used as a general purpose per pixel mask for saving or discarding pixels.

  The stencil buffer is usually an 8 bit integer per pixel. The value can be written to, increment or decremented. Subsequent draw calls can test against the value, to decide if a pixel should be discarded before running the pixel shader.

  Stencil测试在Fragment Shader之前进行。也即光栅化后进行的第一个Test,Stencil-Test过后是ZTest。

[Syntax] 

  Comp, Pass, Fail and ZFail will be applied to the front-facing geometry, unless Cull Front is specified, in which case it's back-facing geometry. You can also explicitly specify the two-sided stencil state by defining CompFront, PassFront, FailFront, ZFailFront (for front-facing geometry), and CompBack, PassBack, FailBack, ZFailBack (for back-facing geometry).

[Comparison Function]

  

[Stencil Operation]

  

[Deferred rendering path]

  to be continued...

参考:file://localhost/Applications/Unity/Unity.app/Contents/Documentation/Documentation/Components/SL-Stencil.html

Stencil的更多相关文章

  1. A trip through the Graphics Pipeline 2011_07_Z/Stencil processing, 3 different ways

    In this installment, I’ll be talking about the (early) Z pipeline and how it interacts with rasteriz ...

  2. Stencil Buffer

    刚在草稿箱里发现了这篇充满特色的好日志.发表之. ------------------吃货的分割线---------------------------------------- Stencil Bu ...

  3. Unity3D Shader Stencil模版测试学习

    官方文档地址: https://docs.unity3d.com/Manual/SL-Stencil.html 参考博客: http://blog.csdn.net/onafioo/article/d ...

  4. Stencil 基础

    Stencil 一个轻量化,渐进式编译器,注意,不是框架. 使用 TypeScript 进行所有操作,这是一个门槛,有一定技术门槛要求. PS:个人强烈推荐所有的前端同学都学习,或至少了解这个超集语言 ...

  5. stenciljs 学习十三 @stencil/router 组件使用说明

    @stencil/router 组件包含的子组件 stencil-router stencil-route-switch stencil-route stencil-route-link stenci ...

  6. 在DirectX11下用Stencil Buffer绘制可视化Depth Complexity

    这是一道在<Introduction to 3D Game Programming with DirectX 11>上的练习题. 要求把某个像素点上的Depth Complexity(深度 ...

  7. stencil in unity3d

    Pass { Stencil { Ref Comp Always Pass REPLACE } AlphaTest Greater Blend SrcAlpha OneMinusSrcAlpha Co ...

  8. UnityShader实例09:Stencil Buffer&Stencil Test

    http://blog.csdn.net/u011047171/article/details/46928463 Stencil Buffer&Stencil Test 在开始前先吐槽下uni ...

  9. ZBrush软件特性之Stencil模板调控板

    在ZBrush中使用Stencil模板我们了解的所有绘图工具,通过它确定模板周围与涂画或模型的位置.本文将详解ZBrush®中如何使用“曲线板”自定义形状. 使用模版 ZBrush模版的作用象我们了解 ...

随机推荐

  1. cnpm 私服搭建(基于docker)

    备注:   使用docker-compose 进行安装 1. 代码clone git clone https://github.com/cnpm/cnpmjs.org.git 2. docker bu ...

  2. php mysql 字符集(三) (转)

    http://bbs.csdn.net/topics/390097514 gbk页面插入数据到utf8表,然后取出到gbk页面 首先, 这个set names x等价于SET character_se ...

  3. 运维命令:tcpdump

    tcpdump命令  tcpdump 命令是一款sniffer工具,它可以打印所有经过网络接口的数据包的头信息,也可以使用 -w 选项将数据包保存到文件中,方便以后分析. 常用参数: -a:尝试将网络 ...

  4. java 工作流

    BPM是jboss旗下遵守LGPL许可的java开源工作流,功能比较完善,从4.0开始引入了pvm的概念,支持jPDL.BPEL等流程定义语言.由于相关资料还比较少,开发自己的一个demo还不是太容易 ...

  5. mysql大数据量之limit优化

    背景:当数据库里面的数据达到几百万条上千万条的时候,如果要分页的时候(不过一般分页不会有这么多),如果业务要求这么做那我们需要如何解决呢?我用的本地一个自己生产的一张表有五百多万的表,来进行测试,表名 ...

  6. CRC 自动判断大端 小端

    /* aos_crc64.c -- compute CRC-64 * Copyright (C) 2013 Mark Adler * Version 1.4 16 Dec 2013 Mark Adle ...

  7. AT 指令和常见错误码

    一. 一般命令 1. AT+CGMI 给出模块厂商的标识. 2. AT+CGMM 获得模块标识.这个命令用来得到支持的频带(GSM 900,DCS 1800 或PCS 1900).当模块有多频带时,回 ...

  8. net start mongodb发生系统错误2 系统找不到指定的文件

    安装mongodb时, 将mongodb 作为系统服务启动 net start mongodb,报错发生系统错误2 系统找不到指定的文件 . 查找原因是因为,系统服务的可执行文件地址有误. 修改服务地 ...

  9. Hibernate学习11——配置Hibernate二级缓存

    一.缓存的概念: 以空间换时间:   二.Hibernate缓存的分类: 前面我们讲的缓存都是session缓存:也叫一级缓存:get,load等缓存都是内置的,一级缓存: SessionFactor ...

  10. 小峰Hibernate简介与HelloWorld

    一.Hibernate简介: 二.Hibernate4 版Hello World 实现 工程结构: com.cy.model.Student: package com.cy.model; public ...