如何去除Youtube图片的黑边 [英] How to remove black border of Youtube image

查看:27
本文介绍了如何去除Youtube图片的黑边的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在这里有很多关于如何获取 Youtube 图像的例子.但如果视频是非标准格式,例如图像上出现垂直、黑框.

I got a lot of examples here how to get Youtube image. But if video is non-standard format, for example, vertical, black frame appears on the image.

我在这个站点上发现了一个有趣的链接,可以通过 GET 查询来剪切它:http://img.youtube.com/vi/XkOpbLBzPsY/hqdefault.jpg

I found interesting link on this site where it can be cut by GET query: http://img.youtube.com/vi/XkOpbLBzPsY/hqdefault.jpg

http://img.youtube.com/vi/XkOpbLBzPsY/hqdefault.jpg?custom=true&w=196&h=110&stc=true;jpg444=true&jpgq=90&sp=68&sigh=Gv-oyTIgA39e7UG01pZ2RiGbwSo

.. 我尝试了我的图像,但什么也没发生,也没有关于这些参数的用途的任何信息.

.. I tried out with my image, but nothing happened, and not any info on what these parameters are for.

问题是:如果我们可以像上面的网址那样做,我怎样才能获得这些参数信息?如果没有,有没有其他办法去除黑框?

The question is: if we can do that as in above urls, how can I get these parameters info? If not, is there any other way to remove black frame?

如果只知道 Youtube 代码,有可能得到如此清晰的图像吗?

Is it possible to get such clear image if we know Youtube code only?

推荐答案

您正在寻找 16:9 yt:aspectratio 格式的 YouTube 缩略图.尝试使用此SO线程中提供的图片网址:

You're looking for the 16:9 yt:aspectratio format of the youtube thumbnail. Try using the image URL provided in this SO thread:

http://img.youtube.com/vi/<insert-youtube-video-id-here>/mqdefault.jpg
http://img.youtube.com/vi/<insert-youtube-video-id-here>/maxresdefault.jpg

试过了,效果很好.希望有所帮助.

Tried this and it works. Hope that helps.

这篇关于如何去除Youtube图片的黑边的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆