🎉 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 HLSL Activity
Room 8 Group’s Game Development team for PC & Console (Dragons Lake), has made its innovative Render Engine Infrastructure (REI) tool available as an open-source solution. Initially developed to transform game porting, development, and preservation, REI is the result of tireless work carried ou…
I have a small issue with my shaders. Sorry if it is not the right place for this question. In general, the essence is that for my application on dx12, I have shaders in glsl (I'm too lazy to rewrite them because there are many, and they are not only for dx12), and I compile them into hlsl using sp…
@Juliean Wow. I could not notice the fact that I defined light as float. lol. I remember that I declared light as float3 definitely but it was not. It works well now. Thanks for your help, you saved my days !
Hi @aerodactyl55 , many thanks for your reply.
Yes - agreed re. device capabilities. It was one of the first things I checked… and all the things I think I'm using are marked as supported on both GPUs I'm testing on (an NVidia mobile GPU and an embedded Intel GPU). It could still be some…
Hi,
I'm working on a game in UE4 that uses a compute shader to perform 3D rotations on 2D images. The final rotated image is drawn to a render target after the calculations are done.
Problem: on certain hardware, we're seeing “striping” occur, where rows of pixels are missing from the final image (ex…
@Jimmyberf Along the lines of what Frob suggested:
// output
float3 outputColor = saturate(ambient + diffuse + specular) * input.Color.rgb;
problem is solved, it works perfectly.
Simply dont know, what i formerly made wrong.
YOU ARE THE BEST !!!
What ^ @joej said. But I'll add a personal axiom that if it's atomic and it's not an index or a counter … you probably need to think again. It applies to all atomics but Compared (min/max) atomics (like an atomic ray-hit distance) are the more obvious example of how atomics can become problems in h…
I'm not sure, but I would probably use the jittered matrix to unproject the depth. I'm not sure if your approach of using scene depth is the right way to calculate velocity. The examples I've seen do the work in the vertex shader of the main pass (gbuffer/forward), where the vertices get multiplied…
Why do you sort the (seemingly opaque) tiles? Are you sure this improves performance instead of just rendering them naively?
I build my terrain mesh on the CPU but in chunks. Maybe you could separate it into chunks as well, assuming updating the terrain (CPU → GPU) really is an issue with performanc…
I am trying to convert a post processing vignette into a torchlight effect and have the centre position brighter instead of the dark edges but unable to work out depth buffer so as to get depth adjustments.
My code is in HSLS (Dx9) and this is what I have (based off CopperCube game engine - irrLicht…
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…
@Juliean Hmm ok, worth thinking about. I'm going to experiment a bit today and see how it'll turn out.
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…
Job interview tests and school homework are not allowed here. You need to solve job or school tests on your own. Thread locked.
codefreak2022 said:
give a way to greatly reduce cost of this shader.
Your other post looked suspiciously like a job interview test, and it has been locked. This one also is now locked. You have to solve job interview tests (and school tests) on your own.
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.
In this part of the 2.5D Game in Unity series, we will write a shader to resolve the depth issues that appeared in the scene we created.
As we observed in the previous part of the tutorial, moving the camera results in rendering order glitches.
This issue originates from the way Unity renders sprites…