FMVs => just a thought

Discuss the future of Warzone 2100 with us.
User avatar
kage
Regular
Regular
Posts: 751
Joined: 05 Dec 2006, 21:45

Re: FMVs => just a thought

Post by kage »

ogg supports any kind of linear bitstream, actually... technically, you could stream game packets through ogg for multiplayer, and it could work, though it'd be stupid to do so, for obvious reasons.

well... i don't know about the "ogg video must contain video audio and sub streams" thing... also, a/v sync might be something of a (dare i say) bitch if you're actually having seperate files for audio and video, much less subtitles, since some things you can assume with streams contained within a single file can't be assumed for seperate files. with the seperate files thing to work in sync, you'd need some kind of timing index to say which byte in each file corresponds to a given hard point in time, in which case you must stop any each stream as it gets to any given index until all streams have caught up -- ogg does a bit of this for you, iirc.

i think what might be cleaner is something like:

Code: Select all

sequence1 = {
file=s1.ogg
audio=stream1
video=stream0
subtitles=stream2
}
or, if we give each stream a meaningful title:

Code: Select all

sequence1 = {
file=s1.ogg
audio="en"
video="main"
subtitles="de"
}
seperate files are probably doable, and i'm not a dev, but based on what i've seen, the amount of code it'd take to deal with certain kinds of syncing, perhaps changing wzsub so it's indexable, and a few other things might make it simply easier to force modders making high res versions to include duplicates of the subtitle and audio streams found in the originals (if done right, this adds up to *maybe* 2.5 mB of data for language-specific audio streams and subtitles for each of the longer videos, such as the intro). beyond that, the prospect of having several audio streams (one for each supported language) isn't so bad if you consider speex: speex goes well with ogg (made by the same people), should have an api that's very similar to vorbis, and is designed specifically for voice compression -- i doubt if it'd have any use if there were only one language supported for a movie, but it would probably make a huge difference if you had 5 or 6 language streams encoded in speex to go along with a single combined sound-effects/ambient-audio/music vorbis stream, because speex can encode voices with the same quality as ogg, but at much lower bit rates (a test i did just now required vorbis to encode voice with an average bitrate of 50 Kbps [anywhere from 40 Kbps to 65 Kbps at any point] to match the audible quality of the original wav file, while speex was able to match the original quality at exactly 27 Kbps, though the average user probably wouldn't notice any grave imperfections if the speex sample was encoded at 18 Kbps).

on a side note, i think it'd be good to set some standards for the way each stream is documented: specifically, any language-specific stuff should have the iso code, or perhaps the native name for the language in a specific place in the stream headers, so that the user doesn't have to specify their language on a per-video basis, but can do it all in one place. for example, if i wanted to use german text throughout the game, but wanted english audio, i might have the following in my user config:

Code: Select all

lang_text=de
lang_audio=en
and instead of having a monolithic file containing metadata for each sequence in the game (not to say that dev was suggesting so), those could be contained within level-specific stuff, or perhaps within the ogg itself, allowing for easy and flexible mod overrides (someone could use a "high-res alpha campaign videos" mod with a "high-res gamma campaign videos" mod without requiring any hand-tweaking on the user's part, and it'd automatically use the low-res beta campaign videos.
User avatar
Hatsjoe
Trained
Trained
Posts: 285
Joined: 20 Feb 2007, 19:57

Re: FMVs => just a thought

Post by Hatsjoe »

kage wrote: also, with ffmpeg2theora, i'd recommend that you use an uncompressed video as the source, as quality could go *way* down if you convert from one compression format to another with radically different compression techniques.
Yes, that's exactly what i was trying to avoid by using virtualdubmod to compress the loose video frames (in bitmap format) to og(gm) directly. Every thing went just fine but when i tried the created files, they would just not play. Every media player i've tried just crashed when trying to open the files. even those that were in particular build to play og(gm). that leaves me just one option: converting the loose frames into a lossless videofile and afterwards compressing to OGG using mpeg2theora. If all goes right, i ll be able to deliver the first 3 movies later this evening :d
Image
User avatar
DevUrandom
Regular
Regular
Posts: 1690
Joined: 31 Jul 2006, 23:14

Re: FMVs => just a thought

Post by DevUrandom »

That makes sense, kage...
Especially the audio/video sync part of your essay convinced me that this is not desirable.
My "metadata" stuff was really only useful in case you wanted multiple files for a single sequence.

The subtitle "problem" seems to need a little more thought than I initially invested, though. So ogg apparently supports some kind of subtitle streams (couldn't find much info on that in the net, besides some dev discussion how to implement it). It could be used and supports different languages etc.
The "problem" arrises when someone wants to override only the subtitles (or wants to provide them in his language).
What I am currently thinking of is that Warzone searches for the subtitle in the specified language in the movie.ogg and if it can't find it there, it uses movie.txt instead (format eg. like this: http://forum.videolan.org/viewtopic.php?t=32652). Optionaly: If that file doesn't exist either, it uses the default subtitle stream if present.

Another unrelated idea I just got:
What is currently (or does that belong to your patch, Gerard?) in the subtitle files could possibly be managed by the scripting language. (Setting up audio to play, images to show and so on.)
gerard_
Trained
Trained
Posts: 71
Joined: 02 Nov 2006, 19:56

Re: FMVs => just a thought

Post by gerard_ »

My current files look like:
(data/sequences/devastation.seq)

Code: Select all

SCENE	"Dusk, November 3rd, 2085"

		"Earth, High Orbit"

		"The Collapse"
IMAGE	"texpages/bdrops/00-bdrop.jpg"

TEXT "The NASDA system was developed to protect us. It was to be the ultimate nuclear deterrent. As it turned out, it was our executioner."
TEXT "Reports said that NASDA developed a fault during a routine systems check. Don't believe it. Someone wanted it to take us out."
TEXT "Those nukes were targeted on every major city around the world. NASDA was programmed to start the Collapse. When the counterstrikes launched, its laser defenses and anti-missile ground sites failed." 

SCENE	"January 19th, 2086"

		"North America"

		"Nuclear Winter"

IMAGE	"images/stills/collapsed_snow.jpg"
COPYRIGHT "Photo by hodge (Flickr)"

TEXT "The world as we knew it ended..."
TEXT "The Nuclear Winter hit hard. Disease and famine claimed most of us who had survived the nuclear strikes. Wars over cans of dog food took even more."

SCENE	"Midnight, April 10th, 2086"

		"Rocky Mountains"

		"Safety"
IMAGE	"images/stills/bunker.jpg"
COPYRIGHT "Photo by Whitney GH (Flickr)"

TEXT "We'd fled Seattle early in '86. We'd heard that the Rocky Mountains were relatively rad-free."
TEXT "After fighting off bands of marauders we came across the base. Its personnel were dead. Killed by any one of a number of virulent diseases."
TEXT "We cracked the doors, and cleared out the bodies inside."

SCENE	"Dawn, April 4th, 2100"

		"North America"

		"A New Beginning"
IMAGE	"texpages/bdrops/01-bdrop.jpg"
TEXT "We knew that things would never be the same again, but we were determined to build a new world out of the ruins. We rebuilt the landing pads and brought the old systems back on-line."
TEXT "We were finally ready to begin the Project."
but it also occurred to me that we would like to be able to have in game cut-scenes etc.
A scripting language like python or lua would have to be used then, so why not use it in the first place?

We now need someone to plug a scripting language into Warzone. If someone wants lua as scripting language, better implement it fast, because my choice would be python. ;)
User avatar
DevUrandom
Regular
Regular
Posts: 1690
Joined: 31 Jul 2006, 23:14

Re: FMVs => just a thought

Post by DevUrandom »

You know I can't do it atm... So this a little bit unfair...
Besides of that: We allready have a scripting language. According to Troman it is also quite powerful. Maybe we can use this for the moment.
User avatar
kage
Regular
Regular
Posts: 751
Joined: 05 Dec 2006, 21:45

Re: FMVs => just a thought

Post by kage »

hmmmm... i was (mistakenly) under the assumption that the meta-data stuff was for specifying user-configurable overrides (so that the user could choose which audio to listen to, or whatnot). i hadn't even thought about the possibility of multiple files representing one logical cutscene: i can definitely see the use of that for various mod attempts (such as branching campaigns that may mix and piece together mini-movies based on where the story is flowing). i think that's a really excellent idea to allow for logical chaining like that, and since, no matter what, we have to specify the filename of at least one movie to play it for any "logical sequence", it's just as easy that we build in support for the possibility of an arbitrary number of movies representing a single sequence.

in regards to subtitles in ogg: most of the stuff related to ogg is beta or lower (theora is alpha, the subtitle stuff is also alpha, vorbis is stable but many vorbis encoders are in beta), so i can't vouch for their usability, though for alpha quality, theora (and the rest of the xiph.org stuff) tends to be beta+ quality from what i've seen. however, writ, though highly unstable (in regards to the specification -- in working draft), is being designed with forward compatibility (and thus backwards compatibility) in mind, and thus might be worth looking at if and when it becomes officially accepted by xiph. it supports multiple languages within a single stream (useful, but for us, it generally only means it's faster to grab bits out of the stream when compared to one subtitle stream for each language), metadata such as x/y position on screen and text size/stretching (both of which we can ignore since it's probably more effort to implement during the render than any of us want to tackle), duration of message (much much nicer than most other implementations which persist any given message until the next one comes up), and some other stuff we'd probably never find useful for warzone. note: afaik, there's not currently a decoder for writ (only an experimental encoder written in/for python), so, as said, it'd be something to keep an eye on, rather than something to look at for immediate implementation -- my hope is that, because it's far superior to most stand-alone subtitle formats (and at least has the synch'ing capabilities that aren't present in any external formats), it'll stabilize and be usable before our subtitles are frozen in external files, as much for the wz dev's sake as anything else, since dealing with it as an ogg stream will be signifigantly simpler than trying to patch together some home-grown best-guess audio/subtitle sync that would triple the amount of code that should be necessary.

i see your point in regards to something like movie.txt -- i don't know how you'd want to tackle it's implementation, but i see your point.

also, another thought: is anyone thinking about multi-language support in the gameplay voice-over level (such as the dialogue you hear when you give units certain kinds of actions, or select a given group)? if we have any interest in doing so, we could conceivably encode multiple languages as seperate streams into the same audio file, or have some kind of language-centric sub-tree in the .wz archives (this one's going to be easier to implement in code, is easier to encode, and doesn't require re-encoding every time we decide to support a new language, but requires some forethought on the .wz internal directory structure).
r34ch
Greenhorn
Posts: 15
Joined: 19 Mar 2007, 20:55

Re: FMVs => just a thought

Post by r34ch »

I have a suggestion, I think people may be setting their goals a bit too high here so I propose a simple but effective solution

Create a still image in photoshop, simply a black screen with green text showing the game story and listing the objects of the mission clearly below, that way every FMV only needs a 'frame' like this

(I presume the game can only run cut scene moves rather than simply display a paragraph of text-then that way would be easier).

Then simply use Premier Pro or something to convert the 'still frame' into a proper cut scene, simply have it play for 20sec's so that the reader can read the text, or, if the game permits the FMV's to be frozen at their last frame when they've stopped, simply create a split-second long render of each 'frame' and since the FMV is frozen (i.e. like hit Esc or Enter to play next/exit] it would simply show the mission details and a bit of the story line without taking up too much room in terms of size on HD

Seems a far better way to me, get three people to type every mission from each campaign(or copy and paste the scripts if someone can find them), then some people to render the still image to short cut scenes, and finally stick them in game.

It could be done in a few days; Text write up-rendering-game implementation.

I'd personally like to see this implemented rather than waiting a year for some FMV's. It'd be amazing to see some nice FMVs i admit (i.e. A nice rendered Into would be really nice, and if people get time then the separate campaign intros and finally an ending) but I would rather be greeted with a basic screen showing me the information than waiting a year for some nice FMVs and putting up with the blank FMVs until then...

Sounds like people want to go to the trouble of implementing new scripting languages...
To be honest from other projects I've seen, once people get an idea in their head, a good idea, they expand on it, uncontrollably, until they reach a stage where the proposed idea takes years to complete (by then no one is interested in it) they give up completely (waste months on getting nowhere) or go half way (get tired of it and leave it incomplete buggy etc)

Even if this idea was a place holder, it would keep people in the loop who have never played before. I mean it couldn't take that long to implement and would do until proper FMV's are done

but just my two cents...
User avatar
kage
Regular
Regular
Posts: 751
Joined: 05 Dec 2006, 21:45

Re: FMVs => just a thought

Post by kage »

i believe you have a good idea, though by no means do i think we should "slow down" making the fmv's (if that's what you meant): we've got momentum here, and hatsjoe has actually done what no one else in this community has *ever* done in regards to the video sequences, which is to do something instead of just talking about it, and has shown that he is both skilled and determined, so the absolute worst thing we can do is give him, or anyone else that is, or is considering helping with this effort any reason not to, or else the effort will be abandoned, and those movies you admit to having thought would be cool would never get done.

instead, i believe we should encourage them to continue working on the full-motion cutscenes while forming a second team, that does as r34ch suggests, and create images that display the briefing, since, some users may outright prefer this to a movie, but more importantly, as r34ch said, we can indeed get these done in much shorter time and with fewer people than it'd take to finish all of the movies. however, i don't believe they should end up as a normal movie, but rather should use the mechanism (or a modification of it) currently used to display the textual briefings for the following reasons: you can't assume that everyone will be able to read any given piece of text in a certain amount of time, as we have a lot of non-native english players (and presumably some who don't speak/read english at all), while at the same time, we have players who be waiting 12 seconds for a briefing to finish every time. the current mechanism allows you to skip to new frames at will, and it may even have image support. if it does, indeed have both image support and text-rendering support, then we should use that, as it would allow us to use the same "backdrop" for all languages.

also, having *both* briefing mechanisms available (video and direct support for the current system) would make it much easier on modders, who could implement briefings with little difficulty, and still be given a much cleaner alternative to creating a regular movie consisting of "stills", which are often needlessly encoded to be several mb larger than a tar of the stills themselves.

there is probably a way to get still frames to work cleanly in an ogg movie: if utilize a comment field in the ogg that could be used to indicate the movie contained stills, we could have our built-in player, upon recognizing this type of movie, play only one frame -> wait for a mouse click -> repeat, which could allow us to simply our briefing system significantly. on the other hand, such a system wouldn't allow for sound contained within the ogg to be played without severely violating the assumptions set forth by the ogg spec, and so any sound streams should be entirely ignored in such an implementation (i don't believe the current textual briefing system supports sounds, though), but we could just as easily play background music during movie playback in such a case.
r34ch
Greenhorn
Posts: 15
Joined: 19 Mar 2007, 20:55

Re: FMVs => just a thought

Post by r34ch »

lol no i didn't mean slow down, i thought you all where still discussing ideas and hadn't actually started, if you have and are going strong then that's great! don't stop! I simply see too many mod forum threads about ideas and no one starts into the work and so the idea perishes, I'd hate to see that happen to this project.

Also the only reason I suggested the rendered clip idea was that i wasn't sure if the game was able to simply display text for each mission, I think i mention very briefly that if it did then that would be the problem sorted (or meant to say) I agree that displaying it as text would save even more trouble - time, multi language support, file size etc

but anyway, I see you lot know what you are talking about so good luck then!
User avatar
Hatsjoe
Trained
Trained
Posts: 285
Joined: 20 Feb 2007, 19:57

Re: FMVs => just a thought

Post by Hatsjoe »

Jeej, i ve almost finished the collective comms movie. It still needs some finetuning but since i didn't just remodel the original, i have to make sure you all like it before i put to much time in high quality renders etc. I'm gonna try to have chojun upload it by tomorrow so you can let me know what you think of it. This 13  sec. one was a bit more complex to animate and model but i m pretty happy with the result. Just have to add a little more detail and adjust some of the effects. Hope you gonna like it :)
Image
User avatar
DevUrandom
Regular
Regular
Posts: 1690
Joined: 31 Jul 2006, 23:14

Re: FMVs => just a thought

Post by DevUrandom »

Don't you have FTP access here?
Kamaze
Regular
Regular
Posts: 1017
Joined: 30 Jul 2006, 15:23

Re: FMVs => just a thought

Post by Kamaze »

We all have the same heaven, but not the same horizon.
User avatar
Hatsjoe
Trained
Trained
Posts: 285
Joined: 20 Feb 2007, 19:57

Re: FMVs => just a thought

Post by Hatsjoe »

I thought it wasn't nesecairy for just the comms movies, But since i'm pretty determined to do more than just the comms, you re probably right about the FTP thingy. So if someone can set it up and tell me how to use it, i ll start making use of it. sry for my stuborness before... :s :)
Image
Giel
Regular
Regular
Posts: 725
Joined: 26 Dec 2006, 19:18
Contact:

Re: FMVs => just a thought

Post by Giel »

kage wrote: if it does, indeed have both image support and text-rendering support, then we should use that, as it would allow us to use the same "backdrop" for all languages.
Backdrops are AFAIK already supported, selecting a different one for each briefing could be a trivial task.
kage wrote: (i don't believe the current textual briefing system supports sounds, though), but we could just as easily play background music during movie playback in such a case.
Nope it does not support briefing through sound (e.g. a voice explaining the mission). Implementing background music, however, would be a non-trivial task as well. I.e. it wouldn't be much easier than implementing the briefing "voice" (in case of the background music you could constantly play the same track, in case of the "voice" you would have to play a different one for each briefing).
"First make sure it works good, only then make it look good." -- Giel
Want to tip/donate? bitcoin:1EaqP4ZPMvUffazTxm7stoduhprzeabeFh
User avatar
lav_coyote25
Professional
Professional
Posts: 3434
Joined: 08 Aug 2006, 23:18

Re: FMVs => just a thought

Post by lav_coyote25 »

Giel wrote: Backdrops are AFAIK already supported, selecting a different one for each briefing could be a trivial task.

Nope it does not support briefing through sound (e.g. a voice explaining the mission). Implementing background music, however, would be a non-trivial task as well. I.e. it wouldn't be much easier than implementing the briefing "voice" (in case of the background music you could constantly play the same track, in case of the "voice" you would have to play a different one for each briefing).
ummmm... i think the tutorial breifing should help you out there... as it is setup to do just that... i am not sure how but each time it gives a task to perform and then when that is done ... it goes to the next task... maybe using that as a base for the rest... and it is all voice intructions.

or am i thinking wrongly here? ???
‎"to prepare for disaster is to invite it, to not prepare for disaster is a fools choice" -me (kim-lav_coyote25-metcalfe) - it used to be attributed to unknown - but adding the last bit , it now makes sense.
Post Reply