Re: problem with output of the program on different OS
- From: pereges <Broli00@xxxxxxxxx>
- Date: Mon, 12 May 2008 10:27:24 -0700 (PDT)
On May 12, 8:06 pm, Bart <b...@xxxxxxxxxx> wrote:
I had a further look at Pelles C version (now that I can run it from
the command line, I can make progress..)
With 3 compilers, ray 463 hits only triangle 654 of the 1200
triangles.
With Pelles C, ray 463 hits triangles 654 and 745, at equal distances.
I just added a raycount member to ray data structure and kept track of
rays hitting triangles. I got some what different results. ray 463 is
hitting triangle 943 at distance 1006.67112
a ray hitting two triangles at same distance is nothing but ray
hitting the edge shared by two triangles or the vertex.
Varying your EPSILON made no difference.
Well I varied EPSILON and there was a little difference in output but
still no where near the results obtained with other compilers.
So it starts to look more like some strange numeric problem; perhaps
Pelles C does some calculations a little differently, or perhaps
something more serious; this requires more investigation by someone
with a lot more time!
It could still be a bug in /your/ calculations which may depend too
heavily on some very small value which is treated differently between
different C systems.
maybe you are right but isn't it strange that PellesC is the only
compiler giving a result like this. If there was a serious bug in the
program, then there would have been atleast one compiler which could
have given strange result ?
BTW this is a hell of a complicated program; I wouldn't have used C
for this. Not until it was 100% working with some reference results
anyway. (I(/we?) still don't know what the right output is supposed to
be. Makes testing a little difficult!)
What other languages in your opinion could have been used ? I was told
C because speed was important to my application.
.
- Follow-Ups:
- References:
- problem with output of the program on different OS
- From: pereges
- Re: problem with output of the program on different OS
- From: Bart
- Re: problem with output of the program on different OS
- From: pereges
- Re: problem with output of the program on different OS
- From: Bart
- Re: problem with output of the program on different OS
- From: pereges
- Re: problem with output of the program on different OS
- From: Bart
- Re: problem with output of the program on different OS
- From: pereges
- Re: problem with output of the program on different OS
- From: Bart
- Re: problem with output of the program on different OS
- From: pereges
- Re: problem with output of the program on different OS
- From: Bart
- Re: problem with output of the program on different OS
- From: pereges
- Re: problem with output of the program on different OS
- From: Bart
- problem with output of the program on different OS
- Prev by Date: Re: C standard question?
- Next by Date: Re: Introduce a C Compiler ucc
- Previous by thread: Re: problem with output of the program on different OS
- Next by thread: Re: problem with output of the program on different OS
- Index(es):
Relevant Pages
|
Loading