Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [lighting]

The tag has no usage guidance.

-2
votes
0answers
22 views

compute light intensity [on hold]

Compute the Light Intensity at Point P = (0,0,3) lying on the plane when viewing direction is [0,-1,1]
11
votes
4answers
444 views

For shader math, why should linear RGB keep the gamut of sRGB?

sRGB is often contrasted with "linear RGB." Images are stored on disk and passed to displays in sRGB, which is approximately perceptually uniform in intensity. Shader math is done in linear RGB, ...
6
votes
2answers
156 views

PBR missing rim darkening on non metallic rough surfaces

If you have a dielectric (non metallic) sphere with a large roughness value (say, 0.95), and put it in a lighting environment that has a constant onmidirectional lighting value (such as 0.5) Cook-...
0
votes
0answers
84 views

Spherical harmonics ringing after coefficient scaling

I have a light probe system which gathers lighting information in a form of spherical harmonics. What I do is project surrounding static geometry surface colors (without lighting) onto SH. Then, in ...
0
votes
0answers
69 views

Image-Based Lighting and Light Probe usage understanding

I have read this thread about Light Probe but still confused. Why does IBL (Image-Based Lighting) is used only for local illumination compare with light probe ? From what I read, light probe is for ...
3
votes
1answer
124 views

How to deal with light leaks?

I'm struggling with light leaking through meshes (especially thin ones) due to interpolation between probes located on the opposite sides of those. First approach I took was mapping all static ...
3
votes
4answers
140 views

How to access several textures from huge amount of textures in a shader?

I'm developing a light probe based GI solution and currently dealing with light leaks due to interpolation between probes located on opposite sides of the walls. I want to tackle the problem by ...
0
votes
0answers
28 views

How calculation-intensive is a complex light source?

Say you have a translucent material with a pattern. You place it on top of another surface, and then move it away. The light on the second surface should go from a copy of the pattern to being ...
1
vote
1answer
39 views

Non-point lights

Is there a technique for implementing non-point lights (i.e. light that has actual physical dimensions)? I can't think of anything except than making a light source out of multiple point lights, but ...
2
votes
0answers
91 views

Not understanding the lighting equation for volumetric cloud rendering

I've been looking The Real-time Volumetric Cloudscapes of Horizon-Zero Dawn, but I'm very confused by a few terms. The presentation mentions "The Henyey-Greenstein phase function" on page 54, ...
2
votes
1answer
157 views

Radiosity normal map light baking

I'm trying to implement radiosity normal maps from the old Valve paper: Half-Life® 2 / Valve Source™ Shading.pdf | valvesoftware.com I've tried generating the light maps using Vray and 3dStudio max, ...
1
vote
1answer
81 views

Light Falloff through a grid

I'm playing with a grid-based lighting system, where light is transported and accumulated through a grid. I initially tried attenuation based on ...
1
vote
0answers
56 views

Omnidirectional Faded Soft Shadows

I'm doing research to implement a shadow algorithm for omnidirectional soft shadows in a real-time 3D renderer. I've read about PCF but to me it doesn't look very realistic since it doesn't "fade" ...
1
vote
1answer
148 views

How to interpolate vertex normals for Phong lighting when barycentric coordinates are negative?

I'm interpolating normals for Phong lighting models. Since I am calculating in the light of each pixel, I'm doing the interpolating after the viewport transform has been applied. So I save a version ...
4
votes
1answer
167 views

Experimental real-time shadowing techniques?

The three most popular shadowing techniques for real time applications are: Shadow maps Advantages: Fast "Simple" Disadvantages: Numerical limitations lead to artifacts and jaggy shadows You ...
3
votes
1answer
107 views

How does opengl fixed function pipeline determine specular lighting with an orthographic projection

I have a scene set up with an orthographic projection with the near / far set from -5000 to 5000. The model view is centered at 0 in the z-axis. I am rendering a sphere centered at z=0 with lighting,...
1
vote
1answer
75 views

Ringlike artifacts produced by rays bouncing off a light source

I recently set up a (very basic) ray-marched path-tracer, and I'm getting strange surface patterns on my area light [link]. I'm using known-valid analytical normals for the light's surface, and the ...
3
votes
1answer
167 views

Directional Light ViewSpace Calculation

I am a bit confused in terms of directional light calculation in OpenGL. Generally we care about the direction of the directional light and we use it with the normal and view (toCamera) vector to ...
1
vote
1answer
41 views

What program can bake transparent light maps?

So I have this racing game I'm trying to modify that uses lightmaps that fade to transparency for light sources. An example from the game: I've been trying to produce a similar effect but with no ...
5
votes
1answer
118 views

Roughness Remapping

I have been recently exploring physically-based rendering (PBR), but there is one part that still confuses me. I don't quite get roughness remapping, as described in the PBR section on Learn OpenGL. ...
1
vote
0answers
67 views

Culling point lights with specular

Well, it's easy to cull point lights when you only need to know the diffuse bounds, but what to do when materials around the light have a specular reflections enabled? The method won't work in this ...
2
votes
1answer
837 views

Path tracing with Next event estimation and area lights auto occlusion

I am working my way through my first path tracer and I am currently designing how to deal with area lights. I have two questions: Each object in my scene can have a Light attached to it, this is how ...
1
vote
1answer
139 views

How do you implement perspective correct Gouraud shading across a triangle?

What's the algorithm for doing so? I have flat shading working and I have perspective correct texture mapping working. Is the way your raster Gouraud shading much different from the perspective ...
1
vote
0answers
43 views

Lighting ramps compressed to zonal harmonics

Let's say I have a lighting lobe represented as a ndotl ramp texture, how do I compress it into a zonal harmonic?
4
votes
2answers
237 views

How does UnrealEngine handle depth?

Today I found something really interesting (I've never seen something like that). While debugging the buffers used in lightning, I see that the depth information is stored in what looks like cascades ...
5
votes
2answers
957 views

How to calculate attenuation and radiance in PBR? (point and directional lights)

I would like implement physically based rendering, following this tutorial I was able to find a list of light sources ordered by lumens, but I have no idea how to use it in the calculations. ...
1
vote
0answers
42 views

Emission maps that interact with a bump map

I am trying to create an effect where a bumpy billboarded texture is illuminated by a emission map that is also billboarded but is logically closer to the camera in 3D space. In this way a blue ...
7
votes
1answer
512 views

Constant screen-space-width rim shading

As of lately I've been studying a bit of shaders (in Unity), and am trying to recreate the "light-based inline" that can be observed in the latest Legend of Zelda. But maybe the task is a bit above my ...
6
votes
2answers
309 views

Ambient Lighting

On the Wikipedia page for the Phong model, it says that the ambient term is a constant, and just gets added on to the other terms. But on other pages like LearnOpenGL it says you should take the ...
3
votes
0answers
113 views

Exact Formula for Diffuse Hemisphere Lighting

The OpenGL Programming Guide states the formula for diffuse hemisphere lighting on a surface with normal vector $\vec{n}$ as $L_o(\vec{n}) = L_i(\uparrow) (1-\frac{1}{2}\sin(\theta)) + L_i(\downarrow)...
5
votes
2answers
201 views

What is missing in this image that stops it from looking like a photograph?

Look at this image: This is CG, Saya, a project meant to make as real CG as possible to the point of becoming indistinguishable from reality. I would say that it is pretty believable. But, it still ...
1
vote
2answers
406 views

How to find Light Direction from a Point on a surface to an Area Light

How can I a find the Light Direction/Ray from a Point on a surface to an Area Light? Is there a universal technique to do this for all types of lights (circle, rectangle, sphere & tube)? Although ...
3
votes
1answer
240 views

Does smooth lighting work with Gouraud shading on single triangles?

I'm currently working on a project where a 3D model gets computed through an isosurface algorithm. This algorithm outputs single triangles with vertices and normals, but without indices. So therefore ...
6
votes
0answers
140 views

Dual paraboloid shadow texture edge seams

I implemented dual paraboloid shadows for point lights. The goal was to reduce the number of shadow passes. Also the target is GLES3.0 so no layered rendering is available. The shadows work, and ...
1
vote
0answers
40 views

What could cause realtime lighting within a viewport to be calculated on the wrong part of the screen?

(I initially posted this in a section that is less suited for the particular issue, oops) I'm having this issue on some of my client's computers (this is for a Unity asset) that I cannot reproduce on ...
5
votes
3answers
436 views

Formula for the ambient light intensity of a scene?

I understand that ambient light is light that occurs a result of light from a given source refecting off an infinite number of points in a scene, thereby illuminating all objects in the scene ...
1
vote
0answers
47 views

Specular Highlight Gray When Behind Model

What would cause this grayscaled backside? When my camera is behind my model I see a grayscale specular highlight. However, in front of it is perfectly fine. Here's my shading code. (Software ...
7
votes
1answer
311 views

Confused about prefiltering environment maps (Manson 16)

I'm working my way through this paper about GGX-filtering environment maps: http://www.ppsloan.org/publications/ggx_filtering.pdf I find myself stuck on the basics. In particular, I am confused by ...
-1
votes
2answers
642 views

Emission of light from texture on WebGL

I have to build a texture of a cube that models the emission of light by the object. Any tips? I really don't know where to start.
1
vote
0answers
282 views

WebGL Spotlight

I have to add a spotlight to my rotating cube so this is my code: HTML ...
5
votes
1answer
238 views

Irradiance Map Equation What is “dω”?

Link to paper : Irradiance and Incoming Radiance | lawrence.edu Using a shader to compute En Computing En as described above is a very compute intensive operation, because we have to compute ...
1
vote
1answer
154 views

How to organize Lights and Models?

I'm interested in how to organize in code (I prefer C++) lighting. Problem is: I have Scene which contains Model where model ...
6
votes
1answer
108 views

Amount of light reaching the sensor of pinhole camera model

Consider hypothetical camera with pinhole (in mathematical sense) lens and is sensor, like in below image. Is it the case that the central region of the sensor will receive more light (pixels will be ...
4
votes
1answer
221 views

Phong: Real-time rendering of Metal and Plastic Materials

Using a shader that works like Phong, what would be the difference between painted Metal and plastic? I seem to remember reading in books years ago, that I no longer have access to, the following: ...
3
votes
3answers
179 views

What's the concept of “Ray” really?

I'm learning Ray Tracing using this MIT tutorial. I've heard Ray Tracing only in the context of lighting. I.e. I understand that ray casting is used to light an object that has been already drawn. ...
4
votes
1answer
119 views

How to send shadow rays to window light source with glazing

For rendering an indoor scene where light source is skylight coming in through the window opening, one can consider the window polyline as the light source, with the sky distribution, in direct ...
7
votes
1answer
310 views

How Sunlight is added in Bidirectional Path tracing?

How is distant directional light source(like sun) added in BDPT? If this is an indoor scene that gets sunlight through windows, how is this handled in BDPT(other than to consider Sun as a big disc far ...
5
votes
1answer
290 views

Path Tracing With Multiple Lights

I've got my path tracer working great for a single light, but I'm having trouble coming up with a solution for scenes with multiple lights. My first thought was to just send a ray to each light and ...
1
vote
1answer
97 views

Acceleration techniques for CPU soft-shadow calculation in light mapper

My light mapper can generate soft shadows just fine - for each texel I cast a ray to the light, offset by some distribution of the 'area' of the light on disc. The problem is that I am casting many ...
5
votes
2answers
137 views

Radiance at a nearly perpendicular angle is almost infinite?

As far as I understand, radiance is a measure of the "intensity" of light in a direction defined as a differential cone . It's measure is Flux per solid angle per projected area. $L = \frac{d\phi}{d\...