0
votes
1answer
35 views

Bounds Queries for Simplex Noise Function

How do I construct a Bounds Query for 3D Simplex Noise? [This is more or less a follow-up to my last question] Simply put, for an arbitrary octree node (cube) in my volume (a section of Unity3d ...
1
vote
1answer
38 views

Draw a rotated rectfill in Allegro 4.2?

I'd like to use Matricies to transform primitive geometric shapes and draw them using the Allegro library using version 4.2 (I can not switch to 5.x just yet). This works fine for non-filled objects ...
3
votes
1answer
88 views

Symmetry preserving path simplification

I'm using the Douglas peucker (DP) algorithm to simplify some (2d) closed paths forming a shape. This works pretty good, but not so much for closed paths that have some symmetry. Take for example a ...
0
votes
1answer
178 views

Algorithm to generate multifaced cube?

Are there any elegant soloution to generate a simple-six sided cube, where each cube is made out of more than one face? The method I have used ended up a horrible and complicated mess of logic that is ...
1
vote
3answers
910 views

How do you blend multiple colors in HSV (polar) color-space?

In RGB color space, you can do a weighted multiple-color blend by just doing: Start with R = G = B = 0. Then we perform a blend at index i using a set of colors C, and a set of normalized weights w ...
15
votes
5answers
3k views

Quick 2D sight area calculation algorithm?

I have a matrix of tiles, on some of that tiles there are objects. I want to calculate which tiles are visible to player, and which are not, and I need to do it quite efficiently (so it would compute ...
2
votes
2answers
268 views

How can I animate a recursive algorithm?

Say I have a recursive algorithm, for example one that generates a random tree: // Pseudocode, just a simple algorithm: it isn't perfect. function generate_branch(angle, length, current_depth, ...
6
votes
3answers
1k views

top down game - checking, drawing enemy's line of sight area with obstacles

Examples of what i'm going to need: I'm using cocos2d to draw a CCTMXTiledMap, on those tiles i'll have to draw the LOS cone. How would i test if the player is within that cone, taking obstacles ...
4
votes
2answers
2k views

Bitmap font rendering, UV generation and vertex placement [closed]

I am generating a bitmap, however, I am not sure on how to render the UV's and placement. I had a thread like this once before, but it was too loosely worded as to what I was looking to do. What I am ...
14
votes
5answers
4k views

boolean operations on meshes

given a set of vertices and triangles for each mesh. Does anyone know of an algorithm, or a place to start looking( I tried google first but haven't found a good place to get started) to perform ...
5
votes
6answers
2k views

Algorithm for drawing asteroids from, er… Asteroids game?

What would the algorithm be for generating/drawing the asteroid shapes from the original Asteroids game? Is it even an algorithm? Or would they be hard coded shapes? Here is a screenshot to jog your ...