Forums > Jitter

[bugreport] path reference is not updated by jit.qt.movie

February 4, 2008 | 11:17 am

Hi,

Description:

When I load a movie into jit.qt.movie, delete the movie and read a new movie with the same name from the same location, jit.qt.movie remembers the reference to the previous movie. In other words:
1) load movie.mov into jit.qt.movie,
2) delete movie.mov (move it to trash),
3) create a new movie.mov in the same location
4) load this new movie.mov into jit.qt.movie… it still loads the deleted movie.mov!

Expected behaviour:

When it receives a read message, jit.qt.movie should rebuild the reference to the provided path.

Steps to reproduce are inside this patch:

#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P comment 204 129 271 196617 3) read movie1.mov: still shows movie1 , not movie2!;
#P comment 204 113 345 196617 2) move movie1.mov to trash , rename movie2.mov to movie1.mov;
#P newex 31 96 60 196617 loadmess 1;
#P message 109 96 88 196617 read movie1.mov;
#P user jit.pwindow 108 188 82 62 0 1 0 0 1 0;
#P newex 31 116 57 196617 qmetro 40;
#P newex 109 157 97 196617 jit.qt.movie @vol 0;
#P comment 204 97 100 196617 1) read movie1.mov;
#P comment 31 53 446 196617 This example assumes you have two different movies to test with , movie1.mov and movie2.mov;
#P connect 6 0 3 0;
#P connect 3 0 2 0;
#P connect 5 0 2 0;
#P connect 2 0 4 0;
#P window clipboard copycount 9;

Mac OS 10.4.11, Max 4.6.3, Jitter 1.6.3

I would be happy if someone could confirm. And.. does someone know a way around this?

Mattijs


February 4, 2008 | 6:30 pm

> I would be happy if someone could confirm. And.. does someone know a way around this?
>
> Mattijs
—————————————————-

yes i confirm, i have the same thing happening on my machine .
using the "dispose" message before reloading the movie seems work.


February 5, 2008 | 9:22 am

Quote: (karrrlo) wrote on Mon, 04 February 2008 19:30
—————————————————-

>
> yes i confirm, i have the same thing happening on my machine .
> using the "dispose" message before reloading the movie seems work.

karrrlo!! You’re a hero, dispose works!

I’ve got four words for you. I. love. this. forum. Yeahhhhhhh! :)

Mattijs


February 5, 2008 | 10:16 am

Oh and btw, to cycling 74, as far as I am concerned it wouldn’t be a bad idea to automatically dispose the movie before reading a new one..

Mattijs


February 5, 2008 | 10:30 am

Quote: Mattijs wrote on Tue, 05 February 2008 10:22
—————————————————-
> Quote: (karrrlo) wrote on Mon, 04 February 2008 19:30
> —————————————————-
>
> >
> > yes i confirm, i have the same thing happening on my machine .
> > using the "dispose" message before reloading the movie seems work.
>
> karrrlo!! You’re a hero, dispose works!

no no Obama is a hero (hint hint) :)
>
> I’ve got four words for you. I. love. this. forum. Yeahhhhhhh!
:)

yes you are right , i am getting married with it , honeymoon in a giant max patch :)

> Oh and btw, to cycling 74, as far as I am concerned it wouldn’t be a bad idea to automatically dispose the movie before reading a new one..

you are right about always using "dispose", i will adopt it myself


February 5, 2008 | 1:53 pm

Quote: (karrrlo) wrote on Tue, 05 February 2008 11:30
—————————————————-
> >
> > I’ve got four words for you. I. love. this. forum. Yeahhhhhhh!
> :)
>
> yes you are right , i am getting married with it , honeymoon in a giant max patch :)

You know about this legendary (ahum) performance?

http://www.youtube.com/watch?v=Nc4MzqBFxZE

Mattijs


February 5, 2008 | 3:27 pm

> You know about this legendary (ahum) performance?
>
> http://www.youtube.com/watch?v=Nc4MzqBFxZE
>
> Mattijs
>
—————————————————-

oh yeah
i am glad the uplifting euphoria this forum fills us could be close to that rather then this other legendary (…) video :


April 3, 2008 | 11:54 am

What if the read fails? There’s no way to deal with this internally without screwing something up for someone. Dispose early, dispose often.

jb

Quote: Mattijs wrote on Tue, 05 February 2008 11:16
—————————————————-
> Oh and btw, to cycling 74, as far as I am concerned it wouldn’t be a bad idea to automatically dispose the movie before reading a new one..
>
> Mattijs
—————————————————-


April 3, 2008 | 12:13 pm

Quote: Jeremy Bernstein wrote on Thu, 03 April 2008 13:54
—————————————————-
> What if the read fails? There’s no way to deal with this internally without screwing something up for someone. Dispose early, dispose often.
>
> jb
>

Yep, my patch is a happy disposer now and everything works fine.

Btw maybe it’s an idea to add this to the help file somehow.

Although.. as far as I know, other applications don’t seem to have this issue. I don’t know how they managed to do that but I can imagine the same thing might be applicable for Max?

Mattijs


April 3, 2008 | 1:51 pm

Quote: Mattijs wrote on Thu, 03 April 2008 14:13
—————————————————-
> Quote: Jeremy Bernstein wrote on Thu, 03 April 2008 13:54
> —————————————————-
> > What if the read fails? There’s no way to deal with this internally without screwing something up for someone. Dispose early, dispose often.
>
> Although.. as far as I know, other applications don’t seem to have this issue. I don’t know how they managed to do that but I can imagine the same thing might be applicable for Max?
—————————————————-

Hard to tell. Most apps open a new window when you read a document. In our case, we replace the open file if and only if the read is successful. We can only tell that the read is successful by reading, before we close the open file. This may be an issue with Max’s path cache, but for the time being, there’s kind of nothing to be/that will be done about it.

jb


Viewing 10 posts - 1 through 10 (of 10 total)