On 9/15/2014, 7:13 AM, Beat Cornaz wrote:
I want to have the clip inside a visible player. In that way I have
more control over how to play the clip. E.g. visibly nudging back a
bit, changing the play speed, seeing at what time the clip is so I
can mark it, etc. So I need to load the clip into a player, but not
from disc, but from inside my stack.
There's no way to play an embedded video in a player object, but there
is a way to work around it. Delete the imported videos from your stack
and then load them into custom properties instead. You can store binary
data in custom properties this way:
set the cThisMovie of this stack to url ("binfile:" & path/to/file)
When you are ready to play a video, write it to the temp folder. You can
get a unique temporary file name using the tempName function. Then set
the player filename to that:
put tempname() into tFilePath
put the cThisMovie of this stack into url ("binfile:" & tFilePath)
set the filename of player 1 to tFilePath
The temp folder content is deleted automatically by the OS during
routine maintenance, but if you want to remove the file yourself
immediately after playback you can:
if there is a file tFilePath then delete file tFilePath
--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode