Skip to main content

Questions tagged [stencil-test]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
1 answer

Are stencil buffer dimensions required to match render target dimensions?

I may not need as precise pixel-perfect stenciling as my render target during stencil tested render pass. I could be okay with stencil test happening at half or quarter of resolution to save bandwidth,...
simd's user avatar
  • 115
1 vote
1 answer

Is it possible to fill in Stencil Buffer programmatically via fragment shader?

I've never worked with stencil buffers, but I'm researching if it is the right tool for my task. Basically I don't understand yet if stencil buffer can only be filled in by some hardcoded rules during ...
simd's user avatar
  • 115
2 votes
3 answers

Fast clipping without clearing stencil buffer

I'm writing an OpenGL application that runs on a Raspberry Pi, i.e., a quite resource-limited system. Essentially, a few quads with RGBA textures are overlayed/alpha blended on top of each other with ...
Jonas Mechtheim's user avatar
5 votes
1 answer

Do stencil tests use any acceleration techniques?

Stencil bits are often used for optimizations, for instance having full screen lighting passes only affect certain pixels. Does the stencil test mechanism use any acceleration structures of any kind (...
Alan Wolfe's user avatar
  • 7,801
6 votes
1 answer

Do occlusion queries respect the stencil test at all?

In a project where I want to select visible objects using using a screen-aligned polygon and various conditions for what "selected" means with regards to that polygon, I'm basically drawing the ...
Christian Rau's user avatar
5 votes
1 answer

Honouring Depth Test with Stencil Test

I'm using OpenGL's stencil test to carve out a semicircular hole in a transition frustum with a cylinder oriented perpendicularly. However as one can see below, while this objective is achieved, the ...
Sharat V Chandrasekhar's user avatar
6 votes
0 answers

How much processing power does stenciling actually save?

For example, let's assume I'm rendering cascaded shadow mapping, but for whatever reason, instead of one of the typical approach, I do the following: Render the lowest resolution shadowmap Copy part ...
Llamageddon's user avatar
12 votes
2 answers

Is it possible to find out how many fragments made it through the stencil test?

I have an OpenGL application which uses stencil tests quite extensively to render irregular shapes (a bit like a simple 2-D CSG). If I could find out how many fragments passed the stencil test and ...
Martin Ender's user avatar
  • 2,730