Tag Info

New answers tagged

0

It might be your display honestly. Some displays use less color depth than 32 bpp which can cause banding or flickering. You might consider dithering if you end up with no better option than addressing the banding.


0

Looking at the problem further, it just seems to be an issue in darker areas. Adding just a low level of ambient light, such as in the attached image, resolves the issue. Maybe someone else can elaborate on the cause of the problem? I consider the issue resolved for the moment, as I always have some level of ambient lighting present, but further explanation ...


0

Just to follow up in case others stumble across this: While I did re-arrange the vertex order to ensure 90 degree perpendicular normals, I found that didn't make a material difference to adjacent object lighting. The answer is that three.js doesn't intrinsically calculate lighting across adjacent objects in the scene graph, and while the shadowmap feature ...


0

You could write your own script to occlude lights. Something like this attached to the main camera: List<Light> Lights = new List<Light>(); const float OccludeDist = 100; void Update() { foreach (Light light in Lights) { if ((transform.position - light.transform.position).sqrMagnitude > OccludeDist * OccludeDist)) { ...


0

This is an old question. However, in the interest of others seeking help with a similar problem, I believe I have a plausible solution: You could have a model prepared for smooth shading (without the duplicate vertices) and present an option of emulating flat shading through your pixel shader. It is possible to calculate the normal at a given pixel by ...


0

I solved the problem by using the model matrix: o.worldPos = mul(_Object2World, v.vertex).xyz;


0

I believe I've solved most of the issues. The very light wall pieces on the left of the unity render were caused by them actually being duplicate pieces. Deleting the duplicates solved that issue. I then swapped my Main camera rendering path setting to "Vertex Lit" instead of "Forward". The other probs seem to have been caused by the point lights. I had ...


1

If you're also working with box2D, you could try box2Dlights, it's a pretty nice wrapper and it's easy to implement as well.


2

I'm not an expert about it but I'll try to explain. When you compute per pixel lighting in camera space, you transform your normal map from tangent space to camera space. The idea of working in tangent space is to transform the camera and lights to tangent space then perform lighting computations. So instead of transforming normals from your normal map to ...


1

There are ways to do dynamic lighting without shaders, although they're usually not as efficient. They often involve raycasting. The link below has some links to useful resources regarding dynamic lighting. http://www.java-gaming.org/topics/2d-dynamic-lighting/27012/view.html


3

You're doing it wrong - very inefficiently. Instead of rendering lightsources to your "lighting framebuffer", render the lighting contribution. That would be a soft disk centered at your light source instead of a single pixel. Example disk: ... and you can render that as a sprite! (Additive blending, clamp to 1 for best results). You can now bind that ...



Top 50 recent answers are included