Skip to main content

Questions tagged [depth]

Filter by
Sorted by
Tagged with
0 votes
1 answer
421 views

Y-sort is not working how I would expect in Godot. I have a player sprite, their feet are at the origin. I have a y-sorted tile layer. The mushroom base is at the bottom of the tile, it doesn't ...
Seph Reed's user avatar
  • 275
2 votes
1 answer
2k views

I'm working on a tutorial for creating wake waves with Godot, versions 3.5 and, importantly, the upcoming 4.0. It uses shaders (including visual) and works fine so far, but in attempting to get the ...
Michael Macha's user avatar
0 votes
1 answer
90 views

I am doing volumetric fog. In the first pass I write down the depth of the front polygons of the cube, in the second pass I write down the depth of the back polygons of the cube, in the third pass I ...
black4joss's user avatar
0 votes
1 answer
1k views

Am I correct that the OpenGL depth buffer has values between 0 and 1 while the z component of gl_Position is between -1 and 1?
wedesoft's user avatar
  • 125
3 votes
1 answer
2k views

I make use of ViewportTextures, kind of like rendering security cameras on screens. Now, I'd need to access the depth textures to do some comparison of images / pixels. How do I access the depth data ...
manabreak's user avatar
  • 1,078
0 votes
2 answers
906 views

I've created a depth texture in OpenGL (using C#) as follows: ...
Grimelios's user avatar
  • 589
-1 votes
1 answer
332 views

I did the following shader (looked up and changed for my needs): ...
maximus's user avatar
  • 99
0 votes
1 answer
3k views

I am new in Unity and now only studying for my work project. I need help with computing real distances from depth values. Can't figure it out. My shader is: ...
Hillbilly Joe's user avatar
1 vote
1 answer
2k views

I am new in Unity and specializing in another field. But now I have to rapidly study it for a new project. I will be very thankful if anyone explain me how to read values of the depth buffer. I wrote ...
Hillbilly Joe's user avatar
4 votes
4 answers
6k views

I'm working on a top-down shooter kind of game, but it lacks the feeling of depth. When you have a sun, it's a bit easier, because the sun can cast shadows. But it's even harder, when there is no sun,...
Tudvari's user avatar
  • 801
1 vote
2 answers
2k views

I'm using Raylib, and I'm attempting to place tiles on a level, and the algorithm for placing the tiles is working. The problem is that the player will display over the walls on the bottom right hand ...
Hawkbirdtree's user avatar
0 votes
1 answer
547 views

I've been working on a custom tile-based map editor for a while now, and everything works as expected, or so I thought until I've tried rendering the actual map including the dynamic objects as well. ...
TheDBeetle's user avatar
1 vote
1 answer
306 views

As in the title, I have an effect prepped for my game which applies certain derived parameters to a post-processing effect after the player enters a boundary I created with ProBuilder. Finding how far ...
Michael Macha's user avatar
6 votes
3 answers
1k views

It seems the only time depth is used to discard data is during rasterization, i.e. at the fragment level. In the geometry stage, I've only see culling and clipping of vertices. Is it not possible to ...
Colin's user avatar
  • 161
1 vote
0 answers
352 views

I need to improve the shadows in my scene. At a first look they don't look too bad: They look awful when the camera gets closer to them, showing weird artifacts. I would like to know what are the ...
Blue Bug's user avatar
  • 1,112
0 votes
1 answer
118 views

I used Tiled Editor for making maps for my own game, I do not run any engine or anything. I have separated terrain layer and object layer in TiledEditor. However I have problem with trees I want to ...
Dakado's user avatar
  • 1
3 votes
3 answers
1k views

I'm trying to reproduce a post-effect with unity seen in the answer here. Chromadepth answer For the moment I just manage to reproduce the wave effect with a quick edge detection. I tried multiple ...
tuyasa's user avatar
  • 33
0 votes
1 answer
775 views

I am having an issue with the walls in my game. I have set them as objects and used the script: depth = -y; inside their create event. However, when I walk my character in front of them, the ...
johan855's user avatar
  • 103
0 votes
1 answer
641 views

I'm using global fog and the standard assets Depth Of Field script but it has a strange effect on the edges of far away objects. How can I make the white edges along the trees blend smoothly into the ...
mr-matt's user avatar
  • 2,779
1 vote
2 answers
7k views

I wrote the following shader which purpose is to force draw a mesh over the rest, regardless z-depth : ...
tigrou's user avatar
  • 3,279
2 votes
2 answers
2k views

https://www.youtube.com/watch?v=QuvAEqgHrMY&feature=youtu.be https://www.youtube.com/watch?v=5ob1JsPIGAs&feature=youtu.be ...
Blue Bug's user avatar
  • 1,112
1 vote
1 answer
1k views

Currently I am writing a small application with Qt and OpenGl and I choosed QOpenGLWidget for rendering graphics. That's how I declared my widget: ...
Denis's user avatar
  • 127
5 votes
2 answers
561 views

I want to get the depth of vertex in 0 to 1 range(like it done in the shader) and I do it like this ...
harut9's user avatar
  • 157
3 votes
1 answer
1k views

I'm newer to Unity so bear with me. I'm using Unity2D and so far I have my character up and walking around, colliding properly with his surroundings, and I've ...
Matthew's user avatar
  • 31
5 votes
1 answer
2k views

When it comes to pre-sorting the draw calls for a given frame, I am aware of two different methods for optimising. The first is to batch draw calls by their material. This minimises shader changes ...
Xenoprimate's user avatar
1 vote
0 answers
281 views

I found a video a while ago for how to make a dynamic DOF in unity. It fires rays from the camera and positions an empty at the location that the ray first hit. How can I change this so that it doesn'...
mr-matt's user avatar
  • 2,779
2 votes
1 answer
3k views

I'm trying to implement SSAO in my application but it doesn't look as it should. I think that the problem is with depth buffer linearization but I tried almost all methods which I found on the Web and ...
Harry's user avatar
  • 690
3 votes
1 answer
387 views

I'm trying to implement depth-only SSAO and for that, I render a depth map into a texture and pass it to my SSAO shader which then uses it. The problem is that when I try to output the depth map ...
CpCd0y's user avatar
  • 301
5 votes
0 answers
2k views

I was having some trouble with cubemaps in OpenGL, and was hoping to get some help. I've been following a tutorial about point light shadow mapping using cubemaps, where a geometry shader is used to ...
kingsapo's user avatar
  • 151
1 vote
1 answer
1k views

I'm trying to render depth texture in XNA 4.0. I'm read few different tutorials several times and realy cannot understand what I'm doing wrong. Depth shader: ...
user avatar
1 vote
1 answer
956 views

So I am drawing an inventory with slots like so: ...
Tikkes's user avatar
  • 173
1 vote
0 answers
126 views

Im back again with yet another problem :( My current problem is with my billboard effect. Im having trouble trying to get the depth correct so that billboards that are closer to the player are ...
Ryan Earnshaw's user avatar
0 votes
2 answers
2k views

I render a lot of quads on the screen into z direction (20 x 2000). I want to get the depth value in a final render target. But it looks like z is always 1.0f. I checked the result with the OpenGL ...
Tobias's user avatar
  • 111
1 vote
1 answer
519 views

I'm currently in the process of making a platformer, and am currently in the process of creating "depth" into my game, by making Up/Down-W/S control your depth. (Come closer to screen, go further). ...
user avatar
-1 votes
2 answers
719 views

I've been working on this problem for a while now. My problem is that the sphere in the top image, is under-lapping the plane which should have a lower Z value. Although, when depth testing is ...
Ecumene's user avatar
  • 19
3 votes
3 answers
3k views

I am creating an 2d bird view tile game using the pixijs render framework. Like pokemon or oldtime zelda. In those games you sometimes walk behind buildings where the tile would be drawn on top of ...
Ismail's user avatar
  • 99
1 vote
2 answers
2k views

I created a skybox in OpenGL (through LWJGL), but the only way I found to render it behind all objects was to make it very big. This leads to ugly edges between the 6 skybox planes. Optimally, I ...
mojomex's user avatar
  • 91
0 votes
2 answers
2k views

I recently stumbled across this http://vimeo.com/99118680 video and was stunned by the beautiful painted art and colors. But mostly I couldn't believe how everything appeared to have three dimensions ...
Saliken's user avatar
  • 357
2 votes
1 answer
623 views

I want to draw my pre-rendered depth map to the scene. I get my depth value in the following way: basically (Pixel Shader) ...
FriendlyFruit's user avatar
9 votes
2 answers
2k views

I want to be able to do what you see in the image, but with a single wall. The player should be able to walk on either side of the same object. That is, the same wall is below the hero when I go down ...
Xkynar's user avatar
  • 601