Alternative languages, these days.
- ahmedali
- Gnome
- Posts: 302
- Joined: Fri Feb 20, 2004 8:52 pm
- Location: Lahore, Pakistan
Alternative languages, these days.
I was looking for not so well known languages and atleast having the possiblity to access essential libraries for 3d game development. From a game programmer's POV some of these languages may seem practical other may help a programmer to improve his designing & problem solving skills.
Embeddable scripting Language:
Besides lua, python, squirrel, pawn/small, angelscript & other well knowns...
io scripting language: (based on Smalltalk, Self, Lua, Lisp, Act1, NewtonScript)
http://en.wikipedia.org/wiki/Io_programming_language
To me it seems a very interesting alternative to Lua. Besides dissimilar syntax, according to authors, it is heavily influended by lua. The C/C++ binding api is much easier than Lua. Plus many more features.
Cool languages: (not just cool names)
Scala: http://en.wikipedia.org/wiki/Scala_programming_language
Very apealing language because syntax looks like Python and compiles for both Java & .Net platforms. So you already have access to a broad range of Java & .Net libraries.
O'Caml: http://en.wikipedia.org/wiki/Objective_Caml
I guess one of the best functional language plus access to tons external libraries.
Oz: http://en.wikipedia.org/wiki/Oz_programming_language (alas! afaik no opengl)
Erlang: http://en.wikipedia.org/wiki/Erlang_pro ... g_language (used in Wings3d modeler)
Aaah! Lisp:
Lisp like scripting languages have been used in Jax & Daxter and AgeOfEmpires. And some other games.
I looked at various lisp implementations and dialects. They all have problems having lack of libraries which are essential for gamedev (correct me if...). Few have OpenGl access.
Here are ones I found having some practical value for game developers. Lisp implementations for .Net have high apealing because not only you have access to .net libraries but syntax and contructs are more imperative programming friendly.
-Lisp for .Net: http://www.lsharp.org/
-Another Lisp for .Net: http://dotlisp.sourceforge.net/dotlisp.htm
Lush (must checkout): http://lush.sourceforge.net/
A lisp based language, uses C compiler, supports SDL & OpenGl with example programs.
NewLisp: http://www.newlisp.org
A very simple lisp, simpler than scheme. has opengl module.
Embedable Scheme:
http://en.wikipedia.org/wiki/Guile_programming_language
http://sam.zoy.org/elk/
http://www.plt-scheme.org/software/mzscheme/
http://code.google.com/p/muvee-symbolic-expressions/
Embedable Lisp:
http://ecls.sourceforge.net/
Embedable Lisp in Lua:
http://vslisp.sourceforge.net/
http://blog.davber.com/2006/09/07/embed ... p-via-lua/
google for for more scheme/lisp.
Embeddable scripting Language:
Besides lua, python, squirrel, pawn/small, angelscript & other well knowns...
io scripting language: (based on Smalltalk, Self, Lua, Lisp, Act1, NewtonScript)
http://en.wikipedia.org/wiki/Io_programming_language
To me it seems a very interesting alternative to Lua. Besides dissimilar syntax, according to authors, it is heavily influended by lua. The C/C++ binding api is much easier than Lua. Plus many more features.
Cool languages: (not just cool names)
Scala: http://en.wikipedia.org/wiki/Scala_programming_language
Very apealing language because syntax looks like Python and compiles for both Java & .Net platforms. So you already have access to a broad range of Java & .Net libraries.
O'Caml: http://en.wikipedia.org/wiki/Objective_Caml
I guess one of the best functional language plus access to tons external libraries.
Oz: http://en.wikipedia.org/wiki/Oz_programming_language (alas! afaik no opengl)
Erlang: http://en.wikipedia.org/wiki/Erlang_pro ... g_language (used in Wings3d modeler)
Aaah! Lisp:
Lisp like scripting languages have been used in Jax & Daxter and AgeOfEmpires. And some other games.
I looked at various lisp implementations and dialects. They all have problems having lack of libraries which are essential for gamedev (correct me if...). Few have OpenGl access.
Here are ones I found having some practical value for game developers. Lisp implementations for .Net have high apealing because not only you have access to .net libraries but syntax and contructs are more imperative programming friendly.
-Lisp for .Net: http://www.lsharp.org/
-Another Lisp for .Net: http://dotlisp.sourceforge.net/dotlisp.htm
Lush (must checkout): http://lush.sourceforge.net/
A lisp based language, uses C compiler, supports SDL & OpenGl with example programs.
NewLisp: http://www.newlisp.org
A very simple lisp, simpler than scheme. has opengl module.
Embedable Scheme:
http://en.wikipedia.org/wiki/Guile_programming_language
http://sam.zoy.org/elk/
http://www.plt-scheme.org/software/mzscheme/
http://code.google.com/p/muvee-symbolic-expressions/
Embedable Lisp:
http://ecls.sourceforge.net/
Embedable Lisp in Lua:
http://vslisp.sourceforge.net/
http://blog.davber.com/2006/09/07/embed ... p-via-lua/
google for for more scheme/lisp.
- Praetor
- OGRE Retired Team Member
- Posts: 3335
- Joined: Tue Jun 21, 2005 8:26 pm
- Location: Rochester, New York, US
- x 3
- Contact:
Scheme/LISP is certainly very interesting. I like it, to a point. To be honest, it is very difficult for me to pick it up because I'm so used to OO and imperative. But that's a personal problem (though it could be a common personal problem).
Interesting that Io claims to be easier to embed than lua. Because lua is really really easy... I'll definitely look into it out of curiosity though. Thanks for the link.
Interesting that Io claims to be easier to embed than lua. Because lua is really really easy... I'll definitely look into it out of curiosity though. Thanks for the link.
-
- Silver Sponsor
- Posts: 597
- Joined: Sun Jan 07, 2007 11:55 pm
- Location: Cologne, Germany
- Contact:
- ahmedali
- Gnome
- Posts: 302
- Joined: Fri Feb 20, 2004 8:52 pm
- Location: Lahore, Pakistan
Yes Lisp/Scheme can alienate regular imperative programmers. But at first glance at .Net lisp implementations, they have made constructs & other changes friendlier for imperative programmers and to take advantage of .net . So it is possible to use .lisp as an imperative language too at reasonable extent. But personally Im a imperative programmer too; I use lisp for experimental stuff only.
Io has not gained as much popularity as lua, though it has many developers.
A tutorial showing binding io to c++. There are no automated binding project.
http://en.wikibooks.org/wiki/Programmin ... to_C%2B%2B
Io has not gained as much popularity as lua, though it has many developers.
A tutorial showing binding io to c++. There are no automated binding project.
http://en.wikibooks.org/wiki/Programmin ... to_C%2B%2B
-
- Halfling
- Posts: 53
- Joined: Thu Apr 28, 2005 12:09 am
- x 1
I love their quicksort example:When it comes to interesting languages do never forget to mention Haskell (it does have OpenGL access)
Code: Select all
qsort [] = []
qsort (x:xs) = qsort (filter (< x) xs) ++ [x] ++ qsort (filter (>= x) xs)
- Kojack
- OGRE Moderator
- Posts: 7157
- Joined: Sun Jan 25, 2004 7:35 am
- Location: Brisbane, Australia
- x 534
D can link with C libs. It's been linked with SDL to make OpenGL games.I was looking for not so well known languages and atleast having the possiblity to access essential libraries for 3d game development
Take a look at http://www.asahi-net.or.jp/~cs8k-cyu/index_e.html for some awesome games done with D. All have source code available. My favourites are Gunroar and Tumiki Fighters.
- Nauk
- Gnoll
- Posts: 653
- Joined: Thu May 11, 2006 9:12 pm
- Location: Bavaria
- x 36
- Contact:
Thanks for the links, Torus-Trooper rocks to steam off
ARTIFEX TERRA 3D - Artist-friendly, free and easy WYSIWYG realtime outdoor scene Editor & Painter
New loader now with Ogre::Terrain support: Addons for Artifex on SourceForge
MOC - Minimal Ogre Collision & Mousepicking
Simple TerrainMaterialGenerator for the use of standard Ogre material with Ogre::Terrain
Support me on Patreon
-
- Halfling
- Posts: 72
- Joined: Tue Feb 13, 2007 1:57 am
It doesn't seem like theres any way to link with C++, is this right? It looks like I'd have to write lots (and lots!) of pure C interface functions for the dlls and then implement the class hierarchy in D somehow to use ogre. I'm interested in using D, at least a bit, and I'm trying to make sure I understand how much work it would be.Kojack wrote:D can link with C libs. It's been linked with SDL to make OpenGL games.I was looking for not so well known languages and atleast having the possiblity to access essential libraries for 3d game development
Take a look at http://www.asahi-net.or.jp/~cs8k-cyu/index_e.html for some awesome games done with D. All have source code available. My favourites are Gunroar and Tumiki Fighters.
- Kojack
- OGRE Moderator
- Posts: 7157
- Joined: Sun Jan 25, 2004 7:35 am
- Location: Brisbane, Australia
- x 534
Yep, c++ is out. D can link with C libraries only. The same applies to all languages I know, I haven't heard of any language able to use c++ libs directly.
Also, even if you have a C lib, you still need to convert the header file into a D binary module. There's tools to do that (iirc), but you might need to hand edit them if the header uses the preprocessor in tricky ways (D has no preprocessor, but it's compile time and language features (like static if, templates, etc) make up for it).
There was a project called swig4d, which used swig to attach C++ and D, but it was abandoned a few years ago. No idea if anything else has come along since (the thing stopping me using D is the thought of wrapping libs. It's easier to just stick with C++).
Also, even if you have a C lib, you still need to convert the header file into a D binary module. There's tools to do that (iirc), but you might need to hand edit them if the header uses the preprocessor in tricky ways (D has no preprocessor, but it's compile time and language features (like static if, templates, etc) make up for it).
There was a project called swig4d, which used swig to attach C++ and D, but it was abandoned a few years ago. No idea if anything else has come along since (the thing stopping me using D is the thought of wrapping libs. It's easier to just stick with C++).
-
- Halfling
- Posts: 72
- Joined: Tue Feb 13, 2007 1:57 am
Yeah it sounds like it, the manual work to convert a .h file to a .d file looks possible, but writing a C interface to ogre would be a nightmare and would probably end up looking a lot like opengl anyway.Kojack wrote:(the thing stopping me using D is the thought of wrapping libs. It's easier to just stick with C++).
ah well, I'll keep it in mind in case I ever work on something where it would be usable.
-
- Gnoblar
- Posts: 9
- Joined: Sun Feb 22, 2004 10:20 pm
- Location: Greater Pacific Northwest
- Contact:
Thunder and Lightning is probably the best poster-child for Io usage within a game. The TNL author has also recently submitted some patches for Io based on his experiences.