Skip to main content
Filter by
Sorted by
Tagged with
2 votes
0 answers
79 views

I’m trying to sample the scene’s depth buffer in a post-processing pass. According to the SceneKit Technique documentation, the built-in semantics COLOR and DEPTH should be “what SceneKit rendered in ...
José Roberto Abreu's user avatar
0 votes
1 answer
67 views

I'm working on a screen-space outline effect for a low-res, cartoony game idea. I'm very new to HLSL programming and fullscreen Shader Graphs, but by looking at tutorials, I've mostly gotten the depth-...
TT87's user avatar
  • 39
1 vote
1 answer
56 views

I am implementing a basic partial transparency system. While this is not correct, order independent transparency, this does work well enough (is more-or-less correct) when dealing with objects that ...
CPlus's user avatar
  • 5,128
2 votes
0 answers
69 views

I'm very new to shader programming, so forgive me for any knowledge gaps or mistakes I've made. I am currently following a technique discussed in Nvidia's GPU Gems: https://developer.nvidia.com/...
Ryan Xu's user avatar
  • 63
2 votes
0 answers
77 views

I've fixed all the possible issues I could in the implementation process, but I still can't figure it out, so I'm sharing my repo. Looking at the code, objects with larger Z values are not being drawn ...
Dev ZIWON's user avatar
0 votes
1 answer
37 views

I’ve run into inconsistent behaviour in depth testing and I don’t know if this behaviour is specified anywhere. My question is: when using EQUAL as the depth-testing function, what is the expected ...
Andrew's user avatar
  • 14.5k
3 votes
1 answer
143 views

I try to understand each member of the struct VkPipelineRasterizationStateCreateInfo, but its depth bias related member confused me, especially about the depthBiasSlopeFactor. I find description ...
SZYoo's user avatar
  • 508
2 votes
1 answer
80 views

If OpenGL FBOs have a provision for multiple colour targets with GL_COLOR_ATTACHMENT0 to GL_COLOR_ATTACHMENT31 but only one depth/stencil target with GL_DEPTH_STENCIL_ATTACHMENT, then how would I be ...
Komal Shashank's user avatar
0 votes
1 answer
424 views

Studying the code of three.webgpu.js, I come across the terms "linear depth", "perspective depth", and "orthographic depth". I know there is a visual difference between ...
Pershing's user avatar
  • 428
3 votes
1 answer
173 views

I have the following situation: I want to transfer depth values from a framebuffer with 1 sample to a different framebuffer with 8 samples. I think, the only way how this can be accomplished is by ...
j00hi's user avatar
  • 6,041
0 votes
1 answer
100 views

I am trying to implement rendering points on top of geometry as in Blender. The algorithm is as follows: rendering is done through PointList without depth test. The depth test is done manually in the ...
Wusiki Jeronii's user avatar
0 votes
1 answer
105 views

In the engine I'm working with, I'm drawing some polygons to be used as a stencil for a portal of sorts, and I want to clip depth to it, in the sense that anything I draw after setting up the stencil, ...
Jordon Moss's user avatar
0 votes
1 answer
173 views

I'm creating a 3D globe with elevation: I now want to add click detection to get a 3D world xyz position from a 2D screen xy + depth (from a click). I'm using the following code (inspired from ...
Tim Autin's user avatar
  • 6,173
1 vote
2 answers
205 views

https://www.youtube.com/watch?v=QWImAT-g7tE Hey, I’m having trouble with overlapping 3d objects. My 3D rendered models/objects are drawn on top of each other based on which draw method gets called ...
MaybeAFish's user avatar
0 votes
1 answer
471 views

The behavior I'm hoping to achieve here is to have my fragment shader write to gl_FragDepth and for a depth bounds test to be performed on that value before going on to a stencil test. There are a few ...
sgfw's user avatar
  • 356
0 votes
1 answer
194 views

I HAVE been trying this for hours now. I have no clue why the triangle is not rendering on the screen. D3D11_DEPTH_STENCIL_DESC dsDesc = {}; dsDesc.DepthEnable = true; dsDesc....
abx_pradB's user avatar
1 vote
1 answer
900 views

My setup is like this: Render a small scene (ie. a single 3D model) into a framebuffer with 1 color and 1 depth attachment. Render the color buffer into a fullscreen quad Most code examples online ...
alexpanter's user avatar
  • 1,646
1 vote
0 answers
222 views

I'm trying to learn DirectX12 and have been following along with 3dgep's tutorial. When I attempt to clear the depth stencil view, it works fine on the first call but throws Exception thrown at ...
Isaac Dexter's user avatar
0 votes
1 answer
248 views

I've read many articles about what is and how to set a reversed depth buffer in OpenGL (just search for opengl reversed depth on Google and I've read 6 positions). None of them mentioned any vertex ...
Shout's user avatar
  • 693
0 votes
1 answer
71 views

I am working from a sample at https://interactivecomputergraphics.com/. My goal is to have a simple example that shows alpha blending with opaque and translucent triangles. I have 6 squares (2 ...
dhhepting's user avatar
1 vote
1 answer
175 views

I'm trying to render meshes with the points and edges as black lines and points, similar to a modeling engine like blender. I have 3 separate draw routines to draw points, lines, and faces (each face ...
BENG's user avatar
  • 161
1 vote
0 answers
311 views

I imported a mesh from Blender 2.90.1 (glTF 2.0 exporter, all transforms applied, normals calced outside) into Godot v4.0.2.stable.official [7a0977ce2] and when setting no_depth_test = true, it seems ...
B3D4ev_guy's user avatar
0 votes
1 answer
815 views

In my project I capture the scene to a RenderTexture and I want to be able to loop over those pixels to get the depth of each pixel. I have so far tried to convert RenderTexture to Texture2D and loop ...
drygloss's user avatar
1 vote
1 answer
376 views

I use this function to linearize the depth value in my shaders: float linearize_depth(float d, float zNear, float zFar) { return zNear * zFar / (zFar + d * (zNear - zFar)); } What function would ...
HenriV's user avatar
  • 43
0 votes
1 answer
254 views

I am trying to render a scene with partially transparent sprites in Pyglet. I want to activate z depth test to render them but this yields the following: two images overlapping The two images ...
Anthony's user avatar
  • 11
0 votes
0 answers
48 views

I have an FBO with two textures attached to it. One of them is color buffer attachment and the other is depth buffer attachment. After rendering the scene with the frame buffer attached I properly get ...
Nandu Krishna's user avatar
0 votes
1 answer
431 views

I wanted to draw a 3D cube, but it doesn't display correctly. That is, the Z buffer (depth buffer) does not work. The initialization of the depth buffer occurs in the InitDepthBuffer method, which I ...
TooLong's user avatar
0 votes
1 answer
155 views

I am trying to create some 2D UI drawing in D3D11. I am trying to get the draw calls down as much as possible to improve performance. Previously, I batched up as many textures as possible to send to ...
anon18975's user avatar
0 votes
1 answer
606 views

I'm trying to draw simple scaled points in my custom graphics engine. The points are scaled in pixel space, and the radius of the points are in pixels, but the position of the points fed to the draw ...
Robert's user avatar
  • 525
1 vote
1 answer
817 views

I'm really new to graphics programming in general, so please bear with me. I am trying to add shadow mapping from a distant light (orthogonal projection) into my scene, but when I follow the (very ...
user722227's user avatar
0 votes
1 answer
106 views

Here is the code for my Z Buffer, it returns a black screen when I draw it. sf::VertexArray ZOrder(sf::VertexArray verticies, std::vector<float> z_buffer) { std::vector<float> order; ...
Noah Burchell's user avatar
0 votes
1 answer
234 views

I'm using an SCNTechnique with SceneKit to implement my own multipass rendering. I have 1 DRAW_SCENE pass that outputs to separate colour and depth targets, and then a second DRAW_QUAD pass that uses ...
Elle Sullivan's user avatar
1 vote
2 answers
742 views

I am trying to adapt the code from this answer to use 1/z depth buffer and here is my attempt /* g++ trig.cpp -o trig -lSDL2 */ #include <algorithm> #define SDL_MAIN_HANDLED #include <SDL2/...
The Rizzler's user avatar
0 votes
0 answers
107 views

Currently I'm making 2d game with java libgdx. In my game I need to have multiple kinds of liquid to occupy floor of room. (something like splatoon but in 2d) Each liquid need track of what entity it ...
MossyForest's user avatar
0 votes
0 answers
336 views

In OpenGL, I'm trying to render a depth map that doesn't loose precision with fa away objects. Do you know of any way I can accomplish this task? My approach so far: I tried the "reverse depth&...
Lilla's user avatar
  • 219
4 votes
1 answer
998 views

I am learning DirectX12 programming. And one thing that has me confused is in all the tutorials I read, they only create a single depth/stencil buffer even when triple/double buffering is used with ...
yosmo78's user avatar
  • 641
2 votes
0 answers
358 views

I'm doing some customized 2D rendering to depth buffer that connects to a texture of internal format GL_DEPTH_STENCIL. In fragment shader, the normalized Z value (only 0.0 to 1.0 is used, I'm lazy) is ...
jiandingzhe's user avatar
  • 2,185
1 vote
1 answer
989 views

I'm attempting shadow mapping in OpenGL, and have been unable to render specifically GL_DEPTH_ATTACHMENT to a frame buffer. glCheckFramebufferStatus does not return complete but only when targeting ...
Celeste Soueid's user avatar
0 votes
0 answers
314 views

I have been trying to implement SSAO following the LearnOpenGL implementation. In their implementation they have utilized the positions g-buffer to obtain the sample positions depth value and I am ...
Krellex's user avatar
  • 753
1 vote
1 answer
72 views

I'm quite new in 3D graphics so I'm just learning :-D. I wanted to create a cube as my first project. I chose PyOpenGl and ran into the following problem: Depth testing didn't work for me. I searched ...
Vasek Blanarovic's user avatar
0 votes
0 answers
590 views

Is there an efficient way to calculate the order of 3D bounding boxes according to their distance from a specific point? I can't simply take the center point of the bounding box since there are often ...
flashback_6's user avatar
1 vote
1 answer
407 views

I am trying to read the depth buffer and store it into an array using openTK in C#. This is my code so far: //Get depth buffer int[] depthBufferID = new int[1]; GL.GenBuffers(1, ...
GeorgeRDX's user avatar
1 vote
0 answers
127 views

I was using the following code to produce depth values: sealed class GL24: iDepthValues { const double mul = 2.0 / 0xFFFFFF; float iDepthValues.value( int index ) { // Have no idea ...
Soonts's user avatar
  • 22.3k
0 votes
1 answer
319 views

I'm trying to test my algorithm on the lineMOD object detection dataset. According to the author, the depth values are stored as unsigned short values. I've managed to load the depth values into a cv::...
John Katsantas's user avatar
0 votes
0 answers
72 views

I have a 3D model of a house with some lines draw on it in teal. I'd like to reduce the opacity of lines that should not be visible to the camera because they are hidden behind parts of the roof.
nickponline's user avatar
1 vote
0 answers
312 views

I have got a scene with an object and a cubemap in OpenGL. My atmosphere shader(rayleigh scattering) renders to a quad which is right infront of the camera. This of course obstructs vision on my ...
kurito's user avatar
  • 43
2 votes
1 answer
924 views

In short I would like to read a single pixel value from a WebGL 2 depth texture in JavaScript. Is this at all possible? The scenario I am rendering a scene in WebGL 2. The renderer is given a depth ...
Berthur's user avatar
  • 4,524
0 votes
1 answer
94 views

I'm following this tutorial on 2D shadow mapping and I've gotten it working in WebGL. Now, I am looking to develop a way to recompute single rows in the depth texture, without clearing the entire ...
Ryan Peschel's user avatar
  • 12.1k
2 votes
1 answer
2k views

I am using the example code of the documentation from PyVista: import pyvista as pv import matplotlib.pyplot as plt from pyvista import examples mesh = examples.load_random_hills() p = pv.Plotter() ...
mzr97's user avatar
  • 69
1 vote
1 answer
584 views

I am rendering a single mesh test object that contains 8000 cubes, 1 monkey, and 1 plane. I checked normals and winding orders. all seems correct for mesh. if I render a single instance, the depth ...
aramok's user avatar
  • 75

1
2 3 4 5
10