Python isnt that bad, just very specific. But i agree if you had the choice between 2 scripting languages well..... wow.
Even better would be if Blender had its own scripting language, like maya. That was easier to use than python. If you were to go into all this hassle to enable perl scripting y not look into creating bScript or blendScript etc....
(Get together with some scriptors and re-write / create a new scripting lang.)

leinad13 wrote:Python isnt that bad, just very specific. But i agree if you had the choice between 2 scripting languages well..... wow.Even better would be if Blender had its own scripting language, like maya. That was easier to use than python. If you were to go into all this hassle to enable perl scripting y not look into creating bScript or blendScript etc....(Get together with some scriptors and re-write / create a new scripting lang.)

I disagree with the comment that blender should have its own scripting language.

One of the resions I chose blender for my project last year was python- I had already tinkered with Python/OpenGL so it was not hard to learn.

Id be worried that adding more languages would fragment the script effort- I think really good python support would be more worthwhile.
(fix all the python/blender bugs and add more usefull python functions)

Its interesting to look at the Gimp- that supports C/Scheme/Perl and now Python- Im not drawing any conclusions here but Its not the beez-kneez to have lots of languages, thats all.

stiv wrote:It should be trivial to replace the 38,000+ lines of C code that implement Blender's Python interface.

A long afternoon at the most.

Good point, i just would like to think that you dont have to learn Python in order to script for blender, Perl is a much bigger scripting language in my opinion i think anyway. Python is sort of dodgy in a couple of ways, but that could be because i dont know it enough.

stiv wrote:It should be trivial to replace the 38,000+ lines of C code that implement Blender's Python interface.

A long afternoon at the most.

Good point, i just would like to think that you dont have to learn Python in order to script for blender, Perl is a much bigger scripting language in my opinion i think anyway. Python is sort of dodgy in a couple of ways, but that could be because i dont know it enough.

Good point, i just would like to think that you dont have to learn perl in order to script for blender

1) I have no experiance with python, but with perl, the first line of the program is
#!/usr/bin/perl (or what ever your path is) with interpreter flags. So, if a little effort went into using perl as a scripting language as well, a little regex would be all that would be necessary to switch between the two.

2) The Perl6 dev team has taken an interesting direction on the VM. They are building a universal VM of sorts that is supposed to be able to act as the VM for java, TCL, Ruby, Perl and Python.

3) I may be wrong in this one, but from what I've seen, Perl is a larger more robust language. Look at the sheer number of mods available on the CPAN archive. (I'm not arguing the choice to use python in blender, I'm arguing for perls useability)

4) The PDL::Graphics::TriD package would be perfect for blender because it's oriented toward 3d applications.

5) With Perl support for Gimp being extensive as it is, this could add a huge amount of flexability and functionality to artists. I'm thinking something along the lines of BodyPaint. (I think for 3dsMax)

So, as far as I can see, I don't really think that it would be that very damaging to blender to use perl as a scripting language as well as python. If done correctly, it could be very simple and beneficial to the community.

The only concern that I have is for dependencies. With perl, the easiest way to install a package is to use the CPAN script which checks and installs deps. Otherwise you have to play the circular dependancy game and download 40 different .pm files to get anything going.

Is perl object oriented? I've used perl, php, vbscript, javascript, vba and now c (with the Blender source). Personally, I think that Python fits beautifully with Blender, as it is open source, high-level and object-oriented. If perl qualifies on those grounds, too, then I guess it's just a matter of personal preference and code inertia. Viva la Python!

I'm saying that python isn't a good scripting language or that it isn't suited for blender. Hell, qbasic could be well suited with a little creative coding.

The point that I'm trying to say is that perl would make an excellent addition to blender.

I really don't know a great deal about python. I don't really care to. Perl can and does do anything that I personally want it to do already, has a HUGE support base, is well integrated into linux and many applications most notably Apache (which could also serve some purpose with the web plugin) have very good support and optimization for perl.

Another added bonus is that perl comes with a byte code compiler. How is that useful for blender scripting? I'm not really sure. I think, however, that with some clever bits of something or other it could be used in some fashion to do something.... I think.

Honestly, I only have the faintest idea of how to implement this. First, write xsubs for the API, then write a routine to choose either perl or python, then write the actual interface between blender and perl (event handlers, error handlers, stuff like that).

I do not see what Perl offers over Python. Python can do pretty much all the things you mentioned. I do not believe that Perl will allow you to do somehow 'more' than you can do with Python. That said, I'm not against adding another scripting language.

You must know that there is no 'Blender API'. There are .h files of course, and some things are split up into separate modules, but it's not like you want to write direct interfaces for internal Blender functions. This is also why the Python team has so much work, they have to go into Blender's internal code and write functions based on it.

The current Python API is what comes closest to a 'Blender API', that you can use without fear of crashing Blender.

And then there is the (separate) game engine interface too, which is coded in c++, and Python is even mixed with the actual game engine code. Some kind of special base class is used that makes Python recognize the c++ classes, which doesn't make it easier for a second scripting language.

So is C, but having artists write C code is asking a bit much. Python is a simple yet powerful scripting language. You dont need learn python to script in blender. Python is just there to give some extensiblity for low level things like string, etc. Jez, why not just force script writers to write scripts in APL?

Another added bonus is that perl comes with a byte code compiler.

Uggg.
You mean the perl VM would need to be distributed with blender? ... along with having to download perl & python???? I can hear it now "I downloaded perl X.y.z but my scripts don't work - what am I doing wrong?"

I think that having a second scripting lanuage available for users is a good idea, however,
1. I don't think most of the devs would like to be updating .xs files evertime things are added to python. The perl source would have to be a wrapper for the python API otherwise it will simply not get updated - no one is going to write python C API functions and perl XSubs too - or worse that perl and python will end up competing and not be the same API.
2. Removing the python API is not really a feasible option. People who have written scripts for blender such as the beast project/makehuman would be forced to rewrite their entire projects in perl scripts. Also the python API is shorly to become the 2nd largest module in the blender source code.

If you can write wrapper code for the python-API (which i dont think is possible) it might be worth considering, however, even if this was done someone (the python devs) would have to update both API's. Maybe there is a better way to do this. Then there is the concern of spliting the script writing community among perl and python script writers.