Questions tagged [computer-graphics]

19 questions
3
votes
0 answers

What is the etymology of "swizzle"?

The word swizzle can refer to an operation performed in GPU algorithms: [The] ability to compose vectors by arbitrarily rearranging and combining components of other vectors. Swizzle (computer graphics) - Wikipedia I've found another reference to…
3
votes
0 answers

What is the historical origin of the concept of a "clipping path"

Algorithms for clipping lines to a rectangle seem to have been invented by Ivan Sutherland in the late 60s. At some point the rectangle was generalized to an arbitrary polygonal area, and these days can be any path (including bezier curves, etc.) It…
Theo H
  • 341
  • 1
  • 5
3
votes
1 answer

Determining the intersections of a line segment and grid

Problem: Given a line segment on the cartesian plane, determine where and which order it intersects a regular grid. This sounds simple, but is actually quite a tough problem. It's related to, but distinct from, both Bresenham and supercover. More…
2
votes
1 answer

Find a minimal (irregular) boundary over a grid of colored cells

A grid is divided up into red cells (pixels), black cells, and white cells. We want to find the smallest boundary that: All red cells are within the boundary All cells of the boundary itself are white The boundary can be irregular, but it must be…
2
votes
1 answer

Bresenham's line drawing algorithm guarantees

I am considering implementing my own version of Bresenham's line drawing algorithm, found here, my one question is does the algorithm guarantee that both endpoints will be covered/drawn. I am doubting this because of the error accumulation factor…
yosmo78
  • 187
  • 5
2
votes
2 answers

How is CPU different from GPU?

A central processing unit offers to handle various operations like calculating, watching movies, making presentation etc. While a graphics processing unit is majorly used for the purpose of video rendering or playing of high-quality graphical…
1
vote
1 answer

Why are polygon meshes explicit representations of a model when you're not explicitly storing most of the points?

For a computer graphics class. Maybe I'm fundamentally misunderstanding something, but AFAIK the difference between implicit/explicit representations for modelling is just implicit uses equations and explicit just stores the points. So, how is a…
Donut
  • 11
  • 3
1
vote
0 answers

What algorithm can expand find the irregular boundary around a drawing on a printed page?

I'm processing scans of printed pages. The books have drawings, photographs, print (which includes characters but also things like lines and boxes around them), and background (the white page). My goal is to extract each individual drawing from…
1
vote
2 answers

Halftone Circle Pattern Algorithm Implementation

The problem is implementation of specific halftone circle pattern algorithm, which should generate a bitmap image composed of black and white circles reflecting the halftones of the original image. When viewed from a distance, the image should…
1
vote
1 answer

How is slope error calculated for Bresenham’s Algorithm for both 2D and 3D?

I've been working with Bresenham’s Algorithm in 2D and understand it is derived from the following logic: y = mx+c To get the slope error at a given point, the following equation is used: d2 is the distance from value Y to the whole integer…
M. Nicol
  • 13
  • 3
1
vote
0 answers

What's the mathematics behind the technique of "keeping a square a square" in chapter 2 of "OpenGL superbible" 4th Edition?

In "OpenGL superbible" 4th Edition by RICHARD S.WRIGHT JR page 60, there's this piece of code that confuses me: // Reset coordinate system glMatrixMode(GL_PROJECTION); glLoadIdentity() aspectRatio = (GLfloat)w /…
1
vote
1 answer

Video compression algorithm

I am working on a project for my CS subject and the topic is Video compression. After theoretical aspect, I want to implement and describe one algorithm that does video compression. I am not sure if these type of questions are allowed here but: what…
Exzone
  • 235
  • 2
  • 11
1
vote
0 answers

What is the difference between DeepFake and First Order Motion?

What is the difference between DeepFake and First Order Motion? Is it the same or not?
Nixon
  • 11
  • 1
0
votes
1 answer

What is this question actually asking for me to solve?

(15 marks) Suppose a ray comes from a point (2, 8) and hits at mirror point (6, 6). Assume that perpendicular vector a point (6, 6) is ̅= (0, 3). Find the reflection emitting point from (6, 6). [Assume 2-D coordinate system, you must draw the…
Kaleb
  • 1
  • 1
0
votes
0 answers

Why are point clouds useful for large datasets of geometries?

In my computer graphics course I came across this "pro" for point clouds: Useful for large datasets (>> 1 point / pixel) I'm trying to wrap my head about it, I know drawing is expensive, but, it somehow counterintutive to me that for larger…
1
2