|
![](/i/fill.gif) |
Still needs a C++ compiler, not everyone has one... When using
POV, everyone has POV. When using POV, not everyone has
C++. That was the point I would put most emphasize on.
You're right though.
Apache wrote:
> All my C/C++ code is ANSI, so it compiles on all platforms without too much
> tweaking.
>
> --
> Apache
> POV-Ray Cloth experiments: http://geitenkaas.dns2go.com/experiments/
> Email: apa### [at] yahoo com
> ICQ: 146690431
--
Tim Nikias
Homepage: http://www.digitaltwilight.de/no_lights/index.html
Email: Tim### [at] gmx de
Post a reply to this message
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
Apache <apa### [at] yahoo com> wrote:
> All my C/C++ code is ANSI, so it compiles on all platforms without too much
> tweaking.
C/C++ code conforming to the ANSI standard doesn't necessarily mean
that it will work in all platforms (or even in more than one specific
platform).
For example there's nothing against the standard in the following code:
void PutPixel(int x, int y, unsigned char color)
{
unsigned char* screen = (unsigned char*)0xA0000;
screen[x+y*320] = color;
}
However, in most systems it will just cause a segmentation fault, and even
if it doesn't, it certainly will not work as expected.
Also some things cause surprises among the unaware coders:
char table[10];
int* ptr = (int*)(&table[1]);
*ptr = 5;
This works ok in some systems (eg. Intel) but in most RISC processors it
causes a bus error (ie. the program crashes).
Conforming to the standard is not enough to make portable code.
--
#macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N color_map{[0rgb x]
[1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end M(-3<1.206434.28623>70,7)M(
-1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// - Warp -
Post a reply to this message
|
![](/i/fill.gif) |