Questions tagged [pixel-shading]

The tag has no usage guidance.

pixel-shading
Filter by
Sorted by
Tagged with
0 votes
0 answers
99 views

Unity lighting and Shading for tilemaps

My team and I are working on a Unity game and I'm having trouble getting my shadows right for when I use different tiles. I want it to appear smooth for the terrain like in the 2nd picture. I can ...
Katoshia's user avatar
3 votes
1 answer
2k views

blinn-phong shading with numpy

I am trying to implement blinn-phong shading in numpy for educational purposes. However I am stuck at debugging what parameters are doing for several days now. My general idea was the following. ...
Kaan E.'s user avatar
  • 515
5 votes
2 answers
4k views

gl_PointSize OpenGLES clarification

What does setting gl_PointSize = 1.0 in vertex shader means or achieve? Does that mean the vertex itself is a pixel?
Deepak Sharma's user avatar
0 votes
0 answers
736 views

What pixel shader can I use to remove a background color, but keep transparent pixels?

I can use a pixel shader in WPF to remove a specific color, but there are alpha pixels layered over the background. I want to remove a background color, but keep alpha pixels. For example, I have ...
Ziya Jafarov's user avatar
0 votes
1 answer
232 views

Phong - Half Vector Specular both sides

When implementing PhongModel shading. The Specular term appears on both sides of the geometry. The specular term is being computed using the Half Vector. In the front output image it seems that it's ...
Eder's user avatar
  • 78
0 votes
0 answers
113 views

Repeat a color scale along a surface with interpolation

I am trying to shade a surface with a sequence of colors to achieve certain visual effects. One effect is a gradient from one color to another. Assume I have a lookup texture with a black and a white ...
J-S's user avatar
  • 425
0 votes
1 answer
2k views

Error 'overlapping register semantics not yet implemented' in VertexShader

I am trying to perform diffuse reflection in hlsl. Currently I am working on vertex shader. Unfortunatelly I get following error, when trying to compile with fxc.exe: C:\Users\BBaczek\Projects\MyApp\...
bartosz.baczek's user avatar
-1 votes
1 answer
357 views

Pixel shading not so smooth

I am implementing a basic heightmap with simple shading (ambient + diffuse). The shading is implemented on the fragment shader, which is shown below. #version 330 in vec3 fragNormal; out vec4 ...
lhahn's user avatar
  • 1,241
1 vote
1 answer
2k views

Issue creating map shading in Matplotlib imshow by setting opacity to data gradient

I am trying to add shading to a map of some data by calculating the gradient of the data and using it to set alpha values. I start by loading my data (unfortunately I cannot share the data as it is ...
MyCarta's user avatar
  • 818
0 votes
0 answers
95 views

Lambertian Shader not working

I'm trying to make a Lambertian shader for my ray tracer, but am having trouble. The scence still seems to be flat shaded, just a little darker. Such as in this picture This is my Shader Class: ...
user2320239's user avatar
  • 1,018
2 votes
1 answer
634 views

How to implement density maps with instanced rendering

I came across this amazing blog about rendering grass by Kévin Boulanger. In his project he has used a certain density map: The black areas represent places in 3D world where grass is to be rendered....
2am's user avatar
  • 697
0 votes
3 answers
2k views

Is it possible to draw simple geometrical shapes in a Pixel Shader?

I'm currently learning about shaders and graphics pipelines and I was wondering if a pixel shader could be used to create, for example, a triangle or a more complex shape like a zigzag. Could this ...
TheAuzzieJesus's user avatar
3 votes
1 answer
697 views

How to enable per pixel shading in Ogre3d

I am lighting a plane with a spot light in Ogre3D. However, the edge on the hotspot shows zigzag effect. It looks like the shading on the plane is done at every vertex without any interpolation. The ...
shapeare's user avatar
  • 4,203
1 vote
0 answers
205 views

illumination and shading for computer graphics

I am preparing for my test tomorrow and this is one of the practice questions. I solved it partially but I am confused with the rest. Here is the problem: Consider a gray world with no ambient and ...
Sam I Am's user avatar
1 vote
2 answers
2k views

Simple Ray Tracer, Diffuse Shading problems c++

I'm writing a basic Ray-tracer in effort to better understand the whole thing. I've come across an issue that's been holding me back for a little while now, Diffuse shading of a sphere. I've used a ...
Unknown's user avatar
  • 131
1 vote
0 answers
475 views

How to do phong shading in POV-ray

I am using POV-ray raytracer for rendering. I have a mesh of triangles, when I render that using : mesh { triangle { < corner_1>, <corner_2>, <corner_3> } } ...
user2481909's user avatar
0 votes
1 answer
3k views

Unity No Shading "Fullbright"

Is there a way to fullbright your Level in Unity3D? I just want to remove shading and lights in a surreal project to get a fullbright world where textures are always shown as they are intented to be, ...
RenokK's user avatar
  • 698
0 votes
1 answer
798 views

Create flat shaded cube using triangle strip

I'm not completely solid on how triangle strips work with normals. I want to make a flat shaded cube so I wrote vertices for a triangle strip that make a cube. That works. I made a cube using a ...
Jehanlos's user avatar
1 vote
2 answers
3k views

HLSL Shader (Phong /w normal map)

EDIT: IT seems like the only problem left now is that the light comes from the opposite direction if i use the calculation with a normal map. If i only use: n = normalize(Input.NorView); it seems to ...
puelo's user avatar
  • 5,681
1 vote
1 answer
319 views

DirectX 9 Shading not linear?

I'm using managed DirectX9 with C#. I made a visualisation of a cnc machine. On computer 1 it works perfectly. a round tube is bright grey on the left side, and the shading is linear to a dark grey. ...
user1095428's user avatar
0 votes
1 answer
1k views

iOS GLSL Spherical Harmonic Shader. How Do I Raycast Using the iOS GPU

I am beginning an Spherical Harmonics shader project for an iOS app I am writing. I have begun by reading this excellent in-depth paper on the subject (PDF) - http://bit.ly/aQmax3. The paper ...
dugla's user avatar
  • 12.9k
2 votes
1 answer
4k views

C++ OpenGL: Ray Trace Shading Isn't Properly Shading

I'm a CS student and for our final we were told to construct the reflections on multiple spheres via ray tracing. That's almost literally what we got for directions except a picture for how it should ...
Cobaltsam's user avatar
5 votes
1 answer
2k views

Android GLES20.glBlendEquation not working?

Ive been trying to make a 2.5D engine with depth and normal map textures for a few weeks now, not unlike whats used here Linky. After thinking the drawing of a depth map in the fragment shader from a ...
user1005998's user avatar
2 votes
1 answer
1k views

realtime terrain lighting

What would be the best way to provide realtime lighting in an OpenGL terrain scene? The level of detail between of each quad will be generated dynamically as it is subdivided as it zooms in, so a pre-...
oldSkool's user avatar
  • 1,232
2 votes
1 answer
221 views

Restricting Pixel shader on particular area of image

Is there any way to restrict Pixel shader on particular area of image. BR
Saghar's user avatar
  • 693
2 votes
5 answers
4k views

Lighting inside of a sphere?

I have this question in mind: I need to make a scene that looks like a real sky. My first idea was to make a cube and texturize it. It wasn't that good looking. I came up with the idea of using a ...
pooya's user avatar
  • 901
0 votes
2 answers
105 views

Is there any crossplatform C library for using Pixel Shading filters?

Is there any crossplatform C library for using Pixel Shading filters? to run pixel shader inside your programm, beter as native part of your programm (not like precompiled file), and better for using ...
Rella's user avatar
  • 66k