POV-Ray : Newsgroups : povray.off-topic : Mildly interesting article : Re: Mildly interesting article Server Time
11 Oct 2024 13:15:44 EDT (-0400)
  Re: Mildly interesting article  
From: Darren New
Date: 11 Nov 2007 20:47:27
Message: <4737b0af$1@news.povray.org>
Warp wrote:
> Darren New <dne### [at] sanrrcom> wrote:
>> You do realize that this isn't in any way unique to C++, yes? :-)  I 
>> mean, without even writing two versions of the library?
> 
>   Yet C++ is used to make games and those other languages aren't. 

Sure they are. Not as many, perhaps, but there are lots of games that 
aren't written in C++, including some significant parts of the big 
MMORPGs.  I'm just pointing out that there are bunches of languages with 
run-time checking that you can turn off in a release build. And there 
have been, since before C was particularly popular, back when 8-bit 
Pascal was the language of choice.  :-)

>   (Perhaps one advantage of C++ is that there are millions of libraries
> out there written in C, and they can usually be used in C++ as they are,
> without any modifications. Few other languages can do that.)

That's one reason, for sure.  It's easier for C++ to interface to native 
C than pretty much any other language I've seen. Beyond that, C# and Ada 
are about the closest I've seen to interfacing trivially with native 
libraries that have complex interfaces, like passing around structures 
full of pointers and such.  Of course, if your gaming engine is in C++, 
it's pretty hard to interface to it from any other language.

Plus, gaming is somewhat of a niche - the performance right now of 
FPS-style games really needs down-to-the-metal type coding, I would 
think. Machines aren't nearly capable of modeling everything people want 
them to model for that style game.

On the third hand, I expect there's whole rafts of scientific, 
engineering, and business applications that demand high performance but 
which don't use C++.  Stuff like avionics hardware, running the NASDAQ 
exchange, or modeling quantum physics.  AFAIK, C++ isn't the language of 
choice for those sorts of things.

-- 
   Darren New / San Diego, CA, USA (PST)
     Remember the good old days, when we
     used to complain about cryptography
     being export-restricted?


Post a reply to this message

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