Skip to main content
20 votes

When is a compute shader more efficient than a pixel shader for image filtering?

John has already written a great answer so consider this answer an extension of his. I'm currently working a lot with compute shaders for different algorithms. In general, I've found that compute ...
bernie's user avatar
  • 830
19 votes
Accepted

Performance of Compute Shaders vs. Fragment Shaders for Deferred Rendering

After more analysis, the TL;DR here is that, yes, the slowdown is due to memory locality, and yes the pixel order is to blame. More interestingly, by writing the shader differently, we can greatly ...
geometrian's user avatar
  • 1,990
6 votes
Accepted

Dealing with wasted space when using SIMD on CPU for vector maths

There's a third option you've neglected. Because of how graphics APIs work, typically you have to copy the data between the CPU and GPU anyway - even if you're on a mobile SoC where they share the ...
Dan Hulme's user avatar
  • 6,840
6 votes
Accepted

Can I use QueryPerformanceCounter to measure single draw or compute call performance?

That diagram includes a CPU block titled "wait for GPU". I do not see the part of your code that includes an equivalent command. Furthermore, even if it did include ...
Nicol Bolas's user avatar
  • 9,852
6 votes
Accepted

Tasks of a professional graphics programmer?

I don't know if this is exactly what you're looking for. I work tangentially in the film and TV industry. I don't work for a studio, but I work on the software that studios use for their productions. ...
user1118321's user avatar
  • 3,421
5 votes

Performance impact during texture layer loading

From the way the problem only manifests when you start overwriting previously used texture tiles, I suspect you're running afoul of some driver heuristic that's attempting to manage the lifetime of ...
Nathan Reed's user avatar
  • 25.1k
5 votes
Accepted

How can an OpenGL visualization run for weeks?

Opengl doesn't care how long it has been running. However there are a few other challenges with long running applications in general: memory leaks, both normal ones and opengl resources. lack of ...
ratchet freak's user avatar
5 votes
Accepted

Register pressure in Compute Shader

Lowering register pressure doesn't necessarily give you any performance boost though. I recently went through this exercise myself on GCN architectures (for a simple ray tracer) and reduced register ...
JarkkoL's user avatar
  • 3,646
5 votes

When is a compute shader more efficient than a pixel shader for image filtering?

I stumbled on this blog: Compute Shader Optimizations for AMD Given what tricks can be done in compute shader (that are specific only to compute shaders) I was curious if parallel reduction on ...
maxest's user avatar
  • 66
4 votes
Accepted

How does everyone count "Rays per Second"?

I've seen both, unfortunately. I'm not fond of rays per second as meaning exclusively primary rays and I'd suggest "paths per second" or better yet "samples per second" instead. "Complete ray" is not ...
Karl Schmidt's user avatar
4 votes

Estimating the area of a triangle-circle intersection

Working Towards an Exact solution Just some quick thought before I must run! Ok, let us turn the problem on its head. What if one does not calculate the area of the triangle cut by the circle. ...
joojaa's user avatar
  • 8,437
4 votes
Accepted

Optimizing performance on hardware

Although you may be able to detect what hardware is available as a first approximation of a computer's capability, depending on this might not be useful since the same hardware may behave differently ...
trichoplax is on Codidact now's user avatar
4 votes

Challenges of Offline Rendering

Since you've used the "path tracing" tag, I'm assuming you're thinking mainly about light transport. At SIGGRAPH 2015, there was a course on the topic of path tracing in movie production that may be ...
Stefan Werner's user avatar
4 votes

Should you measure mesh complexity in triangles or vertices?

Since you're talking about "vertex shaders" and "fragments", I assume that your question is to be interpreted in the context of real-time rendering using the graphics pipeline on a modern GPU through ...
Michael Kenzel's user avatar
4 votes

Are MMORPGs, specifically WoW, limited by their latency in terms of FPS?

Online games do not work the way you describe. The server doesn't give the client one frame's worth of data every frame. That would be awful. Instead, every client has its own copy of the game state, ...
Dan Hulme's user avatar
  • 6,840
4 votes
Accepted

Can meshes be reused in raytracing?

Example code tends to be bad code from a performance (or even software engineering) standpoint because... it's an example. Its primary purpose is to make it clear how to do a thing, not to do it in an ...
Nicol Bolas's user avatar
  • 9,852
3 votes

Dealing with wasted space when using SIMD on CPU for vector maths

While the existing answer adress your question quite well, I'd like to add some general advice, even if you might already be aware of that. Rather than just wasting that fourth component on the GPU, ...
Christian Rau's user avatar
3 votes
Accepted

Why are tessellation shaders disliked?

An answer with details gotten elsewhere: It's bad on mobile: ARM doesn't have a tessellation unit so is emulated in software. Tiled based architectures will write vertex data to main memory before ...
Alan Wolfe's user avatar
  • 7,801
3 votes

How does MSAA performance scale?

Roughly speaking, what the Supersampling Anti-Aliasing method does is: For each pixel in the image to render "Split" the pixel of a target image, usually in 2, 4, 8 or 16. Actually this step is ...
wip's user avatar
  • 1,861
3 votes
Accepted

Should you measure mesh complexity in triangles or vertices?

Vertex count may be more accurate of a measurement of "mesh memory usage and mesh rendering time", but vertex count is not nearly as easily measured. Yes, given a specific mesh with all of its ...
Nicol Bolas's user avatar
  • 9,852
3 votes

How can an OpenGL visualization run for weeks?

Yes, of course. The duration it has to run for doesn't make much difference. Your Android smartphone's main GUI is OpenGL, and phones typically have an uptime longer than four weeks. Air Traffic ...
Dan Hulme's user avatar
  • 6,840
3 votes
Accepted

Challenges of Offline Rendering

From the presentations on non real time rendering I've seen at SIGGRAPH, the answer is basically yes, a lot of time is spent making render times faster. For instance, even with huge amounts of ram, ...
Alan Wolfe's user avatar
  • 7,801
3 votes
Accepted

Different Vertex structures in multi-purpose system

Most rendering engines do need to handle multiple vertex structures depending on the type of shading being used on the mesh. If there are only a small number of discrete vertex structures, you could ...
Nathan Reed's user avatar
  • 25.1k
2 votes
Accepted

How can I improve the performance of my custom Global Illumination approach?

You should always profile to determine where your slowdown occurs. From your question, it's unclear whether your work is CPU bound or GPU bound. But I don't really understand what is does: Does ...
aces's user avatar
  • 1,353
2 votes

How can an OpenGL visualization run for weeks?

To make an application, OpenGL or not, run for extended time safety-critical applications are mostly built to restart on error, be it a driver bug, your application is broken, or hardware failure. If ...
Andreas's user avatar
  • 359
2 votes

The most performant way to organize vertex data on modern GPUs

Apologies, I was going to add a comment to your question thread but found I ended up elaborating too much. My development experience is from a DX 11 perspective so some of this may not hold in OpenGL ...
ErnieDingo's user avatar
2 votes

Best practice for managing many shaders and merging multiple shaders into one?

I target mobile/tablet devices with my product this is less of a concern with desktop GPUs. unity and unreal allowing full flexibility on adding shaders & materials at-will Well, Unity and ...
wip's user avatar
  • 1,861
2 votes
Accepted

Is glDispatchCompute(a,b,c) any faster than glDispatchCompute(a*b*c,1,1)?

Broadly speaking, no, these won't really matter. In specific cases, it could, but only because it might influence the order in which work groups are processed. And that would mean that it might ...
Nicol Bolas's user avatar
  • 9,852
2 votes
Accepted

What does the z-buffer look like in memory?

The Z buffer used to be specialized memory set aside for a single purpose, some web sites still explain it like that, but no longer. Now the Z buffer is just a chunk of memory you allocate, or an API ...
pmw1234's user avatar
  • 3,324
2 votes
Accepted

Embree: Performance issue when ray casting User Defined Geometry

My best guess at why you are not seeing a speed up with your user geometry, is that your example does not contain much BVH traversal. With traversing a triangle/quad mesh more time is spent traversing ...
Peter's user avatar
  • 529

Only top scored, non community-wiki answers of a minimum length are eligible