YouTube iFrame API quality parameter "vq" bug - video playback with black screen - api

There seems to be a huge issue with the iframe url parameter "vq" (in this case "vq=hd720").
If you use this paraneter, the video screen in the flash player turns black.
This example URL worked until today:
http://www.youtube.com/embed/dFVDJlM6zLY?vq=hd720
(feel free to replace the example YouTube ID)
Now, this example works only without the "vq" parameter (vq=hd720):
http://www.youtube.com/embed/dFVDJlM6zLY
The problem is, that we delivered this YouTube iframe in a lot of websites for a lot of clients and it worked quite well for month (years?). Now every single site has black youtube videos!!!
Does anyone know if this parameter was depricated?
Was there a new YouTube API release today?
The parameter was already discussed and recommended in diffrent forums:
e.g. Force youtube embed to start in 720p
Any ideas how to force Google (YouTube) to solve this problem?

It seems that the only way out of this (currently) is to remove the vq parameter or set it to auto. This seems like a widespread problem though, that has occurred very recently. You may wish to star this issue at google make them take notice:
https://code.google.com/p/gdata-issues/issues/detail?id=6009

I was having a similar issue but when I tried to force an embeded youtube video to play in HD at a dimension smaller than the HD resolution.
I was able to get around the "black screen" HD issue by using the old embed code.
If you set the video size to the highest resolution you can then use vq=hd720 parameter and set the video width and height to a lower resolution
<object width="1280" height="720"><param name="movie" value="//www.youtube.com/v/VIDEO_ID?hl=en_US&version=3&rel=0&vq=hd720"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="//www.youtube.com/v/kyilUYoxcww?hl=en_US&version=3&rel=0" type="application/x-shockwave-flash" width="560" height="315" allowscriptaccess="always" allowfullscreen="true"></embed></object>
Hope this helps!

Just had this exact problem. Found changing it to vq=auto works in the code. But on the videos we're working with it's coming out at a slightly lower quality than we'd like.
Nevertheless, this at least removes the blackout.

What are your 3d settings set to? Here's what I've noticed...
1) Taking away the vq=hd setting works.
2) Turning the 3D setting on the video player ON (or sometimes OFF the ON again) makes the
video work.
3) Curious about number 2, I went to the video settings on the video (the admin settings) and changed the 3D settings under Advanced. I changed it from "Disable 3D for this video" to "Please make this video 3D." For some reason this works -- the vq code is back to working the way it should.
HOWEVER I don't know if I would recommend doing this! The reason I set all my videos to "Disable 3D for this video" in the first place was because if I left on on the on the default "No Preference," it often caused glitches in the video.
Has YouTube changed anything with the 3D settings recently? I think thay may have but am not certain.

Related

Screen Recording in Mac using AVFoundation's documentation

I have been working on screen recording on MacOS. I have working code for the same based on Apple's Documentation (https://developer.apple.com/library/content/qa/qa1740/_index.html). The problem is that the resolution of the recorded video is very low. According to the logs generated it looks like SD 480x300 is the default resolution. I was unable to find any methods to change the resolution of the video quality. Can somebody help me out here?
I found the solution to the problem. You can set the screen resolution at mSession.sessionPreset = AVCaptureSessionPreset1280x720;
There are several values for the sessionPreset including
AVCaptureScreenPresetLow
AVCaptureScreenPresetMedium
AVCaptureScreenPresetHigh
AVCaptureScreenPreset320x240
AVCaptureScreenPreset352x288
AVCaptureScreenPreset640x480
AVCaptureScreenPreset960x540
AVCaptureScreenPreset1280x720

Play HTML5 videos forward and backward on hover

I've been trying for days to get a specific behaviour on the homepage of my personal website. But I didn't find any good solution yet. Can someone help me please :-)
I have a homepage with a grid of short videos with different durations. I want each of them to play completely on mouse hover. On second hover most should replay normally, but some should play backward.
I read that playing videos backward was not good in terms of performance because native browser players were not meant for that. So I searched for an alternative and came to the following idea:
Double the duration of those "special" videos so they integrate their forward sequence (1-2-3) and backward sequence (3-2-1) in the same file. On first hover, the video would play its first half, and after that only, on second hover it would play the second half.
Here is a JSfiddle where I put all elements for testing… but I'm currently stuck with my poor JS skills.
HTML:
<video class="forward-backward">
<source src="http://tacco.fr/divers/forward-backward.mp4" type="video/mp4">
<source src="http://tacco.fr/divers/forward-backward.webm" type="video/webm">
</video>
jQuery:
var figure = $("video").mouseover(hoverVideo);
function hoverVideo() {
$(this).get(0).play();
};
It may be a very bad idea in terms of performance (because filesizes are bigger to load), so I'm really open for any others.
Don't hesitate to ask if you have any question.
Thank you very much :-)
BTW: no more than 5 videos should play at the same time… I don't know how to do that…
I ran into this problem. The best solution I can think of is to use a video editor and reverse the video files themselves. Then you create two video elements, one with the forward video as the source and one with the reverse video as the source. Using javascript, you can then show the correct video (and hide the other one) depending on whether you want the video to be playing forward or backwards. Does that help?

using VideoJS VAST plugin without video content

I want to display ads with VAST ad tag and with a HTML5 player. I'm currently trying to use videoJS with Vast Ads Plugin and I'm noticing I can't get the videoJS player to work without having a video content (video element with a src attribute for the video content).
Does anyone know a simple way to use a video player for just ads from VAST, and without video content? Google IMA3 SDK allows that, but I'm now looking for video plugins to cover IE use case (which Google IMA3 SDK does not cover).
Thank you!
There is a dirty way to do this. You can get the ad video url from the plugin that already parsed by it. Then just paste as src to video tag.
If the player you are using support only running pre-roll, that's obviously the best choice. Since that's likely not the case, I would recommend creating a small 1 second long black video MP4 and setting it as the content, with all video controls disabled. This was the lowest friction solution for me, as I didn't need to ask the player anything special of the player. The pre-roll plays, and the user briefly sees black at the end, which may not really be noticed.

MediaElement.js Not Loading Subtitles

I'm trying to use MediaElement.js for an embedded player with subtitles, but it just says "English (loading)" and doesn't actually show the subtitles.
I'm using the pre-made track demo and it doesn't even work.
I created another page that uses the code from the MediaElement.js home page and it doesn't work, either.
Interestingly enough, the MediaElement.js track demo page DOES show the English subtitles, correctly, but DOES NOT do the translation that the code says it should.
Does my web server need a mime-type set for .srt and .vtt? The documentation doesn't say anything about it (video mime-types are mentioned).
It's mentioned here that jQuery version might be the issue.
I ran into the same problem recently and found out that this occurs when one forgets to set the srclang property on the track node..
Make sure to add it (in this case: dutch subtitling):
<track id="subtitles" kind="subtitles" label="Ondertitels" src="mysubs.srt" srclang="nl"></track>

Video.js changing source and seeking simultaneously

I am trying to build a site using video.js to view videos. We need to switch videos while maintaining the currentTime value from the old video. The way I have it working right now is using the loadedmetadata event to set currentTime. The problem I am seeing with this is that the first frame of the video gets shown momentarily while the player seeks to the right time. I am new to JS programming so perhaps I am doing something wrong but I do not see anything in the docs that can help me overcome this. I am trying to render H.264/mp4 videos in Chrome. Thanks!
Changing the preload setting to 'metadata' might help this in the browsers that support that setting.
preload="metadata"
Then it supposedly should only load the metadata and trigger the loadedmetadata event, and not show the first frame. That is unless providing any new src forces preloading, and I'm not sure off the top of my head.
HTML5 video doesn't give us a lot of options around seamless switching videos unfortunately. The media source API proposal from Google/Microsoft/Netflix aims to fix this. http://dvcs.w3.org/hg/html-media/raw-file/tip/media-source/media-source.html
You could try this:
https://bitbucket.org/felixschwarz/videojs-hdtoggle/
As seen here on the old videoJS-Forum I think you might have to declare preload="auto".
In the linked forum-threat there are also some changes I made documented.