POV-Ray : Newsgroups : povray.general : object oriented features : Re: object oriented features Server Time
28 Jul 2024 14:30:59 EDT (-0400)
  Re: object oriented features  
From: Thorsten Froehlich
Date: 19 Aug 2000 05:32:25
Message: <399e5429@news.povray.org>
In article <399DAE0A.2AC32A30@vrml.k12.la.us> , Abe Heckenbach 
<abe### [at] vrmlk12laus>  wrote:

> huh?? I don't know what you mean by that. if you provide a platform
> independent method called trace_scene(POVScene,POVCamera), any other
> c/c++ program can call it and do what every it wants with it(likely
> platform specific like some kind of gui.)

No, it is not.  Different platforms have different methods of making
functions available to outside programs.  This usually requires changing the
source code in some way.  One simple change might be that all the compiler
requires is an compiler specific option to export, i.e. something line
"#export on".  But it might also require some special conventions to
overcome the way how different compilers manage function calls, i.e. the
'popular'  "CDECL" declaration of functions...

To make it short, neither the C nor the C++ standard says anything about
making functions available to outside programs.  In consequence, there is no
standard way to make extern function calls cross-platform easily. *


     Thorsten


* Yes, there are some frameworks that try to overcome this, but this is not
the point here - they are not available anywhere (unlike a good C compiler)!

____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: tho### [at] trfde

Visit POV-Ray on the web: http://mac.povray.org


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.