Saving replays to the camera roll

Where the test pilots meet and discuss their flight day. Now open to the public ;-)

Moderators: blackbird1955, frankynov, desktopsimmer, Elefant

Saving replays to the camera roll

UNREAD_POSTby Sascha » Sun Feb 17, 2013 12:43 am

An option to save replays as video files to the camera is one of the most requested features, so I thought I’d give it a try.
This will be part of the next update.

Sound is still missing, but the video looks good. This has been rendered directly on an iPad, saved from F-Sim to the camera roll and uploaded to YouTube (also directly from the iPad)—no post processing whatsoever.


http://www.youtube.com/watch?v=dBLtxOdSF4Q&hd=1

(This should open the HD version—if not, select 720p from YouTube’s video settings. Also make sure to use the large or full-screen player).

One problem was that at 720p and 30 frames per second it didn’t look as smooth compared to the game itself (which runs at 60fps on most devices). So I added a bit of motion blur (also directly on the iPad), which solved the problem.
Sascha
Site Admin
 
Posts: 3232
Joined: Wed Jan 27, 2010 12:43 pm

Re: Saving replays to the camera roll

UNREAD_POSTby Sascha » Sun Feb 17, 2013 1:21 am

What options do you think would make sense?

I’d like to keep it as simple as possible.

In the replay, I’d add a red RECORD button. When pressed, it would present a resolution option: SD (640x360) or HD (1280x720), and record/cancel buttons (and would alert the user if saving to the camera roll is not possible). I’ll set the bit rates to 2 Mb/s for HD and 500Kb/s for SD (that’s bits, not bytes—one minute of HD video would thus take about 15MB, bytes this time).
Rendering is not done in realtime (it takes about 2 minutes to render 1 minute at 720p on an iPad 3). During the process, it would display the rendered frames (just like during an ordinary replay, but without sound), a progress bar, a cancel button and the camera control buttons. You’ll be able to change the camera or even pan and zoom (just like in an ordinary replay). Of course you can also select the auto-edit mode.

What do you think?

Edit: Maybe an option to insert the score at touchdown?
Sascha
Site Admin
 
Posts: 3232
Joined: Wed Jan 27, 2010 12:43 pm

Re: Saving replays to the camera roll

UNREAD_POSTby Elefant » Sun Feb 17, 2013 9:24 am

It seems good to me Sascha.
A question though, to edit the video (changing the views mainly) it will be doable in the replay ? I mean, when you touch the record button and you begin to change the cam, it will be recorded this way in the camera roll ?
Elefant
 
Posts: 720
Joined: Wed Mar 02, 2011 10:51 pm
Location: Paris, France

Re: Saving replays to the camera roll

UNREAD_POSTby Sascha » Sun Feb 17, 2013 9:45 am

Yes, I’d add that option (to e.g. Change the camera while the video is being encoded). It would not add the overlay (with the buttons, sliders, etc.) to the video, but the camera changes would be recorded.

So customers would have three options:
1. Choose auto-edit and render the video without manual intervention.
2. Edit the video during rendering (by changing cameras, zoom and pan, etc.)
3. Render multiple versions of the video (e.g. from different cameras) and use an app like iMovie to edit a final version. (I’ve tested it with iMovie on the iPad and it works fine).

All with a minimalistic UI (the UI during video recording would look almost like the UI you’re used to during watching replays).
You won’t be able to use the slider during recording, but I’ll add an option to start recording at the current position (or from the beginning), and of course there will be a stop button to stop encoding at any time.

Do you think more resolutions would make sense too (on devices that support them), e.g. Add an intermediate 960x540 and a full 1920x1080 option?
Sascha
Site Admin
 
Posts: 3232
Joined: Wed Jan 27, 2010 12:43 pm

Re: Saving replays to the camera roll

UNREAD_POSTby Sascha » Sun Feb 17, 2013 11:49 am

I’ve made some improvements and fixed a bug, and it now renders to a 720p video (1280x768x30fps) at full speed on an iPad 3 (i.e. OpenGL rendering runs at 60fps while the replay is generated).
Edit: Oops, made a mistake. Encoding to 720p on the iPad 3 runs at about 40fps (at 2/3rds the normal speed). Encoding to 960x540 runs in realtime (60fps). At 1080p we’re down to about 25 fps (about ½ the normal speed).
Sascha
Site Admin
 
Posts: 3232
Joined: Wed Jan 27, 2010 12:43 pm

Re: Saving replays to the camera roll

UNREAD_POSTby frankynov » Sun Feb 17, 2013 2:37 pm

What about the previous mockup of the replays storage you had designed some time ago ?

Image

Maybe clicking on one of the replays could ask to watch the replay in real time and/or export it in camera roll ?
frankynov
 
Posts: 845
Joined: Sun Feb 14, 2010 4:48 pm
Location: Namur, Belgium

Re: Saving replays to the camera roll

UNREAD_POSTby Sascha » Sun Feb 17, 2013 5:11 pm

Yes, this was meant to store the replay data (i.e. the internal representation of the replay, the position, rudder deflections, etc.)

I can still do this (and probably will), but for now these are two different things: Storing replay data, and rendering a replay to a video file.

When playing back a replay you still have control over the camera. Once it’s rendered to video you have not, thus for the render-to-video part a new UI is needed anyway.

For now I’d like to focus on the render-to-video part. I can still add the storing of multiple replay data files part later.

There are lots of F-Sim videos of YouTube, and that’s great. But unfortunately they have either been captured on a jail broken iOS (that allows video capture, but the quality is horrible) or filmed with video cameras aimed at the iPad’s screen (which isn’t optimal either). Time to see some high quality 1080p clips…
Sascha
Site Admin
 
Posts: 3232
Joined: Wed Jan 27, 2010 12:43 pm

Re: Saving replays to the camera roll

UNREAD_POSTby desktopsimmer » Sun Feb 17, 2013 9:26 pm

:)

If I'm reading this right, If the user presses the record button on the replay screen, it will record the camera views and what the users sees in that replay. When the user presses the stop button, the user is presented with options (SD/HD, etc) about the recording. Then it's rendered to the Camera Roll, and then the user can do what ever they want to do to it.

Maybe an option to insert the score at touchdown?


IMHO I would give the user a choice to either add a title screen at the beginning, and an option to add the Score/Summary screen at touchdown or Wheel stop.

As a of topic note. One of my friends said that we should add the NASA Male/Female Commentator when using replays. I'm not sold on the idea, but I thought I'd ask.
desktopsimmer
 
Posts: 1599
Joined: Fri Apr 02, 2010 12:17 pm
Location: UK

Re: Saving replays to the camera roll

UNREAD_POSTby Sascha » Mon Feb 18, 2013 9:15 am

It would start recording (rendering into a video file) as soon as you hit the record button, but you’d still get all the camera controls. The recording happens in near real time, depending on your device and resolution it runs at 50% to 100% speed, but that should not be a problem for e.g. switching camera perspective while the video is recording.
Sascha
Site Admin
 
Posts: 3232
Joined: Wed Jan 27, 2010 12:43 pm

Re: Saving replays to the camera roll

UNREAD_POSTby Sascha » Mon Feb 18, 2013 11:23 am

As a of topic note. One of my friends said that we should add the NASA Male/Female Commentator when using replays. I'm not sold on the idea, but I thought I'd ask.

Hmmm…
Not sure. This would be a lot of work, and I don’t think it’s worth it.

Rendering the audio to a file in general proves to be much more difficult than rendering the video. Partly because I’ve got a pretty good background with OpenGL rendering (and Apple’s APIs for video rendering are pretty straight forward—you just have to access the frames OpenGL has rendered and pass them to the video encoder), but no experience with Apple’s audio APIs. OpenAL doesn’t provide this kind of functionality, so I’ll need to find some low level access (AudioUnits looks promising) and replace the speaker output with a “write-to-file” output. Guess I’ll have to delve into that…
Sascha
Site Admin
 
Posts: 3232
Joined: Wed Jan 27, 2010 12:43 pm

Next

Return to Pancho's Fly-Inn

Who is online

Users browsing this forum: No registered users and 2 guests

cron