Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
|
|
Thread Tools | Search this Thread | Display Modes |
21st January 2014, 20:26 | #1 | Link |
Registered User
Join Date: Feb 2009
Location: USA
Posts: 676
|
Crazy Stupid Question - Can it be done? (Subject:60p->30p)
Ok so I have a really crazy idea; Well some of you will probably think its crazy, but let me explain... No, there is too much, let me sum up....
So there is a trick on Youtube, where you can get "Fake" 60fps playback by using their HTML5 player, which has a playback speed option. Basically what you do is you take a 60fps clip and stretch it out to a 30fps clip.. It also involves taking the original audio and running it through Audacity to do some time and pitch adjustment. I'm wondering, if its possible to accomplish this without that "playback" stage. And also, if there is a better way to get cleaner audio. Let's say I have a 60fps game recording that is 20 minutes long. I want to re-encode it as a 30fps clip that plays back with the temporal resolution of a 60fps clip. Without having to use the whole "playback at 30fps at 2x speed" trick in the first place. Ideally produce a 20 minute 30 fps clip, which on the timeline is playing back 2x as fast, but is still 20 minutes long. Potentially that could remove the need to fuss with the audio as well. Is this event remotely possible in theory? With Avisynth, or with Sony Vegas, without any expensive special plugins? I mean if people can put slow motion clips into regular video clips - can't you put fast-motion clips as well? Meaning, you're not dropping any frames or interpolating or doing anything funny.. You're just playing back the same number of frames at a higher speed. It would seem to make sense that if you can take a given 30fps video, and it has a slow-motion segment in it, that is extremely smooth and looks fine. Could you not also produce a 30fps video from a 60fps source, that plays back at the 60fps rate? For anyone wondering what this actually looks like, here is a video I uploaded a while ago, after trying the "trick" myself. You must have HTML5 player enabled, so you can select 2x playback speed on the video. Ace Combat: Assault Horizon - 60fps Test Last edited by osgZach; 21st January 2014 at 20:30. |
21st January 2014, 21:55 | #3 | Link |
Registered User
Join Date: Aug 2008
Posts: 233
|
I am not sure I understand, exactly, but how about using:
Code:
v = AssumeFPS(framerate() / 2.0) a = TimeStretch(tempo=50.0) AudioDub(v,a) EDIT: Re-reading your post, it seems I may not not understand at all But I will leave the snippet above for others who want to use it (or something like it) for the YouTube "trick". Last edited by vampiredom; 21st January 2014 at 21:59. |
21st January 2014, 23:12 | #5 | Link | |
Registered User
Join Date: Feb 2009
Location: USA
Posts: 676
|
Quote:
I.e the clip I posted a link to? It plays at the "proper" speed when you increase the playback rate to 2x. Because all Youtube clips are converted to 30fps if they are not already 30fps. You'll notice the timer on Youtube says the clip is almost an hour long - but its actually only about half an hour. Because it was stretched out and slowed down as a 30fps clip.. So that it would play back at 60fps when you increase the speed to 2x in the Youtube player. I want to get the same playback affect, without the Youtube player part. I.e Create a 30fps clip that plays back with the temporal resolution of the original 60fps clip. Which it basically does because it still has the same number of frames that the 60fps source had. I'm guessing this could be accomplished in MKV possibly with the use of Timecodes or something.. But that wouldn't address the Audio, and ultimately the real reason for wanting to do it. Which is to upload it to Youtube in the first place. Without requiring the HTML5 player, or special tags to remind people to increase their playback speed, etc.. I found the original video I watched to learn how to do the Youtube trick, so maybe it will explain things better. https://www.youtube.com/watch?v=EsBXYHfYgmI So essentially the I would like to find out if its possible to accomplish the end result of what this process does. Without having to rely on a "2x" playback speed of a video player. Last edited by osgZach; 21st January 2014 at 23:41. |
|
22nd January 2014, 00:50 | #6 | Link | |
Registered User
Join Date: Oct 2011
Posts: 204
|
Quote:
You want all of the following: - All the frames unaltered. - The video played at the correct speed. - The frame rate of the video halved. This is impossible, you'd have to sacrifice at least one of the 3 points (currently you sacrifice the "correct speed" point, because you rely on the player playing back at 2x speed). That said, the easiest way to achieve what you've currently got is this: Code:
OV = YourVideoSource() OA = YourAudioSource() NV = OV.AssumeFPS(OV.FrameRateNumerator(), OV.FrameRateDenominator()*2) NA = OA.AssumeSampleRate(Round(AudioRate()/2.0)) AudioDub(NV,NA) |
|
22nd January 2014, 14:05 | #7 | Link | |||
Formerly davidh*****
Join Date: Jan 2004
Posts: 2,493
|
Quote:
Quote:
There is no way to upload a clip to YouTube that will play back at 60fps. Quote:
It's like asking for a pot of non-sticky glue. David |
|||
23rd January 2014, 03:23 | #8 | Link | |
Registered User
Join Date: Feb 2009
Location: USA
Posts: 676
|
Quote:
Of course I'm not asking for a 30fps clip with the temporal resolution of a 60fps - that's physically impossible. I'm asking for a way to duplicate the EFFECT. Which I was pretty clear about - really As far as why, I'm pretty sure I already answered that. So it can be uploaded to Youtube without burdening the user with having to use HTML5 (vs Flash, which some people prefer) and without having to modify the speed setting every time. It's an academic exercise to see if it can be done, for the sake of doing it because I can. I don't really "need" a reason to experiment with something interesting. That's aside the fact it has practical applications for a small segment of Youtubers. Last edited by osgZach; 23rd January 2014 at 03:25. Reason: spelling |
|
23rd January 2014, 03:31 | #9 | Link | |
Registered User
Join Date: Feb 2009
Location: USA
Posts: 676
|
Quote:
I'm not necessarily sure it's that I want the video to play back at the "correct" speed, as you pointed out.. Well I feel like I would be splitting hairs there. But it seems to be, that I have seen footage before, of cameras that record 30 progressive frames per second, and provide pretty good temporal resolution as well, not a lot of jitters and such with movement. I figure if there is a way for a camera to record that fairly smoothly, there has got to be a better way to smooth out 30fps clips, than blindly throwing out half the frames during the conversion. Or using motion blurs, or things like that. (On the subject of blur, would it be better to blur the 60fps footage before decimation, or after? I've never gotten good results with motion blur, personally. But I know little about correct application) For Example: If I did this locally and played back a video processed to play 30fps at 2x speed - and I recorded THAT playback @30fps somehow, would it look equally as smooth as it does during the 2x playback? I suppose that is the fundamental question of what I am attempting to replicate. If that doesn't clear it up for anyone, nothing probably ever will Last edited by osgZach; 23rd January 2014 at 03:35. Reason: clarified |
|
23rd January 2014, 03:52 | #10 | Link | |
Registered User
Join Date: Sep 2007
Posts: 5,346
|
Quote:
If you play 30fps at 2x speed. That is 60fps (frames per second) . Given you have the same number of frames, the duration is exactly 1/2 . That is basic math If you recorded that 60fps video at 30fps, then only 1/2 the frames are captured . Every 2nd frame will be missed by your capture. ie. Every second is represented by 30 frames, not 60 - thus it won't be as smooth |
|
23rd January 2014, 06:24 | #11 | Link | |
Registered User
Join Date: Sep 2006
Posts: 1,657
|
Quote:
And if you have a 60fps video clip already and want to change it to 30fps, you don't need to re-encode it. The frame rate declaration is just like a tag, all you have to do is put that tag and the video into a container that supports it, and it will playback at the declared frame rate, such as mkv. The re-encode of the video that the guy did is not necessary. Last edited by lansing; 23rd January 2014 at 06:29. |
|
23rd January 2014, 06:47 | #12 | Link |
Registered User
Join Date: Oct 2011
Posts: 204
|
So, you want 30 fps video played at 30 fps look like the original 60 fps video?
You could try either blending 2 frames together Code:
YourVideoSource() Merge(SelectEven(), SelectOdd()) Alternatively, you can also just drop every other frame, but you already mentioned that you don't want that. |
23rd January 2014, 18:48 | #13 | Link | ||||
Formerly davidh*****
Join Date: Jan 2004
Posts: 2,493
|
Quote:
Quote:
Quote:
Quote:
David |
||||
25th January 2014, 13:18 | #14 | Link |
Registered User
Join Date: Mar 2007
Posts: 407
|
osgZach,
if I get you right, you just want to tell Youtube that a 60fps clip is 30fps. In other words, upload a '0.5* slow motion' version of it. For realtime playback then choose 2*speed in the player. Right? In an AVS script, use AssumeFPS(FrameRate*0.5) to give an output clip with a 60fps source a 30fps property. Depending on the player - if it transposes the audio frequencies or just compresses them - use either AssumeSampleRate(AudioRate*0.5) to just give the audio e.g. the property 24000Hz sample rate for a 48000Hz source, or ResampleAudio(AudioRate*0.5) to give the audio 24000Hz sample rate without transposing the frequencies one octave down. EDIT: DarkSpace posted almost the same answer already. EDIT2: ResampleAudio will not time stretch the audio appropriately with AssumeFPS. Use vampiredom's TimeStretch suggestion instead. Last edited by martin53; 25th January 2014 at 20:04. Reason: Added note about TimeStretch |
25th January 2014, 19:01 | #15 | Link | |
Registered User
Join Date: Aug 2008
Posts: 233
|
Quote:
Code:
I found the original video I watched to learn how to do the Youtube trick, so maybe it will explain things better. https://www.youtube.com/watch?v=EsBXYHfYgmI I do not see any way (or any sense) of doing this "without YouTube" (or some other HTML5 player), however. |
|
25th January 2014, 20:02 | #16 | Link |
Registered User
Join Date: Mar 2007
Posts: 407
|
vampiredom,
I rechecked and if the Youtube player compresses playback time without changing the pitch (didn't bother to try that), then ResampleAudio is wrong, and only your TimeStretch suggestion was right. So video quality is enhanced, but audio suffers - see the TimeStretch docpage; and the inverse playback audio manipulation will again introduce some inaccuracies. Last edited by martin53; 25th January 2014 at 20:12. |
25th January 2014, 20:59 | #17 | Link | |
Registered User
Join Date: Aug 2008
Posts: 233
|
Quote:
I suppose I intended only to make a pure AVS version of the trick, rather than a reinvention / circumvention of it. |
|
Thread Tools | Search this Thread |
Display Modes | |
|
|