Questions tagged [dda]

A Digital Differential Analyzer is an interpolation algorithm for line-drawing

See http://en.wikipedia.org/wiki/Digital_differential_analyzer and http://en.wikipedia.org/wiki/Digital_Differential_Analyzer_(graphics_algorithm)

30 questions
5
votes
1 answer

what is meant by symmetric DDA?

I have read about DDA. But I just came across the term symmetric DDA. What is it ? How is it different from DDA ?
Y.E.P
  • 1,187
  • 6
  • 20
  • 40
4
votes
2 answers

Precision problems in raycasting algorithm

I am programming a raycasting engine. The starting position of a ray is given by the position of the player who is standing inside a 2D-grid. When casting a ray into a direction, I have to determine the grids that the ray is intersecting. (The…
Marius Anderie
  • 23
  • 1
  • 2
  • 12
4
votes
1 answer

Digital Diferential Analizer Dotted Line

Im using de DDA (Digital Diferential Analizer) to make a line, and thought I know maybe using de DrawLine the way I am, just run along with it. Im trying to make different types of lines like dashed or dotted, etc. Im thinking in makeing the for…
Jurgen Feuchter
  • 544
  • 1
  • 7
  • 29
4
votes
2 answers

Confused in DDA algorithm , need some help

I need help regarding DDA algorithm , i'm confused by the tutorial which i found online on DDA Algo , here is the link to that tutorial…
M3taSpl0it
  • 2,967
  • 6
  • 28
  • 27
4
votes
0 answers

Curve rasterization to pixels

I need algorithm for rasterize a curve in to pixels example http://i54.tinypic.com/ffc0n9.png I tried apply DDA line algorithm for control points, but I didn't give good result. Also I try enlarge curve (for example in 3 times), and then…
studyman
  • 41
  • 4
3
votes
1 answer

What's the basic difference between the following two implementations?

I was trying to use opengl using c. The code which I wrote leaves gaps within the lines i.e. draws dotted lined whereas the one which I found on the net draws perfectly. I don't get that, if there is no difference in the code which I wrote and the…
user8704383
3
votes
2 answers

Digital Differential Analyzer with Wu's Algorithm in OpenGL

I'm trying to make an algorithm which draws lines, using the DDA (Digital Differential Analyzer), that also use the Wu's algorithm as anti-aliasing. The problem is that the output doesn't look quite good. In particular: the color that i choose, it…
giogix
  • 769
  • 1
  • 12
  • 32
3
votes
1 answer

Draw line between two points on console

How can I draw a line on the console if I have a 2D array of chars. The function I want to write is something like: This is my first attempt, but it looks totally wrong public static void line(char[][] mPixels, int startRow, int startColumn, int…
user445338
2
votes
0 answers

DDA Algorithm and Bresenham Algorithm

I have been studying DDA and Bresenham algorithms for line drawing and am curious about one thing.In both the algorithms,we consider a pixel grid to be of unit size and perform further steps.My question is if I change my grid size to say 0.5*0.5…
2
votes
3 answers

The DDA Algorithm is not drawaing straight lines for all coordinate values

My code for implementation of DDA (Digital Differential Analyzer) algorithm is working good for drawing lines with slope less than 45o but fails in lines slope more than 45o. It is behaving like a broken line for angles > 45o Code void dda(int…
user2447277
1
vote
0 answers

Can someone help me fix my DDA collision algorithm in processing?

I have been trying to make a DDA algorithm for a raycaster for a while now. For some reason I'm having a ton of trouble. The way my code works is that it puts a player into the map that spins at a constant rate. the green circle should be landing…
1
vote
1 answer

Add Custom cursor on ID3D11Texture2D texture

I am completely new to DirectX. But I am using it into my screen capture application. I am capturing the screen using desktop duplication API. Now I want to update the cursor information, instead of the original cursor I want to give custom cursor…
1
vote
1 answer

High CPU usage, with different timeouts interval, between frames acquiring in Desktop Duplication API

I'm trying to capture the screen with 16ms of the timeout, and i'm getting 60-65 FPS when the capture is tested on full screen 4k 60fps video. CPU usage, in this case, is approximately 0-1%. But when the mouse cursor is moving on the screen, the FPS…
KKomrade
  • 95
  • 4
1
vote
1 answer

No output for simple openGL line drawing program?

I am unable to understand why I am not getting any output for the given program. This problem has been occurring to me for my last 2 openGL programs, the previous one being DDA algorithm, again in which I didnt get any output. Is there a problem…
Dhruv Chadha
  • 1,161
  • 2
  • 11
  • 33
1
vote
0 answers

draw a line with open gl mouse function using dda/bresenham algorithm

So i have to draw a line using mouse function. When the mouse clicks two points, the program needs to draw a line connecting them. I need to make an imaginary 10x10 array and map the points on it and then connect the dots. window size doesn't…
joonor23
  • 25
  • 7
1
2