🎉 Celebrating 25 Years of GameDev.net! 🎉
Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!
Latest Shader Activity
hbr3ehreg said:
@Juliean
Thanks for your reply!
Do you think Uber shader approach is something limited to linear game like Doom? It's has less variants than open world games I guess.
I don't think this really matters, I'd say the main difference there would be in spatial division, world streaming…
The goal is to give our players various items to choose from. For this example, our players will choose a weapon, armor for protection, and boots. We want to visualize these choices on the character.
The imagined system should enable quick equi…
Maybe this is part of the problem:
float3 va = normalize(float3(size.xy, s21 - s01));
float3 vb = normalize(float3(size.yx, s12 - s10));
float3 localNormal = float3(cross(va, vb) / 2 + 0.5f);
You forgot to normalize the final normal, while normalizing the two tangents isn't needed. So it should be:
f…
jsmithir123 said:
I am interested in learning a little more about the double intersection count for points that overlap. I am not exactly sure on the details of how you say you solved this previously. Could you expand a little?
Well you can see in the shape below that the scan line passes thoug…
Hi
I'm trying to implement wireframe drawing with hidden line removal. In the geometry shader I make lines from the input triangle. I plan to change the z-value in the geometry shader so that the lines are closer to the camera to avoid stippling (maybe this approach is wrong too).
I want to do …
To fix z fighting when rendering a wireframe on top of another mesh, you want to change your depth test to something similar to GL_LEQUAL (less than or equal to comparison), instead of the usual GL_LESS. This will make your depth test succeed if the depth is equal (which is the case if you render t…
Ok I made it.
My own rendering architecture confused me.
I had to make some adjustments to accommodate offscreen rendering.
What you have to do:
- all rendering is made offscreen, exactly the same way you did before (same bindings etc.) with the only difference being that now you use a render target that…
JoeJ said: This one seems pretty nice: https://jcgt.org/published/0011/03/05/
That's the most useful one for routine dirt, rocks, etc. All it does is divide the texture into hexes, spin the hexes randomly, fuzz the edges, and recombine. That can be done in a shader. That's enough to break up annoyi…
Thaumaturge said:
But I do ask: how accurate does this have to be? Why not just implement it in the vertex shader, as you already have in mind, and have done with it?
That's what I'll do.
Thanks for the support.
JoeJ said:
Not sure (also about the correct term), but if so, you can get this much simpler, and probably more robust as well:
Well, I do want a time component, in order to account for variations in frame-rate. Still, it might be interested to try both, and see which works the better.
JoeJ said:
I gues…
In the end I worked around this as follows:
1) I set “precision highp float; ” in my shader, so that it uses 32 bit, even on OpenGL ES
2) Then, to improve the performance, I first render to a smaller texture FBO, then scale it up to the screen
The Space Jump effect is pretty simple when looking at its individual components.
Previously I created a 3D star field for the environmental rendering.
I use the 3D locations of these stars in the effect.
When the effect starts, I start cranking up the light emitted for each star.
This is done by just …
I have a bmp and I want to texture a mesh with it.I calculated the uvs for the mesh and sent them to vertex shader.I have no idea how to take the data from.bmp file and send it to pixel shader.
Bitmap bitmap = new Bitmap(texturePath);
The vertexShader.hlsl:
#pragma pack_matrix( row_major )
cbuff…
Hi,
I wrote a small tessellation shader and I can write to a SSBO (checked using RenderDoc) but reading the data back right away does not seem to work. If I set the tessellation levels directly, I can see that my code works, but going through the SSBO data does not.
Here is the SSBO:
struct SSBO…
Thank you guys!
Hi,
I'm developing a game with bending shader. The world is curved and I need to use VFX with shader graph such as lightning. There is a screenshot for it.
The obstacle that I selected is seeming below of the actual position cuz of the bending shader but I cannot use my vfx with this bending shader. …
@mjp I downloaded RenderDoc as per your suggestion and it turns out the buffer was full of random data… I guess this is because CLight was a class and not a struct. I changed it to a struct and now everything works fine. Thanks for your help!!
@mattstone2728 @joej So i actually managed to solve it. It was related to the precision, but indirectly. When getting to close to the zero Y value, and as the algorithm is in KM, the distances start to get very small and thus getting into precision errors. The solution was to limit the position of …
@noxil @johnnycode The problem was indeed with the mesh importing. The tutorial I used to load meshes recalculated the normal by using the tangent and binormal vectors. I have changed it to use the normal data from the mesh file instead. The normals now appear smooth. Thanks for your help!
wonka007 said:
I try to make them as generic as possible.
Perhaps try to make them as generic as needed.
GPU is a state machine, only calls that goes operating on it- are the state changing ones, dx11 contains at least a few utility functions which are not GPU calls. Or maybe none, who knows, I do not contain all of it and I have used only GPU calls of the API.
Hi everyone,
Today I want to talk about rendering. Last time, I implemented some random dungeons generation. Since the map can get a bit labyrinthic, I wanted to find a way to help the players orientate themselves. So I decided to add torches that auto-ignite when you get close to them;
But it means…
Creating realistic digital humans for real-time 3D animation is now possible with Reallusion’s new Digital Human Shader. A complete set of shaders for skin, eyes, teeth, and hair are available, along with SSS(Sub -Surface Scattering) and Micro Normal updates for iClone 7.7 and 3D character creation…