i would need a function for drawing (rasterizing) a 2d line on the screen
it should work for iint 32 range values for start_x, start_y and end_x, end_y
(I mean it should ewen get a values like DrawLine( -1000000, 1000000, 300, 200, 0xffffff) ;) but should be clipped to the screen rectangle (of the width and height like 800x600)
A bit trouble was when I clipped the line to the screen rectangle and draw it with the bressenham, It showed to be a bit incorrect becouse of fact that
incoming screen edge bressenham starting points were realy like (102.3 , 0) - (95.7, 0) and casting it to (102, 0) - (96, 0) for bressenham usage wassomewhat inexact
besides that i do not know how the clipping routine should look like to be efficient
In general this leads to some thing at all -
when it seem that i couls consider DrawLine routine to be
taking only integer values (this is probably how bressenham
works, it treats 0,0 as top left pixel, It shows that this "integer"
approach is to narrow - and for example when doing clipping
it is a need to some routine that is able to be working on
fractional starting points coordinates (though besides i would like to work on integer) how to do that is bressenham capable to work on fractional starting and ending points points
DrawBressenhamLine(12.5, 7.3, 128.9, 411.8) ?