Rob - Blog Post #11 - Making a Trailer!

Intro

First and foremost, here's a link to the trailer on my YouTube channel! You can also find my Planet Snatchers trailer from last semester if you'd like to compare how vastly different these are stylistically!

The main "learning point" for me in this endeavor was using Unity to craft the video. I knew I wanted a video in this style. where a Camera would move around a scene and focus in on objects with video and text embedded within. I wasn't super sold on using the "ransom notes" from our game for this, but it grew on me when I realized animating a story book with the content on each new page would be far too challenging given the time frame.

Video in Unity

As this was an entirely new experience for me, I had no idea if Unity could even reliably run video. Looking around online got me a "yeah, it can probably do that," with very little information on how, especially since most of what I found was outdated. Luckily, just importing my MP4s to the project and dragging the file itself right onto a Cube in the scene yielded immediate results.

VPC

This component appeared on the object automatically after dragging the MP4 onto it. Realizing I didn't want the video to play 6 times (each side of the cube) I instead turned it into a sprite and reapplied the MP4 to that object. A quad/plane may prove to be even more optimized for this.

The Video Player component is very similar to an AudioSource component, You can Play(), Pause(), and Stop() it, along with directly editing its "time" variable. You can also Prepare() the component, which I don't fully understand but I absolutely tried to make use of.

All of the videos in the scene start by playing, and I have some keyboard shortcuts to call "Prepare()" as well as one that will restart all of the videos and pause them after a frame or two, so they all start at the beginning when the camera rolls around.

Each Page

Every page in the video is made up of the Sprite with the VideoPlayer component, a Text component, and a very thin cube underneath it that produces a drop shadow. If I had made the page itself a quad and applied the sprite as a texture to it, I think it would've produced this shadow on its own. 

Either way, the pages are all pretty simple, and don't have any special functionality besides what I mentioned already in regards to the VideoPlayer.

The Camera

The camera for this video has its own ~1minute long animation that takes it from note to note. This was done by hand using Keyframes in Unity's Animator. The other main feature it takes advantage of is the Animation Event, which allows me to call functions to Play() / Pause() each VideoPlayer component as I arrive at it. This helped me avoid ever having more than one VideoPlayer active at any given time, as that would probably cause some lag issues.

  It's not much to look at, but this is the Camera's Animation. It brings the whole video together.

It's not much to look at, but this is the Camera's Animation. It brings the whole video together.

There are definitely issues with lag still, and getting the videos to all Play at the right times is inconsistent. That said, it's still a really cool setup that I'm glad I know how to do now. Trying to get the same thing done in Adobe Premiere was causing a lot of issues, as their "Parent-Child" object relationship isn't quite the same as Unity's.