Getting the height and width of a videoclip

William Ziegler billziegler at mac.com
Sun Jan 17 18:57:35 EST 2010


Thanks Jacqueline and Richard

Any sources for tutorials with sample scripts on setting custom disk  
property to binary data?

bill

William Ziegler wrote:
 > I have a stack that allows teachers and parents to attach videos for
 > students to write sentences about. These videos are created with  
various
 > devices and thus have different heights and widths.  I currently  
store
 > these videos in a default folder, and use a 'Player', which I probe  
for
 > the Height and Width to resize large clips to a set maximum size.
 >
 > Teachers have asked if I could package all the videos into each  
stack to
 > make it easier to send home and/or share lessons with other teachers.
 >
 > I am having a hard time manipulating videoclips with the PLAY  
command as
 > compared to using a 'Player' with external video files.

I'd forget the videoclip idea and stick with players. A common way to
package everything in the same stack is to set a custom property of the
stack to the binary data of the movie on disk. That way it travels with
the stack. When you want to actually play the movie, you write the
custom property to a temporary file on disk, and then load it into a
player object just like you did originally. When you're done with the
movie, delete the temporary file.



More information about the use-livecode mailing list