Home News Features Games Authoring Community Forums About Contact
   

May 22, 2013, 07:14:52 AM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
 
   Home   Help Search Login Register  
Pages: 1 2 [3] 4
  Print  
Author Topic: Movies?  (Read 6020 times)
BigMc
SLUDGE Linux/GTK+ Maintainer
Sr. Member
****
Offline Offline

Posts: 266



« Reply #30 on: February 06, 2011, 11:10:05 AM »

I think it would mean using libavformat instead of libwebm for the container handling and libavcodec instead of libvpx for the decoding. The difference is not only the different decoder, but the FFmpeg libraries also support much more formats.
Logged
Trumgottist
Maker of SLUDGE
Longtime Member
*****
Offline Offline

Gender: Male
Posts: 1162



WWW
« Reply #31 on: February 06, 2011, 11:20:29 AM »

But the additional formats won't be exposed to SLUDGE games (and wouldn't have to be compiled into the engine either if I've read things right). Best to stick with a single, well defined format to avoid trouble and confusion. (Not to mention any format licensing issues.)
Logged

"Programming is the computer game that makes all others possible." - Ron Newcomb
xenogia
Jr. Member
**
Offline Offline

Posts: 87


« Reply #32 on: February 09, 2011, 12:03:08 AM »

??

Okay.  Anyway, would the WebM format be easier to implement that libavcodec?
Logged
Trumgottist
Maker of SLUDGE
Longtime Member
*****
Offline Offline

Gender: Male
Posts: 1162



WWW
« Reply #33 on: February 12, 2011, 11:39:14 AM »

Here's what I'm working on:

Three functions, as simple as possible.

playMovie('moviefile.webm');

Plays a movie, fullscreen. (Well, full window if the game running windowed.) The function does not return, and no other graphics are drawn, until the movie is finished, or stopped.

stopMovie();

Stops any playing movie immediately. Nothing happens if no movie is playing.

pauseMovie();

Pauses a playing movie, or resumes a paused movie.

--

This would allow a game to do something like this:
Code:
sub movieClick() {
pauseMovie();
}
sub movieKeys(k) {
if (k == "ESCAPE") stopMovie();
if (k == " ") pauseMovie();
}

sub doCutscene(movie) {
onLeftMouse (movieClick);
onKeyboard (movieKeys);
onRightMouse (movieClick);

playMovie(movie);

# Return to normal
go();
}


doCutscene('intro.webm');



Thoughts?
« Last Edit: February 12, 2011, 11:45:28 AM by Trumgottist » Logged

"Programming is the computer game that makes all others possible." - Ron Newcomb
BigMc
SLUDGE Linux/GTK+ Maintainer
Sr. Member
****
Offline Offline

Posts: 266



« Reply #34 on: February 12, 2011, 01:44:18 PM »

There is cacheSound, so would it be useful to also have a corresponding function for movies or is that not necessary? Depending on how playMovie works, cacheMovie could just load the beginning of the movie to memory to ensure a smooth start of the movie.
Logged
Trumgottist
Maker of SLUDGE
Longtime Member
*****
Offline Offline

Gender: Male
Posts: 1162



WWW
« Reply #35 on: February 12, 2011, 03:16:34 PM »

It's streaming from the hard drive anyway, and not loading everything into memory at once, so I'm not expecting that to be an issue. Even DVDs movies, who live on a slower medium, play instantly.

(If you try to run a game over a network, everything will lag. I've done that, running a game that lives on my other computer. SLUDGE is not designed for that.)
Logged

"Programming is the computer game that makes all others possible." - Ron Newcomb
BigMc
SLUDGE Linux/GTK+ Maintainer
Sr. Member
****
Offline Offline

Posts: 266



« Reply #36 on: February 12, 2011, 03:29:12 PM »

Yes, but there is a buffer and the video only starts after a certain amount is buffered. I'm talking about that first bit. But if it should be necessary you can still add it later.
Logged
xenogia
Jr. Member
**
Offline Offline

Posts: 87


« Reply #37 on: February 13, 2011, 03:52:55 AM »

Could you add a function where as to keep the background music playing while a video file is playing?
Logged
Trumgottist
Maker of SLUDGE
Longtime Member
*****
Offline Offline

Gender: Male
Posts: 1162



WWW
« Reply #38 on: February 13, 2011, 03:59:11 AM »

Sound will continue unless you stop it yourself.
Logged

"Programming is the computer game that makes all others possible." - Ron Newcomb
xenogia
Jr. Member
**
Offline Offline

Posts: 87


« Reply #39 on: February 13, 2011, 05:19:26 PM »

That is perfect then Smiley
Logged
Igor Hardy
Member
***
Offline Offline

Posts: 164



WWW
« Reply #40 on: February 13, 2011, 05:37:27 PM »

Oh, I didn't realize you are transferring Face of Corruption to SLUDGE, xenogia. But that's probably the right choice for a FMV game. I've still didn't get around setting that codec to run Phoenix01 and handling movie files seem like a bit of a problem in AGS in general.
Logged

A Hardy Developer's Journal -  indie games/animation design, development & appreciation
xenogia
Jr. Member
**
Offline Offline

Posts: 87


« Reply #41 on: February 13, 2011, 05:50:34 PM »

Hey Igor,

The main reasons why I changed to Sludge was due to resolution limitations and it's multi-platform aspect.  And also to be fair I filmed the game at a much higher res than AGS handles.  I've also come across a few other issues such as sound-stutters as well which has hindered the development a bit as well.
Logged
Trumgottist
Maker of SLUDGE
Longtime Member
*****
Offline Offline

Gender: Male
Posts: 1162



WWW
« Reply #42 on: March 01, 2011, 06:05:13 PM »

I'm making progress… I'm now able to see my movie in my test game. (I've already uploaded the source to my test game, but you can't compile it or play it until SLUDGE 2.1 is released.)

No sound yet, and no colour yet, but unless I hit a stumbling block I should be able to have WebM playback working in SLUDGE within a week. I hope to get SLUDGE 2.1 out before "Pie Day".
Logged

"Programming is the computer game that makes all others possible." - Ron Newcomb
BigMc
SLUDGE Linux/GTK+ Maintainer
Sr. Member
****
Offline Offline

Posts: 266



« Reply #43 on: March 01, 2011, 06:27:10 PM »

It also works for me so far.

EDIT: What and when is Pie Day?
Logged
Trumgottist
Maker of SLUDGE
Longtime Member
*****
Offline Offline

Gender: Male
Posts: 1162



WWW
« Reply #44 on: March 01, 2011, 06:42:22 PM »

Good to hear.

Pi Day is March 14, and also the release date for Life Flashes By.
Logged

"Programming is the computer game that makes all others possible." - Ron Newcomb
Pages: 1 2 [3] 4
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.8 | SMF © 2006-2008, Simple Machines LLC Valid XHTML 1.0! Valid CSS!
 
Unauthorised reproduction of anything on this website is not allowed without our written consent.
Materials on this site are the property of their respective owners. Copyright © Adventure Developers. All rights reserved.