Linked Questions
19 questions linked to/from What are screen space derivatives and when would I use them?
25
votes
1
answer
33k
views
What does ddx (hlsl) actually do?
I'm a bit confused. The official documentation (http://msdn.microsoft.com/en-us/library/windows/desktop/bb509588(v=vs.85).aspx) says that ddx(input) is the partial derivative of the input with ...
14
votes
3
answers
9k
views
3D models budget. What matters more number of triangles or vertices
When I am making a model for a 3D game what should I take as a measure in my budget Polygons (triangles) or vertices? I have made an experiment with two sets 40000 cubes one with 8 vertices and 12 ...
14
votes
1
answer
15k
views
Animated textures for models; How to write a shader?
Was watching some Rocket League and notice there was animated decals and wheels.
.
I would like to implement something similar to the effects in the image above.
How would I go about writing a ...
6
votes
2
answers
14k
views
An efficient way for generating smooth circle
I'm looking for creating smooth circle. OpenGL supports point, line, and triangle. To create other primitives like circle, we utilize the preceding shapes. In my case, I've utilized points as follows: ...
4
votes
1
answer
5k
views
Any way to combine instantiated sprite renderers into one texture so I can apply into a plane at runtime?
So I am procedurally generating a tile set in Unity by instantiating different tiles that only have a transform and sprite renderer components. I managed to pack the sprites using unity sprite packer ...
5
votes
1
answer
5k
views
How to keep sprites sharp and crisp, even while rotating
How can I maintain crisp, sharp edges on sprites, while avoiding the aliasing caused by rotation?
None of the things I've tried produce a pixel-perfect non-rotated block, while allowing rotation ...
1
vote
1
answer
3k
views
Correcting projection of 360° content onto a sphere - distortion at the poles
I'm using the Autopano Giga 4.4 and Autopano Video Pro 2.6 to stitch and create spherical content, but I've recently moved into wanting to create 360° tours via Unity. I know this is partly a ...
3
votes
1
answer
3k
views
How can I map a texture around a sphere without a seam?
I am attempting to wrap a texture around a sphere without any warping using Unity's Shader Graph. I have been following this StackExchange answer, and have semi-successfully converted their shader ...
3
votes
1
answer
3k
views
GLSL shader algorithm to render a sprite map with a single draw call (on a single sprite mesh)
I'm trying to render a tile map world on a single sprite mesh (instead of one sprite per tile.) This significantly reduces the array vertex bus labor for extremely large worlds:
In order to do this, ...
1
vote
1
answer
2k
views
How to add antialiasing to my circle shader?
I made a circle shader by following this tutorial: https://www.youtube.com/watch?v=Ww1GbfnBH_Q. It is simple flat circle shader. The problem is that there are visible jigged lines on the circle edges. ...
0
votes
3
answers
2k
views
Why is the derivative important in game development? How did you use it in a real scenario?
I'm really eager to know how a programmer finds useful a derivative in game development, using a real scenario as an example. Also I plan to use this question to understand the importance of ...
3
votes
1
answer
779
views
Cutout fragment shader pixels arent square
It has been solved, link to the final shader:
Shader
The problem (as portrayed by the image below) is that the pixels seem to be, for lack of a better word, cut off. I wish to either display a pixel, ...
1
vote
1
answer
621
views
Unity mesh shader for outlining colour changes
I've written a shader to change colour on a deformable mesh's Z position. This is to create the effect of topographic/contour maps where the colour changes based on the height of terrain of the mesh.
...
0
votes
1
answer
846
views
error X4532 Cannot map expression to gs_5_0 instruction set
Using DX11 I have this line starting with TC = txDiffuse in a geometry shader that generates the error message. Can someone explain me the problem or if it is not possible to sample in geometry shader ...
0
votes
0
answers
265
views
Show the edges between the clipping plane and clipped objects
I want to utilize shaders to not only discard fragments if they are on one side of a predefined plane but also render a contour along the intersection.
My fragment shader currently does something ...