Questions tagged [graphics]
Graphics are visual presentations. Questions using this tag should also be tagged with the appropriate language and graphics subsystem in use. For more general graphics questions, consider Computer Graphics Stack Exchange (computergraphics.stackexchange.com).
graphics
20,708
questions
0
votes
0
answers
7
views
Is it ok to calculate differences for every shadow light type as vec3s or it's better to use if statements?
I'm implementing shadows in my game but I also want my shader to be as general as possible.
My first implementation had 3 different functions:
layout(binding = 0) uniform sampler2DArrayShadow ...
0
votes
0
answers
12
views
Rotating bitmap and keeping track of location on new image C#
If I rotate a bitmap and want to keep track of a point on the original image as translated on the new image, how would I achieve this. I essentially want to know where the top right corner of the ...
-2
votes
0
answers
24
views
Compiling OpenGL programs in Lazarus works, but exe closes while running OpenGL [closed]
Earlier I had no problems running OpenGL progs in Lazarus (Free Pascal). But now I installed a new videocard (GeForce RTX 4070) compiling works but while running the program an OpenGL window appears ...
0
votes
1
answer
41
views
Illegal Argument when trying to draw
I'm trying to draw a chess piece on the board I created but keep getting an error that seems my picture can't be found.
Exception in thread "main" java.lang.IllegalArgumentException: input ==...
0
votes
0
answers
29
views
How to project a 3D cuboid onto a 2D camera image?
I'm working on a project where I need to render a 3D cuboid onto a 2D camera image. The image should be displayed with a width of 600px, maintaining its aspect ratio. Here are the details of my cuboid ...
-1
votes
0
answers
9
views
Debian : how to fix my graphics drivers installation?
I just installed debian with kde on a machine with a nvidia graphic card and an amd cpu who have integrated graphics.
When i install the package nvidia-drivers and reboot, when i login, the screen get ...
0
votes
1
answer
32
views
WebGPU multiple render passes for 1 canvas
I'm a beginner in WebGPU and want to process an image with multiple processing stages in separate shader modules:
Desaturation
Edge detection
Compression
Step 4 then computes the compressed texture ...
1
vote
0
answers
25
views
How to Reduce Pixelation in Texture Mapping for Raycasting Engine in C
I am working on a raycasting engine in C, similar to the one used in classic games like Wolfenstein 3D. I have implemented basic texture mapping, but the rendered walls appear very pixelated. I would ...
-1
votes
0
answers
21
views
Create a layered ggplot with 2 different scale x axis? [duplicate]
I'm a litte stuck, I wanna create a plot showing 2 variables based on time, however one of those variable needs to be shown on a log scale (going from 0.01 to 100), and the other one on a regular ...
-1
votes
1
answer
39
views
GLSL bouncing ball issue
#ifdef GL_ES
precision mediump float;
#endif
uniform vec2 u_resolution;
uniform vec2 u_mouse;
uniform float u_time;
vec3 color_bg = vec3(1.0);
vec3 circle_color = vec3(0.0, 0.0, 0.0);
void circle(...
0
votes
1
answer
64
views
How to Pass Previous Frame as Sampler2D to Fragment Shader in Vulkan?
I am currently developing a Vulkan project and I am facing an issue that I cannot resolve.
I need to pass the image of the previous frame as a sampler2D to the fragment shader. I have followed the ...
0
votes
0
answers
24
views
How to project shape into correct positiong C++ SFML
I'm trying to make a simple shape projection into my screen but I can't get the correct position for the rectangle shape. I want to make it so that my world width and height bounded by [-1, 1]. For ...
-3
votes
0
answers
78
views
Why is the sign different only for y-axis rotation? [closed]
Why is the sign entered into the rotation matrix for only y-axis rotation different? Since the direction of rotation for only y-axis rotation is different in Direct, is it correct to multiply the ...
1
vote
1
answer
47
views
Visualization of graphs according to the size of the data
I am making some graphs using different datasets, but when I change the data the graph loses its shape and does not look good. I don't know if there is a way to write something in the code to make the ...
0
votes
0
answers
23
views
How to calculate shadow far plane for sphere light?
I've got point-light shadows implemented.
I get the projection matrix like this:
struct PointLight
{
glm::vec4 colorIntensity;
glm::vec3 position;
float radius;
};
glm::mat4 ...