POV-Ray : Newsgroups : moray.win : Plugin idea Server Time
11 Nov 2026 23:51:05 EST (-0500)
  Plugin idea (Message 1 to 28 of 28)  
From: Twyst
Subject: Plugin idea
Date: 12 Mar 1999 19:47:25
Message: <36e9b59d.0@news.povray.org>
How about a "scripting language" plugin? It would make it really easy to add
new ideas...

For example, you could have a text file like so:


Dialog

  name "MyDialog"
  sidebar //puts it in the side menu; could be window instead to make it
popup
  //if it's window, have pos X,Y, Size X,Y

checkbox

 pos 10,10
 name "C1"
 value 0
}

label {
  pos 10,20
 value "This is C1"
}

editbox

 pos 10,30
 size 10
 name "RepeatVal"
 value "100"
 }
}

output {
 print "#declare Max=" . $MyDialog(RepeatVal) . ";"
 ....
 ....
}


It's very rudimentary -- but I'm thinking of something along the lines of
the scripting language found uin the mIRC chat program for windows.
(http://www.mirc.co.uk )

Anyone game for this?


Twyst
--
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCS/O d+(-) s-: a-- C+++(++++) UL++ P+(--) L+ E- W+++>$ N++ o- K-
w+(---) O- M-- V- PS+ PE+ Y PGP t 5 X R tv- b++++ DI++ D G++ e h* r-- !y++
------END GEEK CODE BLOCK------


Post a reply to this message

From: Twyst
Subject: Re: Plugin idea
Date: 12 Mar 1999 20:05:08
Message: <36e9b9c4.0@news.povray.org>
Oh ya, thinking about this a bit more:

All the math can be done by pov-ray itself -- so you don't need any
calcualtion functions (Unless you want to do a wireframe representation --
this could be done as well, I think.. . add drawing commands, maybe -- the
plugin defines the points in an array, or a loop, or something..  and passes
the list to the drawing method  )

also, the only thing necessary for povray output, is a method of getting the
values from the dialog, and a print command (that gets called when the
plugin is polled for output)-- after all; povray is happy with text.

Hmm...

Wireframe output prob. isn't possible.. but that's not a big deal, imho.

I can see this bringing out a whole bunch of math or repetitive "scripts"...



--
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCS/O d+(-) s-: a-- C+++(++++) UL++ P+(--) L+ E- W+++>$ N++ o- K-
w+(---) O- M-- V- PS+ PE+ Y PGP t 5 X R tv- b++++ DI++ D G++ e h* r-- !y++
------END GEEK CODE BLOCK------
Twyst wrote in message <36e9b59d.0@news.povray.org>...
>How about a "scripting language" plugin? It would make it really easy to
add
>new ideas...
>
>For example, you could have a text file like so:
>
>
>Dialog
>
>  name "MyDialog"
>  sidebar //puts it in the side menu; could be window instead to make it
>popup
>  //if it's window, have pos X,Y, Size X,Y
>
>checkbox
>
> pos 10,10
> name "C1"
> value 0
>}
>
>label {
>  pos 10,20
> value "This is C1"
>}
>
>editbox
>
> pos 10,30
> size 10
> name "RepeatVal"
> value "100"
> }
>}
>
>output {
> print "#declare Max=" . $MyDialog(RepeatVal) . ";"
> ....
> ....
>}
>
>
>It's very rudimentary -- but I'm thinking of something along the lines of
>the scripting language found uin the mIRC chat program for windows.
>(http://www.mirc.co.uk )
>
>Anyone game for this?
>
>
>Twyst
>--
>-----BEGIN GEEK CODE BLOCK-----
>Version: 3.1
>GCS/O d+(-) s-: a-- C+++(++++) UL++ P+(--) L+ E- W+++>$ N++ o- K-
>w+(---) O- M-- V- PS+ PE+ Y PGP t 5 X R tv- b++++ DI++ D G++ e h* r-- !y++
>------END GEEK CODE BLOCK------
>
>


Post a reply to this message

From: Ph Gibone
Subject: Re: Plugin idea
Date: 13 Mar 1999 02:31:32
Message: <36ea1454.0@news.povray.org>
Why not Java ?

Twyst a écrit dans le message <36e9b59d.0@news.povray.org>...
>How about a "scripting language" plugin? It would make it really easy to
add
>new ideas...
>
>For example, you could have a text file like so:
>
>
>Dialog
>
>  name "MyDialog"
>  sidebar //puts it in the side menu; could be window instead to make it
>popup
>  //if it's window, have pos X,Y, Size X,Y
>
>checkbox
>
> pos 10,10
> name "C1"
> value 0
>}
>
>label {
>  pos 10,20
> value "This is C1"
>}
>
>editbox
>
> pos 10,30
> size 10
> name "RepeatVal"
> value "100"
> }
>}
>
>output {
> print "#declare Max=" . $MyDialog(RepeatVal) . ";"
> ....
> ....
>}
>
>
>It's very rudimentary -- but I'm thinking of something along the lines of
>the scripting language found uin the mIRC chat program for windows.
>(http://www.mirc.co.uk )
>
>Anyone game for this?
>
>
>Twyst
>--
>-----BEGIN GEEK CODE BLOCK-----
>Version: 3.1
>GCS/O d+(-) s-: a-- C+++(++++) UL++ P+(--) L+ E- W+++>$ N++ o- K-
>w+(---) O- M-- V- PS+ PE+ Y PGP t 5 X R tv- b++++ DI++ D G++ e h* r-- !y++
>------END GEEK CODE BLOCK------
>
>


Post a reply to this message

From: Johannes Hubert
Subject: Re: Plugin idea
Date: 13 Mar 1999 04:59:53
Message: <36ea3719.0@news.povray.org>
>Why not Java ?

Huh?

Johannes.


Post a reply to this message

From: Ph Gibone
Subject: Re: Plugin idea
Date: 13 Mar 1999 05:58:43
Message: <36ea44e3.0@news.povray.org>
Johannes Hubert a écrit dans le message <36ea3719.0@news.povray.org>...
>>Why not Java ?
>
>Huh?
>
>Johannes.
>

Uhu !

Philippe


Post a reply to this message

From: Twyst
Subject: Re: Plugin idea
Date: 14 Mar 1999 22:48:42
Message: <36ec831a.0@news.povray.org>
Uhm.

Java sucks. End of story. Apart from the fact that Moray doesn't use or
support it.
--
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCS/O d+(-) s-: a-- C+++(++++) UL++ P+(--) L+ E- W+++>$ N++ o- K-
w+(---) O- M-- V- PS+ PE+ Y PGP t 5 X R tv- b++++ DI++ D G++ e h* r-- !y++
------END GEEK CODE BLOCK------




Ph Gibone wrote in message <36ea1454.0@news.povray.org>...
>Why not Java ?
>


Post a reply to this message

From: Ph Gibone
Subject: Re: Plugin idea
Date: 15 Mar 1999 02:54:49
Message: <36ecbcc9.0@news.povray.org>
Twyst a écrit dans le message <36ec831a.0@news.povray.org>...
>
>Uhm.
>
>Java sucks. End of story. Apart from the fact that Moray doesn't use or
>support it.
>--


Java Exists. End of story

Moray doesn't use or support any scripting language so far


Philippe


Post a reply to this message

From: Johannes Hubert
Subject: Re: Plugin idea
Date: 15 Mar 1999 03:33:42
Message: <36ecc5e6.0@news.povray.org>
Ph Gibone wrote in message <36ecbcc9.0@news.povray.org>...
>
>Twyst a écrit dans le message <36ec831a.0@news.povray.org>...
>>
>>Uhm.
>>
>>Java sucks. End of story. Apart from the fact that Moray doesn't use or
>>support it.
>>--
>
>
>Java Exists. End of story
>
>Moray doesn't use or support any scripting language so far
>


That's the reason for my previous "Huh?": Java is not a scripting language,
so I don't really see a good reason to use it here.
Maybe you mean JavaScript??? (Wouldn't be very useful either, since it is
mostly web-oriented)

Johannes.


Post a reply to this message

From: Ken
Subject: Re: Plugin idea
Date: 15 Mar 1999 07:57:09
Message: <36ED041C.CDB298F9@pacbell.net>
Ph Gibone wrote:

> 
> Moray doesn't use or support any scripting language so far
> 
> Philippe

  Moray can use the older versions or Pov script if run thorugh a parser
first. Has been able to do that for years now. Not that many people
go thorugh the trouble but it is possible.

-- 
Ken Tyler

mailto://tylereng@pacbell.net


Post a reply to this message

From: Ph Gibone
Subject: Re: Plugin idea
Date: 15 Mar 1999 12:54:41
Message: <36ed4961.0@news.povray.org>
>Maybe you mean JavaScript??? (Wouldn't be very useful either, since it is
>mostly web-oriented)
>


You're right on this point, but at least you can define something which more
or less looks like a dialog box !

BTW I'm not a Java freak neither a Java fan but when something exists you
can take the good out of it !

Philippe


Post a reply to this message

From: Ph Gibone
Subject: Re: Plugin idea
Date: 15 Mar 1999 13:00:16
Message: <36ed4ab0.0@news.povray.org>
Ken a écrit dans le message <36ED041C.CDB298F9@pacbell.net>...
>Ph Gibone wrote:
>
>>
>> Moray doesn't use or support any scripting language so far
>>
>> Philippe
>
>  Moray can use the older versions or Pov script if run thorugh a parser
>first. Has been able to do that for years now. Not that many people
>go thorugh the trouble but it is possible.
>
>--
>Ken Tyler
>
>mailto://tylereng@pacbell.net


I'm part of the last category !

To make things clear, when I wrote about a scripting language for Moray I
thought that it would be very convenient to be able to write a plugin even
if you don't know C, C++, WIndows SDK, That's what Java wants to do.
Personnaly I don't care : I'm a C++ programmer and Ive been an assembly
programmer during years.

Philippe


Post a reply to this message

From: Twyst
Subject: Re: Plugin idea
Date: 15 Mar 1999 16:01:07
Message: <36ed7513.0@news.povray.org>
I think you both have misunderstood the concept that I was trying to
present.

Java has nothing to do with this. I am talking about a plugin that will read
a text file and according to what it has in it, it draws a dialog.

***NOTE***

this is meant to allow non-programmers to write their own plugins, using a
specified format.
*** Java is NOT good for this.. ... ..

the format doesn't matter - but the idea is that John Q. Public can create a
text file that has his custom "plugin" and then send it to his buddy who
also has the plugin.

Here's an example mIRC script that will create a dialog -- this is sort of
what I'm thinking of.:

Dialog AllDialog {

  Title "Example Dialog Window"
  Size -1 -1 300 200

  Button "Ok", 1, 5 175 55 20, ok
  Button "Cancel", 2, 65 175 55 20, cancel

  Box "Box 1", 3, 5 5 140 70
  Box "Box 2", 4, 5 80 140 85
  Box "Box 3", 5, 155 130 140 60

  Radio "Item 1 - Dotted Radio", 6, 10 20 130 15, group
  Radio "Item 2 - Dotted Radio", 7, 10 35 130 15,
  Radio "Item 3 - Dotted Radio", 8, 10 50 130 15,

  Radio "Item 1", 9, 10 140 60 18, group push
  Radio "Item 2", 10, 75 140 60 18, push

  Check "Item 1 - Checkbox", 11, 165 147 120 15
  Check "Item 2 - Checkbox", 12, 165 167 120 15

  Edit "", 13, 10 95 125 22, autohs

  List 14, 155 50 140 80, sort

  Combo 15, 155 10 140 150, drop

  Text "Edit box", 16, 10 120 125 20

  Text "Drop Down Combo Box", 17, 155 32 140 20

  Text "List box", 18, 155 112 140 20
}

for example, in the first row containing "Button", it breaks down like so:

Object_type "Name" ,ID, X Y Width Height,  value

this is relatively simple, and easily coded without the need for java or
javascript. (i mean the script, not the plugin.)

Of course, there will need to be methods for getting values, output, and for
resetting to defaults.

List of features that would be nice:

- ability to spawn child dialogs
- sliders/spinners
- Loading scripts


I'd try -- but I don't know C/C++, and I don't think that Visual Basic would
work for this...


Twyst
--
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCS/O d+(-) s-: a-- C+++(++++) UL++ P+(--) L+ E- W+++>$ N++ o- K-
w+(---) O- M-- V- PS+ PE+ Y PGP t 5 X R tv- b++++ DI++ D G++ e h* r-- !y++
------END GEEK CODE BLOCK------
Johannes Hubert wrote in message <36ecc5e6.0@news.povray.org>...
>Ph Gibone wrote in message <36ecbcc9.0@news.povray.org>...
>>
>>Twyst a écrit dans le message <36ec831a.0@news.povray.org>...
>>>
>>>Uhm.
>>>
>>>Java sucks. End of story. Apart from the fact that Moray doesn't use or
>>>support it.
>>>--
>>
>>
>>Java Exists. End of story
>>
>>Moray doesn't use or support any scripting language so far
>>
>
>
>That's the reason for my previous "Huh?": Java is not a scripting language,
>so I don't really see a good reason to use it here.
>Maybe you mean JavaScript??? (Wouldn't be very useful either, since it is
>mostly web-oriented)
>
>Johannes.
>
>
>


Post a reply to this message

From: Rudy Velthuis
Subject: Re: Plugin idea
Date: 15 Mar 1999 17:15:59
Message: <36ed869f.0@news.povray.org>
Twyst schrieb in Nachricht <36ed7513.0@news.povray.org>...
>
>I'd try -- but I don't know C/C++, and I don't think that Visual Basic
would
>work for this...

It should, if you can get someone to translate the main header file for you
and if you can create real normal dlls (not OLE or ActiveX dlls) with VB (I
think VB6 can do this, not sure tho). Otherwise you're out of luck. Would be
a nice interface.

--
Rudy


Post a reply to this message

From: Ph Gibone
Subject: Re: Plugin idea
Date: 15 Mar 1999 17:39:32
Message: <36ed8c24.0@news.povray.org>
Hi TWYST

5 more things :

1) I'm not a Java Fan
2) The actual Plugin interface is pure genius, very easy to use as long as
you know C/C++, which is the least for a DLL
3) If you want to have a full featured language one day or another you will
need something as sophisticated as JavaScript (if we can say it is),
Personally I'm very glad with the actual interface, and I don't need
anything else.
4) A good idea for plugins would be for any of us that has an idea for a
good plugin : send a mail to Lutz so that he can publish your request, and
publish a request in this forum, I'm sure that some one will take it, and if
not, the language will not be the reason.
5) The following lines of codes are JavaScript, isn't it what you ask for ?
This is not a very rich example, and I agree that the presence of items like
this.form can sound cryptic. For me the *ONLY* advantage of JavaScript is :
it exists !

<SCRIPT LANGUAGE="JavaScript">

<!-- Original: Rick Johnson -->
<!-- Web Site:  http://members.tripod.com/~RickJohnson -->

<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->

<!-- Begin
function a_plus_b(form) {
a=eval(form.a.value)
b=eval(form.b.value)
c=a+b
form.ans.value = c
}
function a_minus_b(form) {
a=eval(form.a.value)
b=eval(form.b.value)
c=a-b
form.ans.value=c
}
function a_times_b(form) {
a=eval(form.a.value)
b=eval(form.b.value)
c=a*b
form.ans.value=c
}
function a_div_b(form) {
a=eval(form.a.value)
b=eval(form.b.value)
c=a/b
form.ans.value = c
}
function a_pow_b(form) {
a=eval(form.a.value)
b=eval(form.b.value)
c=Math.pow(a, b)
form.ans.value = c
}
// End -->
</SCRIPT>

<!-- STEP TWO: Put this code into the BODY of your HTML document  -->

<BODY>
<CENTER>
<FORM name="formx"><input type=text size=4 value=12 name="a">
<input type="button" value="  +  " onClick="a_plus_b(this.form)">
<input type="button" value="  -  " onClick="a_minus_b(this.form)">
<input type="button" value="  x  " onClick="a_times_b(this.form)">
<input type="button" value="  /  " onClick="a_div_b(this.form)">
<input type="button" value="  ^  " onClick="a_pow_b(this.form)">
<input type="number" size=4 value=3 name="b"> = <input type "number" value=0
name="ans" size=9>
</FORM>
</CENTER>

<!-- Script Size:  1.72 KB  -->


Philippe


Post a reply to this message

From: Nathan Kopp
Subject: Re: Plugin idea
Date: 15 Mar 1999 23:17:55
Message: <36EDDB2A.6C1C618D@Kopp.com>
Twyst,

I really like your concept (I've been following this thread for a bit).  I
think that you'll a bit more powerful of a scripting language, though, in
order for a plug-in to be able to do anything useful.  Trying to jump all
the way to javascript (or something like it) would probably be a bit
difficult (unless there's open source code available to parse and execute
it already).  Maybe something a bit simpler, but something that is
designed for growth.

-Nathan

Twyst wrote:
> 
> I think you both have misunderstood the concept that I was trying to
> present.
> 
> Java has nothing to do with this. I am talking about a plugin that will read
> a text file and according to what it has in it, it draws a dialog.
> 
> ***NOTE***
> 
> this is meant to allow non-programmers to write their own plugins, using a
> specified format.
> *** Java is NOT good for this.. ... ..
> 
> the format doesn't matter - but the idea is that John Q. Public can create a
> text file that has his custom "plugin" and then send it to his buddy who
> also has the plugin.
> 
> Here's an example mIRC script that will create a dialog -- this is sort of
> what I'm thinking of.:
> 
> Dialog AllDialog {
> 
>   Title "Example Dialog Window"
>   Size -1 -1 300 200
> 
>   Button "Ok", 1, 5 175 55 20, ok
>   Button "Cancel", 2, 65 175 55 20, cancel
> 
>   Box "Box 1", 3, 5 5 140 70
>   Box "Box 2", 4, 5 80 140 85
>   Box "Box 3", 5, 155 130 140 60
> 
>   Radio "Item 1 - Dotted Radio", 6, 10 20 130 15, group
>   Radio "Item 2 - Dotted Radio", 7, 10 35 130 15,
>   Radio "Item 3 - Dotted Radio", 8, 10 50 130 15,
> 
>   Radio "Item 1", 9, 10 140 60 18, group push
>   Radio "Item 2", 10, 75 140 60 18, push
> 
>   Check "Item 1 - Checkbox", 11, 165 147 120 15
>   Check "Item 2 - Checkbox", 12, 165 167 120 15
> 
>   Edit "", 13, 10 95 125 22, autohs
> 
>   List 14, 155 50 140 80, sort
> 
>   Combo 15, 155 10 140 150, drop
> 
>   Text "Edit box", 16, 10 120 125 20
> 
>   Text "Drop Down Combo Box", 17, 155 32 140 20
> 
>   Text "List box", 18, 155 112 140 20
> }
> 
> for example, in the first row containing "Button", it breaks down like so:
> 
> Object_type "Name" ,ID, X Y Width Height,  value
> 
> this is relatively simple, and easily coded without the need for java or
> javascript. (i mean the script, not the plugin.)
> 
> Of course, there will need to be methods for getting values, output, and for
> resetting to defaults.
> 
> List of features that would be nice:
> 
> - ability to spawn child dialogs
> - sliders/spinners
> - Loading scripts
> 
> I'd try -- but I don't know C/C++, and I don't think that Visual Basic would
> work for this...
> 
> Twyst
> --
> -----BEGIN GEEK CODE BLOCK-----
> Version: 3.1
> GCS/O d+(-) s-: a-- C+++(++++) UL++ P+(--) L+ E- W+++>$ N++ o- K-
> w+(---) O- M-- V- PS+ PE+ Y PGP t 5 X R tv- b++++ DI++ D G++ e h* r-- !y++
> ------END GEEK CODE BLOCK------
> Johannes Hubert wrote in message <36ecc5e6.0@news.povray.org>...
> >Ph Gibone wrote in message <36ecbcc9.0@news.povray.org>...
> >>
> >>Twyst a écrit dans le message <36ec831a.0@news.povray.org>...
> >>>
> >>>Uhm.
> >>>
> >>>Java sucks. End of story. Apart from the fact that Moray doesn't use or
> >>>support it.
> >>>--
> >>
> >>
> >>Java Exists. End of story
> >>
> >>Moray doesn't use or support any scripting language so far
> >>
> >
> >
> >That's the reason for my previous "Huh?": Java is not a scripting language,
> >so I don't really see a good reason to use it here.
> >Maybe you mean JavaScript??? (Wouldn't be very useful either, since it is
> >mostly web-oriented)
> >
> >Johannes.
> >
> >
> >


Post a reply to this message

From: Johannes Hubert
Subject: Re: Plugin idea
Date: 16 Mar 1999 03:00:26
Message: <36ee0f9a.0@news.povray.org>
Ph Gibone wrote in message <36ed4961.0@news.povray.org>...
>>Maybe you mean JavaScript??? (Wouldn't be very useful either, since it is
>>mostly web-oriented)
>>
>
>
>You're right on this point, but at least you can define something which
more
>or less looks like a dialog box !


OK, now I get your point that you were thinking about how to define
dialogs...
Well, I still don't think that Java or JavaScript would be the right thing,
but at least my initial "Huh?" is cleared up! ;-)

Johannes.


Post a reply to this message

From: Johannes Hubert
Subject: Re: Plugin idea
Date: 16 Mar 1999 03:25:16
Message: <36ee156c.0@news.povray.org>
Twyst wrote in message <36ed7513.0@news.povray.org>...
>I think you both have misunderstood the concept that I was trying to
>present.


Actually, I understood you quite well the first time. That is why I was so
confused when Phillipe suggested Java.

I aggree that it is probably easiest to define a new simple script-language
that makes part of the power of the plugin-interface/SDK available to non
C/C++ programmers.
But we shouldn't kid ourselves: It will not work for non-programmers,
because it will still be a programming language. It will only take away the
need of that DLL building and stuff. Anyway, it sound like a cool idea to
me, something that seems worthy of checking out...

Johannes.


Post a reply to this message

From: Johannes Hubert
Subject: Re: Plugin idea
Date: 16 Mar 1999 03:25:17
Message: <36ee156d.0@news.povray.org>
Ph Gibone wrote in message <36ed4ab0.0@news.povray.org>...
>
>To make things clear, when I wrote about a scripting language for Moray I
>thought that it would be very convenient to be able to write a plugin even
>if you don't know C, C++, WIndows SDK,
[snip]

That is where the misunderstanding was, I think:

Twyst was thinking of a plug-in that would offer a simply scripting-language
to make part of the plug-in interface available to non (C/C++)-programmers,
or at least available without the need of compiling and building DLLs.

Your idea was to change/adapt the plugin interface of Moray so that it would
facilitate writing plugins in Java instead of C/C++.

Both are good ideas, but different ones, in my view.

You idea may be possible to realize in two ways: First (of course) would be
for Markus and Lutz to change the plugin-interface to allow interfacing to
Java (frankly, I don't see this happening ;-)
Or someone could write a Moray plugin in C++ that is actually only a wrapper
for the plugin-interface, and that exposes all interface methods and members
to a similar Java interface.

But the main question is: Is this needed?
Are there really people who are dying to write a Moray plugin and only don't
do so because they would have to program in C/C++? And would the same people
start programming like hell, if they could do so in Java instead?
I don't think so, because even in Java it would still require some
above-beginner-level programming skills, and people with such skills are
usually not bothered by the fact of which language they would have to use
for a certain task.

Java has other disadvantages for a project like this: The number of
different VM's that all behave slightly different would require quite some
testing of such a plugin, to make sure that it runs everywhere. Or the
author could require a certain VM (and a certain version of it) to be
installed, adding more installation burdon to the end-user.
Then there is the general sluggishness of Java (granted, it can be overcome
by the right programming, but still...).
Also the memory usage: Expect your VM (with a program loaded and running) to
use up at least 5-10 Megs of RAM - memory that is no longer available for
Moray (and more importantly POV-Ray) anymore.
And last not least: The look and feel (even with Swing's Windows L&F) would
be different between Moray and Java plugins, making them appear less
"seamless".

OK, just to clear that up (and because Philippe always stresses that he is
*not* a "Java-fan" ;-) I want to stress that I am not a Java "basher":
Actually, I earn my living by programming in Java and I like it (but it also
makes me very aware of its many shortcomings).

Greetings,
Johannes.


Post a reply to this message

From: Ph Gibone
Subject: Re: Plugin idea
Date: 16 Mar 1999 03:40:22
Message: <36ee18f6.0@news.povray.org>
>But we shouldn't kid ourselves: It will not work for non-programmers,
>because it will still be a programming language.

That's exactly what I mean, so why not take advantage of an existing one ?

Philippe


Post a reply to this message

From: Ph Gibone
Subject: Re: Plugin idea
Date: 16 Mar 1999 04:00:21
Message: <36ee1da5.0@news.povray.org>
Hi Johannes

I agree to most of the things you just wrote, but I want to add a few things

1) I was not thinking of a full featured Java VM, but I was thinking of
using the syntax of JavaScript, because, as you pointed it, someone will
need a very simple tool and some other will need a very sophisticated one,
so we need something sophisticated enough.

2) Don't hide yourself behind your finger (nothing personnal), writing a
plugin needs some skills, but it would be nice to get rid of SDK's hassles.

3) I insist : if someone has a good idea for a plugin, just publish the
request, I (or somebody else) will be glad to take it

Philippe


Post a reply to this message

From: Rudy Velthuis
Subject: Re: Plugin idea
Date: 16 Mar 1999 07:56:16
Message: <36ee54f0.0@news.povray.org>
Nathan Kopp schrieb in Nachricht <36EDDB2A.6C1C618D@Kopp.com>...
>Twyst,
>
>I really like your concept (I've been following this thread for a bit).  I
>think that you'll a bit more powerful of a scripting language, though, in
>order for a plug-in to be able to do anything useful.  Trying to jump all
>the way to javascript (or something like it) would probably be a bit
>difficult (unless there's open source code available to parse and execute
>it already).  Maybe something a bit simpler, but something that is
>designed for growth.


There are a few simple free macro languages on the net. If I could only
remember where I had seen them. One would only have to write a plugin dll
wrapper for them. I also like the concept. This would be like Word-Basic as
it was before Office 97: a simple macro language for Moray.

--
Rudy


Post a reply to this message

From: Alex Magidow
Subject: Re: Plugin idea
Date: 16 Mar 1999 08:12:19
Message: <36EE587E.E00012A2@mninter.net>
Johannes Hubert wrote:

> Ph Gibone wrote in message <36ed4ab0.0@news.povray.org>...
> >
> >To make things clear, when I wrote about a scripting language for Moray I
> >thought that it would be very convenient to be able to write a plugin even
> >if you don't know C, C++, WIndows SDK,
> [snip]
>
> That is where the misunderstanding was, I think:
>
> Twyst was thinking of a plug-in that would offer a simply scripting-language
> to make part of the plug-in interface available to non (C/C++)-programmers,
> or at least available without the need of compiling and building DLLs.
>
> Your idea was to change/adapt the plugin interface of Moray so that it would
> facilitate writing plugins in Java instead of C/C++.
>
> Both are good ideas, but different ones, in my view.
>
> You idea may be possible to realize in two ways: First (of course) would be
> for Markus and Lutz to change the plugin-interface to allow interfacing to
> Java (frankly, I don't see this happening ;-)
> Or someone could write a Moray plugin in C++ that is actually only a wrapper
> for the plugin-interface, and that exposes all interface methods and members
> to a similar Java interface.
>
> But the main question is: Is this needed?
> Are there really people who are dying to write a Moray plugin and only don't
> do so because they would have to program in C/C++? And would the same people
> start programming like hell, if they could do so in Java instead?
> I don't think so, because even in Java it would still require some
> above-beginner-level programming skills, and people with such skills are
> usually not bothered by the fact of which language they would have to use
> for a certain task.
>

I think that such a plugin would, perhaps, be quite useful. I am a Moray user,
with a decent level of knowlege about C++(but only in DOS), and I want to write
plugins for Moray. Also, I don't have VC++ 5.0, so thats another thing that I
can't do with them.

I think that all you need for the given plugin is this:
The dialogue box.
The export of the dialogue box.
The wireframe of the object created by the dialogue box.

The first two ought to be pretty easy, even for non-programmers, as long as they
have at least a decent familiarity with POV-Code. The last section would be a
bit harder to write, but nonetheless, it would be easier than having to write a
windows program. By encapsulating this code, I think that you open up Moray to a
great amount of new plugins. Everyone who writes those little plugin requests
will be able to at least TRY to write new plugins, without having to buy a major
C++ compiler or something similar, as well as a few books on programming.

I think, though, that you may just want to create a bunch of .h files, or
libraries, or soemthing, so that you can compile the plugin before hand. But
that would require a commercial compiler, so strike that idea.

> Java has other disadvantages for a project like this: The number of
> different VM's that all behave slightly different would require quite some
> testing of such a plugin, to make sure that it runs everywhere. Or the
> author could require a certain VM (and a certain version of it) to be
> installed, adding more installation burdon to the end-user.
> Then there is the general sluggishness of Java (granted, it can be overcome
> by the right programming, but still...).
> Also the memory usage: Expect your VM (with a program loaded and running) to
> use up at least 5-10 Megs of RAM - memory that is no longer available for
> Moray (and more importantly POV-Ray) anymore.
> And last not least: The look and feel (even with Swing's Windows L&F) would
> be different between Moray and Java plugins, making them appear less
> "seamless".
>
> OK, just to clear that up (and because Philippe always stresses that he is
> *not* a "Java-fan" ;-) I want to stress that I am not a Java "basher":
> Actually, I earn my living by programming in Java and I like it (but it also
> makes me very aware of its many shortcomings).
>
> Greetings,
> Johannes.



--
Only I can prevent narcissism!


Post a reply to this message

From: Alexander Enzmann
Subject: Re: Plugin idea
Date: 16 Mar 1999 09:23:57
Message: <36EE6908.F0004D10@mitre.org>
Johannes Hubert wrote:
> 
> Ph Gibone wrote in message <36ed4ab0.0@news.povray.org>...
> >
> >To make things clear, when I wrote about a scripting language for Moray I
> >thought that it would be very convenient to be able to write a plugin even
> >if you don't know C, C++, WIndows SDK,
> [snip]
> 
> That is where the misunderstanding was, I think:
> 
> Twyst was thinking of a plug-in that would offer a simply scripting-language
> to make part of the plug-in interface available to non (C/C++)-programmers,
> or at least available without the need of compiling and building DLLs.

That would be a pretty nice thing to have - especially considering the
size of today's compilers...

One thing seems like an obvious alternative to the suggestions made so
far - use the Windows Scripting Host (WSH).  Already has support for
VBScript and JScript...

See http://msdn.microsoft.com/scripting/ for details.  Why only have one
scripting language available.


> ...
> 
> But the main question is: Is this needed?
> Are there really people who are dying to write a Moray plugin and only don't
> do so because they would have to program in C/C++? ...

On the other hand, even those of use that do write plugins in C++ might
like the ability to do simple scene building stuff as a script, rather
than having to build an entire DLL to do the job.

An obvious response is that it is possible to do this sort of thing as a
POV-Ray macro.  But then, the script only works with POV-Ray - I make a
renderer and I'd much prefer to have the scripting done in Moray, and
then have it be exportable to the renderer of choice.

Xander


Post a reply to this message

From: Nathan Kopp
Subject: Re: Plugin idea
Date: 16 Mar 1999 09:49:56
Message: <36EE6F4B.3B8C0E8D@Kopp.com>
Johannes Hubert wrote:
> 
> It will only take away the need of that DLL building and stuff.

And with that it would take away the need to have development tools like
VC++ or Borland (Inprise).  That would allow more people to write plugins.

-Nathan


Post a reply to this message

From: Nathan Kopp
Subject: Re: Plugin idea
Date: 16 Mar 1999 09:54:55
Message: <36EE7075.F44AEEEC@Kopp.com>
Alex Magidow wrote:
> 
> I think that all you need for the given plugin is this:
> The dialogue box.
> The export of the dialogue box.
> The wireframe of the object created by the dialogue box.

You also need to be able to save the pluged-in object to the MDL file.
(and do stuff like copy and paste)

-Nathan


Post a reply to this message

From: Ph Gibone
Subject: Re: Plugin idea
Date: 16 Mar 1999 11:26:41
Message: <36ee8641.0@news.povray.org>
Hi Twyst

Just looking at the length of this thread : you had a very good idea.


Philippe

--The universe is the only place I know where you can get a good steack--


Post a reply to this message

From: Lue Ebra
Subject: Re: Plugin idea
Date: 17 Mar 1999 04:07:06
Message: <36ef70ba.0@news.povray.org>
I've been following this thread for a while and have a question for Philippe
Are you suggesting using JS for the macros (afterall, it would be basically
a macro plugin)? While JS has the "advantage" of existing, there it wouldn't
be an ideal language for this specific application. Twyst's original idea
for the macros was a lot simpler and easier to understand for the
"non-programmer". I grew up in the age of COBOL, BASIC, and LOGO.. they had
a certian simplicity that today's languages lack (including JS)
On the upside, it would be a novel non-web based use for what's basically a
web script.
 Lue Ebra
url /say $chan www.triangle.quik.com/lueebra
Ph Gibone wrote in message <36ee18f6.0@news.povray.org>...
>>But we shouldn't kid ourselves: It will not work for non-programmers,
>>because it will still be a programming language.
>
>That's exactly what I mean, so why not take advantage of an existing one ?
>
>Philippe
>
>


Post a reply to this message

From: Ph Gibone
Subject: Re: Plugin idea
Date: 17 Mar 1999 05:55:11
Message: <36ef8a0f.0@news.povray.org>
Hi Lue

 I didn't expect to raise so many swords suggesting JS as a macro language
for Moray plugin.

What I suggest, following the excellent idea by Twyst, is to have a plugin
(written in C/C++ as present plugins, by a talented programmer) able to read
a script file (1 script file = 1 plugin in written by anyone knowing the
scripting language and not necessarily C/C++, and anyway it saves a compiler
:-)) and then, based on the script file infos :

1) create and open a dialog box to input the needed values
2) tell Moray how to draw the wireframe, according to these values
3) tell PovRay how to ray-trace (means create the pov ray object)
4) tell Moray how to initialize, load, read, copy ...

What we need is a scripting language able to
1)   describe a dialog box and its content,
2)   know what is a variable (if possible structured one)
3)   do much math (plugins need that)
4)   and many other things

And what is to be noted is that we need first to define a syntax (as
complete as possible) for this scripting language before programming the
analyser so we have two solutions

1) use the syntax of a scripting language able to do most of the things we
need (and we don't need to implement all of it), and the happy fews knowing
the inspiring language will have a short learning curve)
2) re invent the wheel (an so every body will have to learn a new language)

The end of the story is : The talented programmer that will create the
scripting plugin will certainly have the right to choose


Sorry for my loosy english, I'm afraid most of the confusion comes from my
difficulties mastering this language (which has the advantage to exist :-)))


Philippe


Lue Ebra a écrit dans le message <36ef70ba.0@news.povray.org>...
>I've been following this thread for a while and have a question for
Philippe
>Are you suggesting using JS for the macros (afterall, it would be basically
>a macro plugin)? While JS has the "advantage" of existing, there it
wouldn't
>be an ideal language for this specific application. Twyst's original idea
>for the macros was a lot simpler and easier to understand for the
>"non-programmer". I grew up in the age of COBOL, BASIC, and LOGO.. they had
>a certian simplicity that today's languages lack (including JS)
>On the upside, it would be a novel non-web based use for what's basically a
>web script.
> Lue Ebra
>url /say $chan www.triangle.quik.com/lueebra
>Ph Gibone wrote in message <36ee18f6.0@news.povray.org>...
>>>But we shouldn't kid ourselves: It will not work for non-programmers,
>>>because it will still be a programming language.
>>
>>That's exactly what I mean, so why not take advantage of an existing one ?
>>
>>Philippe
>>
>>
>
>


Post a reply to this message

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