• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges

Cg

Cancel

Cancel

All Questions

  • Unanswered Questions
avatar image

meat5000 commented

Good resources for learning how to write shaders, Cg, ShaderLab?

Mar 5, '15 shader·graphics·resources·tutorials·cg

4 Replies

11 Votes

avatar image

thallippoli commented

How can I make my own shader include file (.cginc or .glslinc)?

Sep 25, '13 shader·graphics·cg·glsl

2 Replies

7 Votes

avatar image

Bunny83 commented

Why are texcoords (uvs) stored in float4?

Nov 15, '19 shader·cg

2 Replies

5 Votes

avatar image

VivienS asked

Which way to write a shader in Unity is the best?

Jan 28, '11 shader·performance·cg·bestpractices·custom-shader

1 Reply

4 Votes

avatar image

Cambesa commented

Shader Intellisense / Code completion

Oct 12, '15 shader·editor·cg·intellisense

2 Replies

4 Votes

avatar image

MikeMarcin edited

Cg tex2Dfetch

Nov 20, '13 shader·cg

0 Replies

4 Votes

avatar image

tomjen asked

What is the code for the standard cg fragment shader?

May 12, '10 shader·cg

1 Reply

3 Votes

avatar image

Aily commented

shader inverse(float4x4) function

Apr 4, '15 shader·cg·matrix·glsl·inverse

2 Replies

3 Votes

avatar image

x5lcfd commented

How do I add transparency to a cg vertex lit shader

Jun 4, '16 shader·transparency·alpha·cg·unlit

2 Replies

3 Votes

avatar image

unimechanic converted comment to answer

Can sampler2DArray be used?

Aug 13, '14 shader·cg·glsl

2 Replies

3 Votes

avatar image

customphase published

CG Shaders. Get pixels from previous pass (or write to texture)

Jan 31, '13 shaders·cg

0 Replies

3 Votes

avatar image

ifurkend answered

How can I transform a world view dir into tangent space in a Cg only shader

Aug 22, '20 shader·cg·transforms·tangents·viewdir

2 Replies

3 Votes

avatar image

Nullspace commented

Is there a way to pass an array to a Cg shader?

Feb 27, '13 shader·array·color·cg

2 Replies

2 Votes

avatar image

Gabriel 4 asked

Need help with a shader.

Dec 15, '10 shader·shaderlab·cg

3 Replies

2 Votes

avatar image

ScroodgeM answered

Stop shader values from being clamped

Jul 20, '12 shader·vertex·cg·fragment

1 Reply

2 Votes

avatar image

Ferb commented

Texture coordinate sampling in cg surface shader

Sep 25, '14 texture2d·cg·surface shader·sampling

1 Reply

2 Votes

avatar image

MountDoomTeam answered

Geometry Shader

Mar 5, '13 shaders·cg

3 Replies

2 Votes

avatar image

Liam-Lam answered

Ambient Occlusion Map in Shaders

Jul 27, '19 cg

1 Reply

2 Votes

avatar image

teigsy edited

Projector + custom fragment shader = endless texture draw

Nov 14, '17 shader·texture·cg·projector·tiling

2 Replies

2 Votes

avatar image

EricWGD commented

How do I render scalars to a Floating Point RenderTexture?

Dec 29, '18 cg

2 Replies

2 Votes

avatar image

DBN answered

How to specify my CGIncludes directories?

Nov 19, '16 shader·cg

3 Replies

2 Votes

avatar image

Alex_May edited

cross product in cg shader - error "can't find __getVectorIndex"

Feb 21, '14 error·shader·cg

1 Reply

2 Votes

avatar image

MaT227 edited

How to control Ambient Lighting and Spherical Harmonics

Aug 28, '14 shader·lightmap·cg·surface shader

0 Replies

2 Votes

avatar image

Beks_Omega edited

Unity5 v Unity4 Shader array errors

Aug 3, '17 unity 5·shader·unity5·cg

1 Reply

2 Votes

avatar image

Bunny83 edited

Flat Shading / No Vertex Interpolation

Aug 24, '16 shader·shaders·shader programming·shaderlab·cg

2 Replies

2 Votes

avatar image

Danisuper asked

Need help with object behind another one shader 2d

Sep 15, '17 2d·shaders·2d sprites·cg

0 Replies

2 Votes

avatar image

kingIZZZY asked

3ds max / Maya / Lightwave / etc exporting CgFX

Dec 16, '09 maya·cg

2 Replies

1 Votes

avatar image

sanmn19 commented

Send data from a inner CG variable back to a Shaderlab property, is it possible?

Dec 18, '15 shader·graphics·cg

1 Reply

1 Votes

avatar image

ScroodgeM answered

Get access to previous pass from CG

Jul 20, '12 shader·cg·custom-shader

2 Replies

1 Votes

avatar image

schetty answered

I cannot pass parameters to my custom shaders... help please...

Apr 11, '14 shader·cg·parameters·shader-replacement·renderwithshader

2 Replies

1 Votes

  • 1
  • 2
  • 3
  • ›

Followers

avatar image avatar image

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Related Topics

shader shaders shaderlab hlsl shader programming glsl fragment unity 5 lighting material graphics texture alpha vertex surface shader c# matrix shader writing vertex shader pass surface color uv error blending


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges