• 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
  • Home /
avatar image
0
Question by user-7302 (google) · Dec 10, 2010 at 03:11 PM · ztest

Image-based shader Ztest issue

Hello, I am in the process of writing an image-based shader requiring two different z-passes. - one with Ztest LEqual - one with Ztest Greater However, in all cases, I get a Ztest LEqual buffer. I am using Unity Pro, and I get an almost satisfactory result when I use the Ztest Greater on a material, but it never works on image-based shader. Is there something obvious I am missing?

Also, I know there is a builtin shaderlab variable that stores the offset to convert UV coordinates to screen pixel coordinates. Does anyone know its name?

Comment
Add comment · Show 1
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Justin Warner · Dec 10, 2010 at 03:41 PM 0
Share

What's the shader for? The only reason I could think of making it is for a projection kind of thing, which is already made/supported in Unity...

Also, you might want to check out:

http://forum.unity3d.com/threads/56180-Strumpy-Shader-Editor-Beta-3.1-released-(performance-usability-upgrade)

0 Replies

· Add your reply
  • Sort: 

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Welcome to Unity Answers

The best place to ask and answer questions about development with Unity.

To help users navigate the site we have posted a site navigation guide.

If you are a new user to Unity Answers, check out our FAQ for more information.

Make sure to check out our Knowledge Base for commonly asked Unity questions.

If you are a moderator, see our Moderator Guidelines page.

We are making improvements to UA, see the list of changes.



Follow this Question

Answers Answers and Comments

No one has followed this question yet.

Related Questions

ZTest, and ZWrite Problem rendering a Cluster of Quads 2 Answers

Overrender all without ZTest Always 0 Answers

Z Fighting Help - How to get bias for ZTest only, not ZWrite 0 Answers

How to have sorting order/layers used when Z depth is the same? 1 Answer

Display complex object when it is behind the wall 5 Answers

  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges