Movie problems in LiveCode

stgoldberg at aol.com stgoldberg at aol.com
Tue Mar 31 17:14:07 EDT 2015


Yes, Devin, in using your script for Macintosh using LC 6.7 and higher:

set the filename of player 1 to the defaultFolder & "/media/mymovie.mov"

that appears to let the movie show after the standalone is transferred to other Mac or Windows computers.
I thank you for pointing that out. However, with that script, I am now unable to see the movie in the stack prior to creating the standalone. 
Any suggestion for that?  Thanks.

Stephen Goldberg
www.medmaster.net


2015 16:03:58 +0000
From: Devin Asay <devin_asay at byu.edu>
To: How to use
LiveCode <use-livecode at lists.runrev.com>
Subject: Re: Movie problems in
LiveCode
Message-ID:
<FA91918F-9901-491F-BABC-2B2747914907 at byu.edu>
Content-Type: text/plain;
charset="Windows-1252"


On Mar 30, 2015, at 6:00 AM, stgoldberg at aol.com
wrote:

> I do not know why we?re getting such different results. On Mac
version 10.9.5, using LC 7.0.3, if I write the following script in the openCard
handler:
> 
> on openCard
> set the filename of player 1 to
?media/mymovie.mov?
> answer the filename of player 1
> end openCard
> 
>
then, while the movie will show in the player, I get the absolute path as an
answer to the filename, rather than the relative path. This is confirmed by
opening up the movie player property inspector and finding the absolute path in
the fileName field (in my case, /Users/stephengoldberg/Desktop/Script
words/Media/myMovie.mov)

The behavior of player objects vis-a-vis  relative
paths has definitely changed in 6.7 and higher, as detailed in the bug report I
posted a few days back. (http://quality.runrev.com/show_bug.cgi?id=14435). There
is apparently a fix of some kind due out in one of the next builds.

In the
meantime, or perhaps as a best practice, it seems like instead of setting the
players filename property to a relative path (which *should* work but doesn?t),
you should do this:

  set the filename of player 1 to the defaultFolder &
?/media/mymovie.mov?

Or use whatever full file path is appropriate:

  set
the filename of player 1 to specialFolderPath(?Documents?) &
?/media/mymovie.mov?


Interestingly, in my own development work, it turns
out I always use this method, and like Jacque, don?t have the problem Stephen is
reporting. But in my teaching I have often demonstrated the technique of setting
the defaultFolder to say, the parent folder of the mainstack, and setting the
filename property to a relative path, like Stephen does. It was as I was testing
this technique for a recent class that I discovered the change in behavior,
which broke this capability in 6.7.x

Devin


Devin Asay
Office of Digital
Humanities
Brigham Young



More information about the use-livecode mailing list