美文网首页
ShaderLab 属性,特性声明

ShaderLab 属性,特性声明

作者: 晓龙酱 | 来源:发表于2017-10-03 11:14 被阅读15次
  • Numbers and Sliders
name ("display name", Range (min, max)) = number
name ("display name", Float) = number
name ("display name", Int) = number
  • Colors and Vectors
name ("display name", Color) = (number,number,number,number)
name ("display name", Vector) = (number,number,number,number)
  • Textures
name ("display name", 2D) = "defaulttexture" {}
name ("display name", Cube) = "defaulttexture" {}
name ("display name", 3D) = "defaulttexture" {}

Attribute

  • [HideInInspector]
    does not show the property value in the material inspector.

  • [NoScaleOffset]
    material inspector will not show texture tiling/offset fields for texture properties with this attribute.

  • [Normal]
    indicates that a texture property expects a normal-map.

  • [HDR]
    indicates that a texture property expects a high-dynamic range (HDR) texture.

  • [Gamma]
    indicates that a float/vector property is specified as sRGB value in the UI (just like colors are), and possibly needs conversion according to color space used. See Properties in Shader Programs.

  • [PerRendererData]
    indicates that a texture property will be coming from per-renderer data in the form of a MaterialPropertyBlock. Material inspector changes the texture slot UI for these properties.

https://docs.unity3d.com/Manual/SL-Properties.html

相关文章

  • ShaderLab 属性,特性声明

    Numbers and Sliders Colors and Vectors Textures Attribute...

  • 如何使用属性_05

    Shaderlab属性类型和CG变量类型的匹配关系 ShaderLab属性类型对应的CG属性类型 Color,Ve...

  • Shader笔记——ShaderLab

    在Unity中,所有的Shader程序都是使用名为“ShaderLab”的声明性语言进行编写的。ShaderLab...

  • 自动属性声明->属性特性

    在Xcode4.2之后,Objective-C新添加一项特性:property 在@property中属性特性有3...

  • ShaderLab: 属性

    原文链接:https://docs.unity3d.com/Manual/SL-Properties.html ...

  • iOS----属性

    声明属性 Objective-C声明的属性特性提供了一种简单的方法来声明和实现对象的访问器方法。 概述 ...

  • NSString属性的声明:关于copy和strong

    iOS开发中经常会遇到关于NSString属性的声明,在ARC下,NSString属性的声明有两个特性关键字可选:...

  • 34章 属性

    34 属性 34.1属性的特性 存取类型任何一个属性可以声明为readwrite或readonly。默认为read...

  • 语法篇

    1、@property的作用是声明属性及其特性?( ✅) 2、@synthesize的作用是自生成属性的访问器(...

  • Objective-C总结----2.如何编写一个类(下)

    Objective-C2.0发布,新特性:自动声明、补全属性、点语法,大大提高了开发效率,现在我将用自动声明属性的...

网友评论

      本文标题:ShaderLab 属性,特性声明

      本文链接:https://www.haomeiwen.com/subject/ihgxyxtx.html