Search Unity

Video Intro

Discussion in 'Editor & General Support' started by rant, Jan 4, 2006.

  1. rant

    rant

    Joined:
    Jan 3, 2006
    Posts:
    11
    Is it possible to include a short video intro in a unity game? Like the torque engine function?
     
  2. Joachim_Ante

    Joachim_Ante

    Unity Technologies

    Joined:
    Mar 16, 2005
    Posts:
    5,203
    At the moment it is not possible to pla yback compressed video in unity.
    If the video is short you can play it back but it will not be compressed. For large movies that is of course suboptimal.

    We will add support for compressed video in a later version of unity.
     
  3. bigbrainz_legacy

    bigbrainz_legacy

    Joined:
    Jul 15, 2005
    Posts:
    137
    It will be critical for us to get some kind of video playback by the end of August, so I'm wondering:

    1. Could you please give us us some kind of timeline for video playback?

    2. If it's not going to be doable in the next couple of months, could you please give us some advice on how to rig up something on our own that would work?

    We're thinking to implement some kind of .flv player. The .flv format has the best compression we know of, and the Flash player is by far the smallest and most common.

    (I know there are folks on this forum that get pretty excited about Flash functionality in general, or Quicktime or Windows Media Player, but for now we just need a video solution that doesn't burden either Mac or PC users with downloading the correct player. We want to just ship everything they need with the game, and adding 16+ MBs to every download is unacceptable both in terms of size and annoyance).

    Rather than a 16+ MB install that would be required for full-blown Quicktime or WMP, the external .flv players I've used from http://www.flvplayer.com/ are teeny tiny, and it looks like it wouldn't be too hard to rig one of these methods to get some excellent compressed video playing in the game.

    What do you think our best option will be for getting some video into the game? We need it for our tutorial, and also for our "level selection" GUI where we play video of the various levels they can choose among.
     
  4. bigkahuna

    bigkahuna

    Joined:
    Apr 30, 2006
    Posts:
    5,434
    I'm very interested in this as well. I plan on using .FLV for a number of current and future projects.

    As an interim solution, have you tried using Director or Zinc? I've embedded other game content into Director and controled it using ActiveX. I'm not sure what control you would have over a Unity app, I've been meaning to study the Web Player docs a bit more thoroughly as it may reveal an idea or two. The latest Flash Xtra for Director should allow you to play the Flash video file without having Flash installed on the system and you can also launch your game app. The down side is you'll be installing two separate apps, not very clean, but do-able.

    I also looked at Zinc and played around with it a bit. Zinc is basically a development system for Flash that allows you to create "packaged" content (not just Web content). Looks very capable, but again, the solution won't be nearly as clean as doing everything inside Unity.
     
  5. Morgan

    Morgan

    Joined:
    May 21, 2006
    Posts:
    1,223
    Workarounds:

    * For level selection: make an animated texture (say, 16 frames of the level in action, at 8 fps).

    * For the intro: make a Flash executable which, after playing the intro video, launches the Unity executable. (Zinc does some neat things, but Flash can do this on its own). The Unity exe could be in a folder so people still only have one app to click.
     
  6. podperson

    podperson

    Joined:
    Jun 6, 2006
    Posts:
    1,371
    Flash is a nice option, but you'll have the intro play THEN get the configuration dialog.

    Can Unity launch an external program, minimize itself, then return once the program has quit?

    Even so this is likely to be ugly, especially under Windows.
     
  7. jeremyace

    jeremyace

    Joined:
    Oct 12, 2005
    Posts:
    1,661
    You can turn the config window off, or more properly, set it so it doen't open automatically.

    -Jeremy
     
  8. podperson

    podperson

    Joined:
    Jun 6, 2006
    Posts:
    1,371
    You do actually *want* the config window to pop up at some point though, surely. Otherwise the price of having an intro animation is that you can't configure your game...

    I suppose you can write your own config stuff from scratch, but that's a high price to pay to show a startup video.
     
  9. jeremyace

    jeremyace

    Joined:
    Oct 12, 2005
    Posts:
    1,661
    Yes and no, it would just depend on how flashy you would want your in-game menu. A simple menu isn't that hard to set up if you plan it properly, but yes, for a 10 second company logo...not worth it. ;-)

    -Jeremy
     
  10. elias723

    elias723

    Joined:
    Feb 10, 2006
    Posts:
    178
    If you're just doing a company logo flyby, you could just script a camera to fly past a 3d model of your logo and then get close to it, with whatever effects you want to run there. If you want a real video though, I don't know how you could do it.
     
  11. freyr

    freyr

    Joined:
    Apr 7, 2005
    Posts:
    1,148
  12. bigbrainz_legacy

    bigbrainz_legacy

    Joined:
    Jul 15, 2005
    Posts:
    137
    Joaquim's tips and advice have given us a good idea of how to build a video plugin. Time's gotten the best of us for now though, so we'll see how soon we might be able to get to it. Otherwise, we'll just have to patiently wait for 2.0.
     
  13. Jonathan Czeck

    Jonathan Czeck

    Joined:
    Mar 17, 2005
    Posts:
    1,713
    Excellent! If you do get to it, make sure you don't do it similarly to this:
    http://www.onesadcookie.com/svn/repos/QTValuePak/

    While there is code there to display a QuickTime movie in an OpenGL texture and it used to work greatly, QuickTime 7 does things differently and it'd be good to do a more future proof approach. The Warning.txt in there explains this, and apologies if this was already apparent.

    -Jon