Author |
Message |
Amodeus
|
Posted: Mon Oct 22, 2007 8:53 am Post subject: Is there a way to inport movies... |
|
|
Hey,
Is there a known way how to inport movies into Turing?
Thanks,
Amodeus |
|
|
|
|
![](images/spacer.gif) |
Sponsor Sponsor
![Sponsor Sponsor](templates/subSilver/images/ranks/stars_rank5.gif)
|
|
![](images/spacer.gif) |
Mazer
![](http://compsci.ca/v3/uploads/user_avatars/1323750815476d9f446d80c.png)
|
Posted: Mon Oct 22, 2007 10:15 am Post subject: RE:Is there a way to inport movies... |
|
|
Not a terribly good way, but you can use some method to split the movie up into frames (a shitload of frames) and save each as an image. Then in your program load each image (if it's really short. if there are alot of frames you'll have to load a few at a time and free the old ones as you go) and display each at ~23 frames per second (so, around 0.04seconds for each frame).
Short answer: it's not really worth it. |
|
|
|
|
![](images/spacer.gif) |
Nick
![](http://compsci.ca/v3/uploads/user_avatars/19644337547e837b41d67a.png)
|
Posted: Mon Oct 22, 2007 2:05 pm Post subject: RE:Is there a way to inport movies... |
|
|
the answer (other than MAZER's) is yes and no...
yes: u can use turing to play movies
no: it will not be in a turing window but rather the media player of choice (well not choice but the one that is set to play with the file extension)
heres what u do
Sys.Exec("movie file path")
and thats it but its not that cool if u wanna have a cutscene in a game cause it will open something else and the player will be all like "wtf?" |
|
|
|
|
![](images/spacer.gif) |
Tony
![](http://wiki.compsci.ca/images/f/f4/OniTony.gif)
|
Posted: Mon Oct 22, 2007 3:29 pm Post subject: RE:Is there a way to inport movies... |
|
|
Constructing your own movie, frame by frame, is essentially the best way to do it with Turing. I think the latest version of Turing implements .gif images, possibly animated, though it's a bit of a mess.
Forces has a CG quality "cut scene" playing in the background of the title menu. It's done with a series of .jpeg frames.
Keep in mind that you can't have more than 1000 pictures loaded. You can easily get to those numbers from a 30 second clip -- so don't forget to Pic.Free |
Tony's programming blog. DWITE - a programming contest. |
|
|
|
![](images/spacer.gif) |
Dan
![](http://wiki.compsci.ca/images/archive/3/3c/20100325043407!Danspic.gif)
|
Posted: Mon Oct 22, 2007 3:29 pm Post subject: RE:Is there a way to inport movies... |
|
|
You can also read the documentation on the video file format and what codec it used and make a program that will play it for real.
This is alot of work, but i have seen it done in turing befor. However the score code was never given out to my knowagle, so you whould have to start from scartch. |
Computer Science Canada
Help with programming in C, C++, Java, PHP, Ruby, Turing, VB and more! |
|
|
|
![](images/spacer.gif) |
Nick
![](http://compsci.ca/v3/uploads/user_avatars/19644337547e837b41d67a.png)
|
Posted: Mon Oct 22, 2007 4:12 pm Post subject: RE:Is there a way to inport movies... |
|
|
well i think Dan just gave me my next project ![Razz Razz](http://compsci.ca/v3/images/smiles/icon_razz.gif) |
|
|
|
|
![](images/spacer.gif) |
Amodeus
|
Posted: Mon Oct 22, 2007 7:03 pm Post subject: Re: Thanks |
|
|
Thanks! I know what to do know |
|
|
|
|
![](images/spacer.gif) |
Amodeus
|
Posted: Sun Oct 28, 2007 10:28 pm Post subject: Re: Is there a way to inport movies... |
|
|
I tried the Sys.Exec thing and it's not working... I get the "Expression is not a procedure and hence cannot be called" error. This is how I typed it: Sys.Exec("DC_Versus_Marvel.wmv")
I'm also certain that's the exact file name, I tried it with the full directory path thing and it gave me the same error. |
|
|
|
|
![](images/spacer.gif) |
Sponsor Sponsor
![Sponsor Sponsor](templates/subSilver/images/ranks/stars_rank5.gif)
|
|
![](images/spacer.gif) |
Nick
![](http://compsci.ca/v3/uploads/user_avatars/19644337547e837b41d67a.png)
|
Posted: Sun Oct 28, 2007 10:42 pm Post subject: RE:Is there a way to inport movies... |
|
|
what version are you running? |
|
|
|
|
![](images/spacer.gif) |
Clayton
![](http://compsci.ca/v3/uploads/user_avatars/1718239683472e5c8d7e617.jpg)
|
Posted: Sun Oct 28, 2007 10:47 pm Post subject: RE:Is there a way to inport movies... |
|
|
That would be because Sys.Exec() isn't a procedure. Instead, it is a function that returns a boolean result. F10 is your friend in these matters. |
|
|
|
|
![](images/spacer.gif) |
Nick
![](http://compsci.ca/v3/uploads/user_avatars/19644337547e837b41d67a.png)
|
Posted: Sun Oct 28, 2007 10:55 pm Post subject: RE:Is there a way to inport movies... |
|
|
clayton thats right
so here is what the code should look something like
Turing: | if not Sys.Exec("movie") then
put "movie not played"
end if |
|
|
|
|
|
![](images/spacer.gif) |
|