Skip to main content

Questions tagged [algorithm]

Questions about the rigorous usage of instructions used to solve a specific computer graphics problem.

Filter by
Sorted by
Tagged with
2 votes
0 answers
87 views

I have written dithering software, and previously asked a question about that. Now I want to pick palette colours automatically, to make dithering easier for users. The way I've found for doing this ...
makeworld's user avatar
  • 163
0 votes
0 answers
44 views

In bresenham's line drawing algorithm, we assume that xk,yk is the first pixel to be plotted and then proceed to determine the next pixels. Whether it will be (xk+1,yk) or (xk+1,yk+1). (I suspect my ...
Ghungroo's user avatar
2 votes
1 answer
90 views

I'm trying to create an algorithmic, deterministic, static image generator based on magic the gathering. Essentially, I want to provide the generator with a seed id and colours to then have it output ...
Felix ZY's user avatar
  • 123
0 votes
1 answer
94 views

In the Wikipedia article about flood fill, there is a section describing a walk-based (fixed memory) method. The approach is based on making a decision depending on the number of already filled ...
Leo B.'s user avatar
  • 141
1 vote
0 answers
48 views

Assume you have a triangle set such that there is a sub-simplicial complex of your mesh (a sub mesh) that is manifold. Is there an algorithm that can compute the maximal manifold submesh of the input ...
Makogan's user avatar
  • 1,891
3 votes
1 answer
120 views

I want to triangulate a bounded 2D area in order to interpolate the colors, but unfortunately I'm not a clever mathematician, so I could need some clever idea. Let's have a look at this sample: The ...
U. Windl's user avatar
  • 145
1 vote
2 answers
214 views

For regression tests of our note typesetting program, LilyPond, we currently use ImageGraphick's compare program with the MAE metric (mean absolute error, average ...
lemzwerg's user avatar
  • 111
0 votes
0 answers
42 views

I have a set of non-intersecting packed tetrahedrons in 3D space. What is the most optimized way to find the tetrahedron inside which a query point lies? Edit: I tried some data structures and ...
Prakhar's user avatar
  • 11
1 vote
0 answers
70 views

Is there a method to find the shortest segment between 2 Signed distance field? I know how to calculate this segment for a limited number of SDF like from sphere to sphere, from capsule to sphere, ...
Kuwazy's user avatar
  • 11
1 vote
0 answers
100 views

I would like to programatically identify pitch and roll numbers that will level the horizon on each frame in a series of equirectangular 360 panorama images. Here's why. I recently ended up with a ...
amh15's user avatar
  • 111
1 vote
0 answers
52 views

I am quite new to meshing and mesh manipulation. I am working on a problem consiting of meshes $A$, $B$, and $C$. The mesh $C$ completely encloses the meshes $A$ and $B$ as shown in the attached ...
Prakhar's user avatar
  • 11
1 vote
1 answer
115 views

I am trying to write an L-System to generate the Penrose P3 tiling (with thin and thick rhombi, I will call them Rhombus-A and Rhombus-B. For render, I am planning to use the following chars. '+' ...
Ouss's user avatar
  • 111
1 vote
1 answer
254 views

Motivation I am trying to refine a mesh such that each triangle gets subdivided into 4 triangles, but I want the vertices to be shared. For that purpose I need a half-edge data structure so I can ...
lightxbulb's user avatar
  • 2,711
1 vote
1 answer
260 views

Say you have 2 parametric cylinders represented as triangle meshes with very different geometries and you connect them together. Is there a method that allows you to join them together such that the ...
Makogan's user avatar
  • 1,891
1 vote
0 answers
107 views

Kobbelt et al. published a paper some 20 years ago where they specified how solving Poisson equations on the positions of a mesh lead to removing noise. This can be used for reconstructing mesh ...
Makogan's user avatar
  • 1,891
2 votes
1 answer
92 views

I was reading this question regarding half edges from 3 years ago and the selected answer seemed pretty smart to me. However, while actually implementing it I'm confused at the part where I have to ...
ThisAccountIsForGameDev's user avatar
0 votes
0 answers
197 views

I am analyzing a large amount of Layers 0-4 Network Data. I am trying to render diagrams dynamically showing the Network Devices involved in the data (Desktop, Switch, Router, Server, etc.) and how ...
Liam Kelly's user avatar
0 votes
1 answer
159 views

I have searched through a lot of libraries and sources, that include very diverse intersection algorithms, for computer graphics. And I've never found a capsule-box intersection algorithm. Despite ...
Lenny White's user avatar
0 votes
2 answers
343 views

I have a vertex shader happily producing all the vertices I want for a 2D plot. Now I want to also render a plot of the same data, but each point relative to the previous one, like SVG Paths using <...
Nick's user avatar
  • 11
1 vote
1 answer
83 views

Looking at the output of the angle of this double pendulum made me think this was a good candidate for generating realistic looking terrain profiles. I can't be the first to notice this so I was ...
AJP's user avatar
  • 83
4 votes
2 answers
2k views

I've been trying to wrap my head around this algorithm, and I need it for my drawing function. But I can't seem to understand it. The Wikipedia page gives this piece of code right at the end: ...
sneaker's user avatar
  • 41
4 votes
1 answer
670 views

I maintain an image dithering library and command line tool. When I was initially developing the library, I was trying to figure out how to match dithered RGB values (containing quantization error or ...
makeworld's user avatar
  • 163
4 votes
1 answer
499 views

I'm trying to figure out a solution to a problem that looked simple at first: how to render overlapping windows in a 2D windowing system. Originally I was thinking about implementing a text-based UI ...
LittlePilgrim's user avatar
1 vote
0 answers
166 views

In specular reflection result depends on view vector from camera to point. Because of that, when doing temporal reprojection and reprojecting position of current fragment while camera is translating, ...
mdkdy's user avatar
  • 2,199
1 vote
1 answer
209 views

I need to accurately plot a line chart using WebGL. The numbers have a precision of around 33 bits - that's too many to fit into a single-precision float's mantissa. WebGL does not support the double-...
purefanatic's user avatar
4 votes
1 answer
3k views

Given 3D mesh with a closed surface. (solid object without hole). I'm looking for an algorithm to calculate its volume. There are several ideas, Such as Voxelized and count voxels Point cloud and ...
kitta's user avatar
  • 143
1 vote
0 answers
209 views

I'm trying to figure out how to go about removing the "colorization" of comic/cartoon/manga/etc drawn-art inputs where the black-ink strokes ("the line-art") are to be retained ...
Phil S.'s user avatar
  • 11
1 vote
0 answers
76 views

I read the pixels of PNG files via libpng and creates an array of alpha channels (showing visible pixels for a monochromatic image). int pixels[height][width]; <...
Googlebot's user avatar
  • 131
1 vote
0 answers
194 views

I just posted this to SO but the question got closed, so I hope it's OK if I try it again here. They say "we don’t allow questions seeking recommendations for books, tools, software libraries&...
fweth's user avatar
  • 127
1 vote
1 answer
251 views

In recent years, the technology of Live2D has become particularly popular and I have been attempting to find any papers or articles which explain what the mathematics for the mesh-based image morphing ...
MadCreativity's user avatar
2 votes
1 answer
746 views

I'm attempting to use the jump flood algorithm to compute distance transforms of an arbitrary texture derived from a canvas2d context, roughly following the explanations detailed here/here. In the ...
Nico's user avatar
  • 23
1 vote
1 answer
108 views

In pbrt v3, the book gives this description of beam transmittance, but I don't know how to solve the differential equation like it says to get Tr , can someone please tell me how to solve the ...
Wenjian Zhou's user avatar
0 votes
0 answers
91 views

Suppose we want to convert an RGB image into a paletted image. As an example, we may have a 1024x1024 image, and we want to map it onto 512 unique colors. All the colors are RGB. This is a problem of ...
Water's user avatar
  • 101
2 votes
1 answer
191 views

I wish to determine the path taken by a light ray between two points, $a$ and $b$, through an anisotropic medium. More specifically, this medium has an index of refraction which varies as an ...
10GeV's user avatar
  • 123
1 vote
1 answer
177 views

I am new to CG and I need to draw a wall clock using bresenhams circle algo . I have drawn a circle using this algo but how do I add minute and hour needle in it basically how do i add lines inside a ...
Nubcodes's user avatar
0 votes
0 answers
79 views

I am using Fournier's midpoint algorithm (recursive subdivision) to construct a landscape of 1025 x 1025 gridpoints, then I am using an advanced version of box counting to find fractal dimension, D. ...
user993563's user avatar
4 votes
3 answers
16k views

I am trying to use constructive solid geometry (CSG) and boolean operators to combine various shapes and get the outer (possibly concave) hull. This seems to work okay when using primitive shapes like ...
Sirius 5's user avatar
1 vote
1 answer
321 views

I hope this is the right forum to ask this question. I want to experiment with procedurally generating some buildings, and as a first step I want to generate a 2D shape to use as a foundation for the ...
munHunger's user avatar
  • 113
4 votes
2 answers
383 views

I implemented the curved PN triangles algorithm described in this paper to smooth geometry in real time. After the implementation was finished (in glsl) I realized, that this algorithm smooth the ...
Thomas's user avatar
  • 1,503
3 votes
0 answers
64 views

While I'll try my best to give all relevant info in all possible brevity below, please refer to the spoiler and link at the bottom of the post for the (more lengthy) original description if needed. ...
Herbert Jensch's user avatar
2 votes
0 answers
76 views

Background I need to remesh by OpenVDB, like what Blender remesh does: Voxel Uses an OpenVDB to generate a new manifold mesh from the current geometry while trying to preserve the mesh’s original ...
Megidd's user avatar
  • 133
6 votes
1 answer
180 views

I am working with a PWP3D-like algorithm that renders silhouettes of a mesh in order to segment a frame of video and update an object's pose. Because it is only the silhouettes of the mesh that matter,...
FilmCoder's user avatar
  • 101
0 votes
0 answers
110 views

I'm implementing some mesh operations (e.g. edge collapse, edge split, edge flip etc) and need to ensure applying such operations does not cause the mesh to become non-manifold. However, I'm not sure ...
Amir's user avatar
  • 241
0 votes
1 answer
71 views

I have a 2D layer/section containing the 2D polygons colored in shades of green. I have another layer containing the 2D polygons colored in shades of blue. I intend to figure out how different are ...
Megidd's user avatar
  • 133
0 votes
1 answer
510 views

I am rotating a bitmap using the three shear algorithm documented in these articles [1][2]. From about 0-90°, the quality is acceptable, but beyond that it gets progressively more distorted until it's ...
Dr. Pontchartrain's user avatar
1 vote
1 answer
2k views

I would like to rotate an bitmap image using math. I have two issues with my current implementation: the pixel-by-pixel rotation of the copied bitmap is extremely slow and it is leaving gaps between ...
Dr. Pontchartrain's user avatar
1 vote
1 answer
118 views

Subdivision schemes work by considering the vertices and their connectivity information to calculate averaging weights. However, other than specifying which vertices are connected, and perhaps which ...
Makogan's user avatar
  • 1,891
1 vote
1 answer
142 views

I have a mesh made up of several tetrahedrons, I know for sure that there are intersections between some of them: how can I remove these intersections, without generating others? In other terms: if ...
Davide's user avatar
  • 11
0 votes
2 answers
167 views

Following the instructions from this post on Stack Overflow, I have been able to find points A, B, and C from points V1, V2, and V3 and a radius value (code below). I would like to be able to find a ...
Dr. Pontchartrain's user avatar
3 votes
1 answer
2k views

I'm trying to implement something like an "inner glow". That is, I have an image which defines the shape of an object, and then I want to create overlay that is a gradient that goes from the ...
Steinbitglis's user avatar