[Q] How to export a script

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

[Q] How to export a script

Young-Jin Lee-3
Hi,

I am looking for a way to export a script in one project so that it can be used in another project. I looked for contextual menus and googled it, but found no solution yet. Can anyone tell me if it is possible?

Also, I have another question about using a movie file in etoy. In one of the demo projects that comes with etoy (a free-fall experiment), I found a set of JPEG images imported from a movie file. Does etoy can save selected frames from a movie as image files? If not, what is the best way to create image files from a movie file so that they can be used in etoy?

Thank you so much!!!

Young-Jin

_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

Karl Ramberg
On 2009-08-11 18:44, Young-Jin Lee wrote:

> Hi,
>
> I am looking for a way to export a script in one project so that it
> can be used in another project. I looked for contextual menus and
> googled it, but found no solution yet. Can anyone tell me if it is
> possible?
>
> Also, I have another question about using a movie file in etoy. In one
> of the demo projects that comes with etoy (a free-fall experiment), I
> found a set of JPEG images imported from a movie file. Does etoy can
> save selected frames from a movie as image files? If not, what is the
> best way to create image files from a movie file so that they can be
> used in etoy?
>
> Thank you so much!!!
Scripts are a part of a Player and you bring it along when you for
example copy and paste a Player. ( ctrl+c and ctrl+v )

Or put the Player in a global flap and pull it out and put it into the
you want.

These procedures are not well documented at the moment.


Karl


_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

Yoshiki Ohshima-2
In reply to this post by Young-Jin Lee-3
At Tue, 11 Aug 2009 11:44:22 -0500,
Young-Jin Lee wrote:
>
> Hi,
>
> I am looking for a way to export a script in one project so that it can be used in another project. I looked for
> contextual menus and googled it, but found no solution yet. Can anyone tell me if it is possible?

  Like Karl wrote, a script is tied to its player (player's uniclass,
really).  One thing you can do is, to turn the "debugHaloHandle"
preference on, get the halo of the object and from the gray debug
menu, choose "save morph in file" to create a .morph file.  It saves
the morph's player altogether.  Later you can load it from "find any
file" or dragging the .morph file from Explorer/Finder to the Squeak
window.

  For Supplies Bin, there is a machinary to save all the user defined
objects but there is no simple UI;  If you know what to type as
Smalltalk expression for the Supplies bin, you can do it.

> Also, I have another question about using a movie file in etoy. In one of the demo projects that comes with etoy (a
> free-fall experiment), I found a set of JPEG images imported from a movie file. Does etoy can save selected frames from
> a movie as image files? If not, what is the best way to create image files from a movie file so that they can be used in
> etoy?

  If the movie file in the format supported by the MPEGMoviePlayer or
GStreamerMoviePlayer, getting out frames programatically can be done.
Otherwise, I'd use an external tool...  Could be a Windows Movie Maker
or iMovie but can be cumbersome.  Does anybody have a better idea?

-- Yoshiki
_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

Karl Ramberg
On 2009-08-12 18:19, Yoshiki Ohshima wrote:

> At Tue, 11 Aug 2009 11:44:22 -0500,
> Young-Jin Lee wrote:
>    
>> Hi,
>>
>> I am looking for a way to export a script in one project so that it can be used in another project. I looked for
>> contextual menus and googled it, but found no solution yet. Can anyone tell me if it is possible?
>>      
>    Like Karl wrote, a script is tied to its player (player's uniclass,
> really).  One thing you can do is, to turn the "debugHaloHandle"
> preference on, get the halo of the object and from the gray debug
> menu, choose "save morph in file" to create a .morph file.  It saves
> the morph's player altogether.  Later you can load it from "find any
> file" or dragging the .morph file from Explorer/Finder to the Squeak
> window.
>
>    For Supplies Bin, there is a machinary to save all the user defined
> objects but there is no simple UI;  If you know what to type as
> Smalltalk expression for the Supplies bin, you can do it.
>
>    
>> Also, I have another question about using a movie file in etoy. In one of the demo projects that comes with etoy (a
>> free-fall experiment), I found a set of JPEG images imported from a movie file. Does etoy can save selected frames from
>> a movie as image files? If not, what is the best way to create image files from a movie file so that they can be used in
>> etoy?
>>      
>    If the movie file in the format supported by the MPEGMoviePlayer or
> GStreamerMoviePlayer, getting out frames programatically can be done.
> Otherwise, I'd use an external tool...  Could be a Windows Movie Maker
> or iMovie but can be cumbersome.  Does anybody have a better idea?


We should in my opinion have a internal conversion of video to Holder.
(and Holder to video)
But such a feature would need work:
     Make it possible to select a short sequence of the video for
conversion.
     Set frame rate and frame size and possibility to crop out a
selection of the video.

Another issue:
Where are copy and paste menu items when in Etoy mode ??

Karl



_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

Karl Ramberg
In reply to this post by Karl Ramberg
On 2009-08-12 01:53, Young-Jin Lee wrote:
Karl,

I must be too novice because I don't understand your explanation. :-(

First of all, could you explain in more detail what you meant by a "Player". I know that I can use a "Players" tool from the toolbox of the eToy, but I think this is not what you were talking about because I did not see a copy/paste menu on the Players tool.
Every object in Etoys is a Player :-)
And you are right, there is no copy and paste items in the menus :-(
I'll look into that.

Also, I do not know how to make a global flap (therefore, I do not know how to put a player into the global flap, either. Could you please give more detailed information or point me to the resources explaining what you suggested.
Here is a video that describe how you can do this:
http://wiki.squeakland.org/display/sq/How+to+move+a+Player+to+another+project

Karl



Thanks in advance.

Young-Jin

On Tue, Aug 11, 2009 at 2:41 PM, Karl Ramberg <[hidden email]> wrote:
On 2009-08-11 18:44, Young-Jin Lee wrote:
Hi,

I am looking for a way to export a script in one project so that it can be used in another project. I looked for contextual menus and googled it, but found no solution yet. Can anyone tell me if it is possible?

Also, I have another question about using a movie file in etoy. In one of the demo projects that comes with etoy (a free-fall experiment), I found a set of JPEG images imported from a movie file. Does etoy can save selected frames from a movie as image files? If not, what is the best way to create image files from a movie file so that they can be used in etoy?

Thank you so much!!!
Scripts are a part of a Player and you bring it along when you for example copy and paste a Player. ( ctrl+c and ctrl+v )

Or put the Player in a global flap and pull it out and put it into the you want.

These procedures are not well documented at the moment.


Karl





_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

K. K. Subramaniam
On Wednesday 12 Aug 2009 10:20:37 pm Karl Ramberg wrote:
> > First of all, could you explain in more detail what you meant by a
> > "Player". I know that I can use a "Players" tool from the toolbox of
> > the eToy, but I think this is not what you were talking about because
> > I did not see a copy/paste menu on the Players tool.
>
> Every object in Etoys is a Player :-)
> And you are right, there is no copy and paste items in the menus :-(
> I'll look into that.
It is under halo->menu->copy->copy to paste buffer. Press ALT+V in the target
project to paste the morph.

Simpler method is to just drag (or dup) the morph into the Supplies bin,
switch to target project and then *pick* it out into the world. You will get
an iconic button. Click the button to get the morph and trash the button.

If the projects are in different images, then drag-n-drop is simplest.

Subbu
_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

Bert Freudenberg
In reply to this post by Karl Ramberg
On 12.08.2009, at 18:50, Karl Ramberg wrote:

> Every object in Etoys is a Player :-)


More precisely, every Etoys object is made of a player and a costume.  
The player has the scripts, the costume is what's visible on the  
screen. The costume can be changed, but the player stays the same.  
Using tiles you really interact with the player, which causes the  
costume to be moved, for example.

This distinction is only necessary to understand for some advanced  
uses. In the beginning it's fine to only talk about "objects". Later,  
the concepts of players and costumes can be introduced.

- Bert -


_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

Karl Ramberg
In reply to this post by K. K. Subramaniam
On 2009-08-12 19:16, K. K. Subramaniam wrote:

> On Wednesday 12 Aug 2009 10:20:37 pm Karl Ramberg wrote:
>    
>>> First of all, could you explain in more detail what you meant by a
>>> "Player". I know that I can use a "Players" tool from the toolbox of
>>> the eToy, but I think this is not what you were talking about because
>>> I did not see a copy/paste menu on the Players tool.
>>>        
>> Every object in Etoys is a Player :-)
>> And you are right, there is no copy and paste items in the menus :-(
>> I'll look into that.
>>      
> It is under halo->menu->copy->copy to paste buffer. Press ALT+V in the target
> project to paste the morph.
>
> Simpler method is to just drag (or dup) the morph into the Supplies bin,
> switch to target project and then *pick* it out into the world. You will get
> an iconic button. Click the button to get the morph and trash the button.
>
> If the projects are in different images, then drag-n-drop is simplest.
>    
Copy is not there when the Etoys friendly preference is on.
There is also no paste item in any menu.

Karl


_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

dcorking
In reply to this post by K. K. Subramaniam
Subbu wrote:

> If the projects are in different images, then drag-n-drop is simplest.

I can't drag and drop between two images on my Mac.  Is there a
preference or a VM setting I need?  (Ctrl-c hides the sugar flap, and
cmd-c and cmd-v copy and paste text for me, not morphs.)
_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

K. K. Subramaniam
On Thursday 13 Aug 2009 2:02:25 am David Corking wrote:
> Subbu wrote:
> > If the projects are in different images, then drag-n-drop is simplest.
>
> I can't drag and drop between two images on my Mac.  Is there a
> preference or a VM setting I need?  (Ctrl-c hides the sugar flap, and
> cmd-c and cmd-v copy and paste text for me, not morphs.)
Drag-n-drop not working on a Mac but working in Linux is weird. Usually it is
the other way around :-).

That leaves only using Flaps as intermediate containers as a multiplatform
option.

Subbu
_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

Timothy Falconer-3
In reply to this post by Karl Ramberg
On Aug 11, 2009, at 3:41 PM, Karl Ramberg wrote:

> On 2009-08-11 18:44, Young-Jin Lee wrote:
>> Hi,
>>
>> I am looking for a way to export a script in one project so that it  
>> can be used in another project. I looked for contextual menus and  
>> googled it, but found no solution yet. Can anyone tell me if it is  
>> possible?
>>
>> Also, I have another question about using a movie file in etoy. In  
>> one of the demo projects that comes with etoy (a free-fall  
>> experiment), I found a set of JPEG images imported from a movie  
>> file. Does etoy can save selected frames from a movie as image  
>> files? If not, what is the best way to create image files from a  
>> movie file so that they can be used in etoy?
>>
>> Thank you so much!!!
> Scripts are a part of a Player and you bring it along when you for  
> example copy and paste a Player. ( ctrl+c and ctrl+v )
>
> Or put the Player in a global flap and pull it out and put it into  
> the you want.
>
> These procedures are not well documented at the moment.


Can someone add this to the wiki "Secrets" page?

http://wiki.squeakland.org/display/sq/Secrets


Moving forward, please add helpful tips as you find them there, until  
we have a clearer place to put them.

Thanks,
Tim

_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

Karl Ramberg
On 2009-08-31 17:17, Timothy Falconer wrote:

> On Aug 11, 2009, at 3:41 PM, Karl Ramberg wrote:
>
>> On 2009-08-11 18:44, Young-Jin Lee wrote:
>>> Hi,
>>>
>>> I am looking for a way to export a script in one project so that it
>>> can be used in another project. I looked for contextual menus and
>>> googled it, but found no solution yet. Can anyone tell me if it is
>>> possible?
>>>
>>> Also, I have another question about using a movie file in etoy. In
>>> one of the demo projects that comes with etoy (a free-fall
>>> experiment), I found a set of JPEG images imported from a movie
>>> file. Does etoy can save selected frames from a movie as image
>>> files? If not, what is the best way to create image files from a
>>> movie file so that they can be used in etoy?
>>>
>>> Thank you so much!!!
>> Scripts are a part of a Player and you bring it along when you for
>> example copy and paste a Player. ( ctrl+c and ctrl+v )
>>
>> Or put the Player in a global flap and pull it out and put it into
>> the you want.
>>
>> These procedures are not well documented at the moment.
>
>
> Can someone add this to the wiki "Secrets" page?
>
> http://wiki.squeakland.org/display/sq/Secrets
>
>
> Moving forward, please add helpful tips as you find them there, until
> we have a clearer place to put them.
>
> Thanks,
> Tim
>
>
I put it here:
http://wiki.squeakland.org/display/sq/Documentation

Karl

_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: [Q] How to export a script

Timothy Falconer-3
On Aug 31, 2009, at 1:44 PM, Karl Ramberg wrote:

> On 2009-08-31 17:17, Timothy Falconer wrote:
>> On Aug 11, 2009, at 3:41 PM, Karl Ramberg wrote:
>>
>>> On 2009-08-11 18:44, Young-Jin Lee wrote:
>>>> Hi,
>>>>
>>>> I am looking for a way to export a script in one project so that  
>>>> it can be used in another project. I looked for contextual menus  
>>>> and googled it, but found no solution yet. Can anyone tell me if  
>>>> it is possible?
>>>>
>>>> Also, I have another question about using a movie file in etoy.  
>>>> In one of the demo projects that comes with etoy (a free-fall  
>>>> experiment), I found a set of JPEG images imported from a movie  
>>>> file. Does etoy can save selected frames from a movie as image  
>>>> files? If not, what is the best way to create image files from a  
>>>> movie file so that they can be used in etoy?
>>>>
>>>> Thank you so much!!!
>>> Scripts are a part of a Player and you bring it along when you for  
>>> example copy and paste a Player. ( ctrl+c and ctrl+v )
>>>
>>> Or put the Player in a global flap and pull it out and put it into  
>>> the you want.
>>>
>>> These procedures are not well documented at the moment.
>>
>>
>> Can someone add this to the wiki "Secrets" page?
>>
>> http://wiki.squeakland.org/display/sq/Secrets
>>
>>
>> Moving forward, please add helpful tips as you find them there,  
>> until we have a clearer place to put them.
>>
>> Thanks,
>> Tim
>>
>>
> I put it here:
> http://wiki.squeakland.org/display/sq/Documentation
>
> Karl

Thanks Karl ... great screencast.

Tim

>

_______________________________________________
squeakland mailing list
[hidden email]
http://lists.squeakland.org/mailman/listinfo/squeakland