Dark spaces cast by the presence of a solid object blocking the flow of light. Often helpful for telling where your character is going to land.

learn more… | top users | synonyms (1)

6
votes
2answers
750 views

Where to cast light/shadows in a 2.5D view?

I'm working on a tile-based 2D pseudo top-down/side-on game very much in the graphical style of Prison Archiect. More specifically, I'm referencing their style of drawing wall tiles where you can see ...
2
votes
0answers
51 views

Would this 2D Lighting and Shadows implementation work? [closed]

I'm writing a top-down 2D tile-based game and I'm trying to decide on how to implement lighting and shadows. The game will have a large number of light sources, some static and some moving around the ...
2
votes
0answers
69 views

Jagged light bleeding where surface is roughly parallel to shadow mapping light direction

I am using Unity but this question might not be proper to this engine. I have projected the shadow map onto this sphere but there are grazing shadows. Is it possible to avoid it or to correct it as I ...
0
votes
0answers
22 views

Only one side of the object reflects light while in the shadow

in my scene I have a plane as a floor and a plane as a building next to it, my directional light is rotated to make the building cast shadow on the road. I placed a few cubes on the road, the ...
0
votes
0answers
32 views

LibGDX Box2DLights - Global Illumination

I'm using LibGDX + Box2D to create dynamic lights in my game, but I'm currently stuck. I'm trying to light up every game object in the game with its own shadow, kinda like global illumination. Do you ...
0
votes
1answer
45 views

My point light shadows only really work if my point light is at the world origin (0,0,0)

When I move the light, the shadows will fall apart as if their occluders aren't occluding them in certain areas. For example, in the following scene, I move a pointlight 400 units down the Z axis, I ...
0
votes
0answers
40 views

Peter-panning gets worse with front-face culling [closed]

So ive been following this tutorial(http://www.opengl-tutorial.org/intermediate-tutorials/tutorial-16-shadow-mapping/) And it specifies that the peter panning effect could be removed by enabling front ...
3
votes
1answer
48 views

Issues with depth calculation in HLSL shader

I'm currently trying to implement shadow maps in my graphics framework. I ran into an issue with depth calculations I wasn't able to solve myself (yet). I did a lot of testing and debugging and think ...
3
votes
1answer
127 views

Why are there no dynamic shadows in UE4?

So my problem is that other than for static objects which have baked shadows from building lighting, there are no shadows for movable objects, like those cubes. Neither from the Light source actor, ...
1
vote
0answers
41 views

Consistent Shadow Map Filtering

I want to filter my shadow map generated by PSSM, but the problem is that I have a inconsistent filter size. The problem is that the shadow map sources rotate to find the best fit for the camera ...
1
vote
0answers
95 views

Smooth+Flat shaded meshes cause shadow artifacts (understanding the source of the problem)

I'm using blender to create assets to use in Unity3D, and I'm having some trouble understanding how the smooth/flat shading interacts with shadows, I'm sorry if it has been asked before, but all the ...
4
votes
3answers
147 views

Can't find the solution to the “shadow acne” problem

This is how it looks now: This is the code that generate the shadow matrix an shaders source: void shadow::calculateShadowMatrixFromLightPointOfView(vector3f lightPosition, vector3f ...
3
votes
0answers
66 views

How to draw Shadow Volumes in one draw call?

I've got a simple app that draws 3D cubes using instance rendering and I'm implementing Shadow Volume. Each cube's vertex, uv, normal and index data are statically stored in 4 vertex array buffers. On ...
2
votes
0answers
39 views

Virtual infinite plane in shadow map

I have a WebGL deferred rendering pipeline, where I'm rendering shadow map with VSM technique. The goal is that the scene, or model, is hovering in space, and in addition to casting shadow on itself, ...
2
votes
1answer
57 views

Directional Light shadow mapping error - opengl

i need some help with shadow mapping (directional light) in opengl 3.3 and GLSL. The problem is that the shadows are not displayed correctly over de 3d models and primitives: This is the code that ...
1
vote
1answer
346 views

Multiple lights shadows

I'm trying to achieve multiple lights shadows. Currently my program works using only 1 spotlight as a light source that produces shadows. Well... I want to involve multiple lights to give a more ...
1
vote
0answers
24 views

Directional light view frustum stabilisation

Calculating directional light view frustum based on scene objects(bounding frustum) results in noticeable scene jittering on camera movement in CSM and non-CSM rendering code paths. What are the ...
0
votes
0answers
74 views

How do I calculate the matrices required for cascaded shadow maps?

I'm trying to switch over to Cascaded Shadow Maps (CSM'S/PSSM's), however this topic is quite complex and I'm not quite getting the expected results. Note: I already have a functioning standard ...
4
votes
1answer
64 views

Only one object rendered to FBO for Shadow Map

I've been playing around with rendering shadow maps using FBOs in OpenGL. I set up a simple directional light in my engine and managed to get a shadow map rendered. My Scene is a big castle and the ...
2
votes
0answers
100 views

Shadow mapping - Can't get the right texture coordinates

I'm trying to implement shadow maps for Spotlight's, but alas I can't get them to work. I have verified that my fragment shader is getting the shadow map texture. I can sample from it in the ...
1
vote
0answers
69 views

Instancing meshes messing up scene lighting

I've been rendering a scene (some objects over a large field of grass) to test shadow mapping which is working fine. But when I use instancing to "gain" performance, I not only get a decrease in ...
0
votes
1answer
58 views

Generate Mesh of Shadow Volume

Given a mesh, I want to generate another mesh that is effectively a shadow volume of this mesh. I am looking for an algorithm/solution/implementation/reference that can do this under the following ...
29
votes
1answer
3k views

Why is shadow mapping the standard?

Though I am a programmer by trade, I have barely touched game development at all. I've had this question for some time, and now that I'm looking into game development I thought it would be a good time ...
5
votes
1answer
137 views

Dual paraboloid shadows on GLSL

I'm trying to port an XNA example to OpenTK + OpenGL, I found it here http://graphicsrunner.blogspot.com.es/2008/07/dual-paraboloid-shadow-maps.html But I'm having a really hard time, I think my maps ...
2
votes
1answer
244 views

How to create 2D shadows and lighting?

How do I create shadows and lights in a 2D top down perspective game? I want to achieve an effect similar to this game (also made in unity) where some objects like a torch, different sprites, and the ...
10
votes
1answer
266 views

How can I implement lights & shadows in a multi-layer 2d tilemap?

I am in the process of writing an isometric game from scratch, and I'd like to know how/if I can add lights and shadows. The code I have so far can be found here, but it should be enough to know that ...
2
votes
1answer
580 views

Creating Fog Of View in 2D game with lighting method

I'm creating 2D side scrolling game with Unity, and i want to add feature where the player come into a cave, then all going dark, the player turn on the flash light, so the player can see around ( ...
1
vote
1answer
202 views

Ray tracing - soft shadow

I'm implementing my own ray tracer as an iPad app for a school project. At the moment this is the result: I need to add the last requirement, soft shadows, but I can't find a complete reference ...
1
vote
1answer
63 views

Efficient dynamic character shadows [SW Rasterizer]

I am working on a SW rasterizer for a quarter-century old console (think sub-100 MHz RISC CPU, no dedicated 3D HW, couple megs of RAM) and am approaching a stage where I will be adding dynamic ...
1
vote
0answers
95 views

Why would an ambient occlusion (AO) shader's performance be dependent on light direction?

One of my favourite games recently implemented ambient occlusion as a graphics feature, which appears to perform very well in most circumstances - except during sunrise and sunset. As someone who is ...
2
votes
1answer
134 views

Shadow mapping bone animated model

I am trying to get shadowmapping right for my animated models. It works perfectly for static meshes but the animated models are just wiggeling a bit here's the vertex shader for rendering to the ...
1
vote
1answer
61 views

LibBDX create a tail when the object is moved

I am looking for a way to implement in my game a kind of shadow/tail which will be displayed after the object is moved. Should I use animation? If yes how? Here an example:
0
votes
2answers
168 views

Directional light and finding relevant shadow casters

Right now when culling the models to render for the directional light shadow map pass I just do a view frustrum culling using the main camera. At some angles, the objects will be outside the view but ...
5
votes
2answers
230 views

How do I optimize 2D visibility cone calculations?

I'm creating a simple 2D game and got a little bit stuck with a visibility cone algorithm, influenced by walls and other obstacles on the map. The only issue I'm currently having, is that it's very ...
2
votes
0answers
331 views

PSSM and tightening the split frustrums

So I have implemented PSSM which currently does not care about the objects in the scene, meaning alot of resolution is wasted on empty space. This image shows the bottom two splits wasting alot of ...
3
votes
0answers
95 views

Does anyone know what technique was used in Minecraft to create shadows? [closed]

Specifically I want to know the technique used to render shadows under animals and players. I would like to create shadows like that for my own block game but I don't even know what to google. Any ...
0
votes
0answers
74 views

XNA/C# Shadows look strange in orthographic

I have implemented shadows in to my game engine. They look fine when rendered in projection mode as a projected light, however I get a strange "blocky" look when they are put into orho'. I will be ...
5
votes
1answer
961 views

unity 5 how to get a shadowmap

I'm writing a custom shader in unity 5 that requires a shadowmap (not just for drawing shadows but also for different computations involving scattering particles through fog). Does anybody know how to ...
1
vote
1answer
63 views

Pick which directional light shades which object

Suppose you have two directional lights pointing at one sphere from different angles. You would expect the sphere to cast two shadows, but it turns out that this isn't the default behavior. The first ...
1
vote
0answers
434 views

How can I get shadows to appear correctly when using a custom projection matrix?

EDIT: This has been officially marked as a bug in Unity. If anyone else has this issue, you can vote here for Unity to fix it. As mentioned in this thread, I'm using a custom projection matrix in ...
0
votes
1answer
317 views

Drawing faded lightmap in 2D polygon

I have been making a 2D visiblity algorithm by following this tutorial http://simblob.blogspot.se/2012/07/2d-visibility.html I have managed to create the light vertices and it works fine when I draw ...
4
votes
2answers
325 views

Hide some objects from the camera (fog)

I'm trying to implement a visibility representation in a 2D game ( no plains, no quads - plain 2D ) In the examples below I have calculated what the player can see using raytracing and added all the ...
0
votes
1answer
70 views

LWJGL Stencil shadow problem

I've a problem with shadow (Stencil). So when i draw the shadow they looks good, but when the object to draw is underground his shadow is wrongly rendered. My game is do with LWJGL/GL11. Normal ...
4
votes
1answer
863 views

C++ OpenGL ShadowMap Issue/Artifacts

I am currently implementing basic shadow mapping in my C++ Custom Engine using GLSL 4.10. It is currently working with basic PCF anti-aliasing and very minimal reduction for unwanted artifacts. Here ...
3
votes
1answer
294 views

Shadows in html5 canvas game

I'd like to ask for reference. I met an article about how to cast shadows in games. I'm using html5 canvas (currently without webgl) with javascript for my projects. The article mentioned above is ...
3
votes
1answer
242 views

Shadow mapping. I don't understand what to do after creating the depth texture

I'm taking an intro to computer graphics course, so this is something we haven't touched on. I am reading this tutorial ...
0
votes
0answers
112 views

How to move vertices of matrix in order to cast a 2d shadow?

I am trying to add shadows to my 2D xna game. Currently I have created a "shadow" using the texture of the caster with a transparent gray color, rotated, and stretched using a matrix. This, though, ...
7
votes
0answers
421 views

Variance shadow maps don't want to render properly

I've implemented VSM (and also ESM) in my engine but results are for me not as I expected and saw in many examples published on network. I set filtering of shadow maps to GL_LINEAR but when I compare ...
1
vote
0answers
207 views

Shadow map shimmering, indexing outside the shadow map

I have tried to reduce shadow shimmering/flickering using technique described here: http://msdn.microsoft.com/en-us/library/windows/desktop/ee416324%28v=vs.85%29.aspx I works as I want and shimmering ...
0
votes
0answers
177 views

Depth texture white in shader

I am trying to implement shadow mapping into my project and am stuck at this problem: If I'm reading the shadow map values with glReadPixels and linearize those values, I am getting exactly the value ...