Click here to Skip to main content
15,891,136 members
Home / Discussions / Algorithms
   

Algorithms

 
GeneralRe: Steganography algorithms?? Pin
Luc Pattyn9-Jul-07 3:01
sitebuilderLuc Pattyn9-Jul-07 3:01 
AnswerRe: Steganography algorithms?? Pin
Vasudevan Deepak Kumar17-Jul-07 6:45
Vasudevan Deepak Kumar17-Jul-07 6:45 
Questionlinear algebra library Pin
ovoundaga8-Jul-07 2:03
ovoundaga8-Jul-07 2:03 
AnswerRe: linear algebra library Pin
Stephen Hewitt8-Jul-07 15:03
Stephen Hewitt8-Jul-07 15:03 
GeneralRe: I think this shouldn't be here... Pin
p_v_chaitanya2-Jul-07 1:51
p_v_chaitanya2-Jul-07 1:51 
AnswerI think this shouldn't be here... Pin
CPallini2-Jul-07 1:47
mveCPallini2-Jul-07 1:47 
QuestionQuick Hit-Testing Pin
Ri Qen-Sin19-Jun-07 3:43
Ri Qen-Sin19-Jun-07 3:43 
AnswerRe: Quick Hit-Testing Pin
Luc Pattyn19-Jun-07 4:30
sitebuilderLuc Pattyn19-Jun-07 4:30 
Hi,

lots can be done depending on circumstances.

SCHEME 1

Assuming you are only interested in a finite and rectangular part of the 2D plane,
you could divide the area in a number of smaller rectangles. Say 16*16 rectangles.

Now a ray would intersect only some of these rectangles, so we are only
interested in those circles that partially cover those rectangles.
Assuming your circles are static, that can be precalculated and stored: for
each record, you can hold a list of crossing circles.

So now it is a matter of finding the rectangles crossed, then scanning the circles
listed for these rectangles.

WARNING: things must be organized in such a way that the same circle is not
tested again for different rectangles; a boolean flag might help.

SCHEME 2

Assuming (most of) the circles are fairly small with respect to the entire area,
if the ray does not cross the entire area, but is restricted to some X-range
(for a steep ray) or some Y-range, one could easily eliminate all circles that
lie fully outside said X or Y-range.


Hope this helps.


GeneralRe: Quick Hit-Testing Pin
Ri Qen-Sin19-Jun-07 6:09
Ri Qen-Sin19-Jun-07 6:09 
GeneralRe: Quick Hit-Testing Pin
Luc Pattyn19-Jun-07 6:53
sitebuilderLuc Pattyn19-Jun-07 6:53 
GeneralRe: Quick Hit-Testing Pin
Ri Qen-Sin19-Jun-07 13:30
Ri Qen-Sin19-Jun-07 13:30 
GeneralRe: Quick Hit-Testing Pin
cp987619-Jun-07 18:39
cp987619-Jun-07 18:39 
GeneralRe: Quick Hit-Testing Pin
Luc Pattyn20-Jun-07 1:45
sitebuilderLuc Pattyn20-Jun-07 1:45 
GeneralRe: Quick Hit-Testing Pin
Ri Qen-Sin20-Jun-07 2:59
Ri Qen-Sin20-Jun-07 2:59 
GeneralRe: Quick Hit-Testing Pin
Luc Pattyn20-Jun-07 3:56
sitebuilderLuc Pattyn20-Jun-07 3:56 
GeneralRe: Quick Hit-Testing Pin
Ri Qen-Sin20-Jun-07 14:25
Ri Qen-Sin20-Jun-07 14:25 
GeneralRe: Quick Hit-Testing Pin
Ri Qen-Sin20-Jun-07 2:50
Ri Qen-Sin20-Jun-07 2:50 
AnswerRe: Quick Hit-Testing Pin
Stephen Hewitt20-Jun-07 14:13
Stephen Hewitt20-Jun-07 14:13 
GeneralRe: Quick Hit-Testing Pin
cp987620-Jun-07 17:09
cp987620-Jun-07 17:09 
GeneralRe: Quick Hit-Testing Pin
Stephen Hewitt21-Jun-07 16:30
Stephen Hewitt21-Jun-07 16:30 
GeneralRe: Quick Hit-Testing Pin
cp987623-Jun-07 18:34
cp987623-Jun-07 18:34 
AnswerRe: Quick Hit-Testing Pin
Roy Heil2-Jul-07 3:43
professionalRoy Heil2-Jul-07 3:43 
GeneralRe: Quick Hit-Testing: The "Look and See" Method Pin
Luc Pattyn22-Jun-07 7:00
sitebuilderLuc Pattyn22-Jun-07 7:00 
Questionrunge Kutta Pin
Noharyiasa18-Jun-07 23:46
Noharyiasa18-Jun-07 23:46 
AnswerRe: runge Kutta Pin
Luc Pattyn19-Jun-07 0:11
sitebuilderLuc Pattyn19-Jun-07 0:11 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.