gpt4 book ai didi

Youtube 流 fmt_stream_map 质量

转载 作者:行者123 更新时间:2023-12-01 08:08:08 26 4
gpt4 key购买 nike

我通过解析“fmt 流映射”得到流 URL,

问题是如果我的视频时长不到 1 小时,我会得到这个:

{
"comment_count" = 1;
description = "";
"dislikes_num" = 0;
duration = "54:46";
"encrypted_id" = WWjNEyHrNsk;
"fmt_stream_map" = (
{
"fallback_host" = "tc.v7.cache6.c.youtube.com";
itag = 22;
quality = hd720;
type = "video/mp4; codecs=\"avc1.64001F, mp4a.40.2\"";
url = "http://r4---sn-bvvbax-8pxl.c.youtube.com/videoplayback?sver=3&ipbits=8&itag=22&key=yt1&expire=1366039593&upn=phUk9-1Fjyw&signature=34CDFF5AAC4E5BB24177EAA001B5519E0218A04E.A437435FC87FD09D7AD95E0417A4EA77BC786C86&ms=au&mv=m&mt=1366015457&app=youtube_mobile&ip=85.127.44.131&fexp=906370%2C923120%2C932000%2C932004%2C906383%2C916911%2C916910%2C902000%2C901208%2C919512%2C929903%2C925714%2C931202%2C900821%2C900823%2C931203%2C906090%2C909419%2C908529%2C930807%2C919373%2C930803%2C906836%2C920201%2C929602%2C930101%2C930609%2C926403%2C900824&sparams=cp%2Cid%2Cip%2Cipbits%2Citag%2Cratebypass%2Csource%2Cupn%2Cexpire&el=watch&newshard=yes&id=5968cd1321eb36c9&cp=U0hVS1BOV19OTUNONV9ISEFGOmh3anpiZHFRODBI&dnc=1&yms=izkxzhrL53I&source=youtube&ratebypass=yes";
},
{
"fallback_host" = "tc.v14.cache4.c.youtube.com";
itag = 18;
quality = medium;
type = "video/mp4; codecs=\"avc1.42001E, mp4a.40.2\"";
url = "http://r4---sn-bvvbax-8pxl.c.youtube.com/videoplayback?sver=3&ipbits=8&itag=18&key=yt1&expire=1366039593&upn=phUk9-1Fjyw&signature=BCA6FFE2575EE8947CFF52E91D0C8896538E239F.33FE7FF507257A8F5161A1E4C80A101BE4EB693F&ms=au&mv=m&mt=1366015457&app=youtube_mobile&ip=85.127.44.131&fexp=906370%2C923120%2C932000%2C932004%2C906383%2C916911%2C916910%2C902000%2C901208%2C919512%2C929903%2C925714%2C931202%2C900821%2C900823%2C931203%2C906090%2C909419%2C908529%2C930807%2C919373%2C930803%2C906836%2C920201%2C929602%2C930101%2C930609%2C926403%2C900824&sparams=cp%2Cid%2Cip%2Cipbits%2Citag%2Cratebypass%2Csource%2Cupn%2Cexpire&el=watch&newshard=yes&id=5968cd1321eb36c9&cp=U0hVS1BOV19OTUNONV9ISEFGOmh3anpiZHFRODBI&dnc=1&yms=izkxzhrL53I&source=youtube&ratebypass=yes";
},
{
"fallback_host" = "tc.v3.cache3.c.youtube.com";
itag = 36;
quality = small;
type = "video/3gpp; codecs=\"mp4v.20.3, mp4a.40.2\"";
url = "http://r4---sn-bvvbax-8pxl.c.youtube.com/videoplayback?sver=3&ipbits=8&itag=36&key=yt1&expire=1366039593&upn=phUk9-1Fjyw&signature=8174E39396391843AFA940C30624A823E5275890.B323AA44059ED3928A47C4AEA1BC82F3C565F433&ms=au&mv=m&mt=1366015457&app=youtube_mobile&ip=85.127.44.131&fexp=906370%2C923120%2C932000%2C932004%2C906383%2C916911%2C916910%2C902000%2C901208%2C919512%2C929903%2C925714%2C931202%2C900821%2C900823%2C931203%2C906090%2C909419%2C908529%2C930807%2C919373%2C930803%2C906836%2C920201%2C929602%2C930101%2C930609%2C926403%2C900824&sparams=cp%2Cid%2Cip%2Cipbits%2Citag%2Cratebypass%2Csource%2Cupn%2Cexpire&el=watch&newshard=yes&id=5968cd1321eb36c9&cp=U0hVS1BOV19OTUNONV9ISEFGOmh3anpiZHFRODBI&dnc=1&yms=izkxzhrL53I&source=youtube&ratebypass=yes";
}
);
"length_seconds" = 3286;
"likes_num" = 7;
longform = 1;
playability = "PLAY_OK";
"player_type" = desktop;
"profile_url" = "/user/KapfenbergWebTV";
"public_name" = KapfenbergWebTV;
"thumbnail_for_watch" = "http://i.ytimg.com/vi/WWjNEyHrNsk/hqdefault.jpg?w=600&h=360&sigh=5t9yhLmY66cc2ZBb6gJyOaNOsRs";
"thumbnail_info" = "<null>";
"time_created_text" = "Feb 6, 2013";
title = "HiWay-TV Sendung 3 - 2013";
"user_image_url" = "//s.ytimg.com/yts/img/silhouette32-vflu0yzhs.png";
"view_count" = "1,593";
"watch_link" = "/watch?v=WWjNEyHrNsk";
}

具有不同的品质。

但是如果我的视频时长超过 1 小时,我只会得到很小的质量,例如:
{
"comment_count" = 0;
description = "";
"dislikes_num" = 0;
duration = "1:00:47";
"encrypted_id" = taiK0WKSApg;
"fmt_stream_map" = (
{
"fallback_host" = "tc.v1.cache6.c.youtube.com";
itag = 36;
quality = small;
type = "video/3gpp; codecs=\"mp4v.20.3, mp4a.40.2\"";
url = "http://r6---sn-bvvbax-8pxe.c.youtube.com/videoplayback?ratebypass=yes&fexp=906370%2C923120%2C932000%2C932004%2C906383%2C916911%2C916910%2C902000%2C901208%2C919512%2C929903%2C925714%2C931202%2C900821%2C900823%2C931203%2C906090%2C909419%2C908529%2C930807%2C919373%2C930803%2C906836%2C920201%2C929602%2C930101%2C930609%2C926403%2C900824&signature=9B83CFB7B240D7DA86E0ED4EC0DFFCFF4151D85B.81CBC92237B653BA3BF7E0E52A730B324EFD70A8&key=yt1&id=b5a88ad162920298&newshard=yes&mt=1366015334&sparams=cp%2Cid%2Cip%2Cipbits%2Citag%2Cratebypass%2Csource%2Cupn%2Cexpire&mv=m&ms=au&ip=85.127.44.131&el=watch&yms=izkxzhrL53I&itag=36&upn=j7RXkiXzhRI&source=youtube&cp=U0hVS1BOV19OUkNONV9ISEFHOm13anpiZHFROTBN&expire=1366039698&ipbits=8&sver=3&dnc=1&app=youtube_mobile";
}
);
"length_seconds" = 3647;
"likes_num" = 6;
longform = 1;
playability = "PLAY_OK";
"player_type" = desktop;
"profile_url" = "/user/KapfenbergWebTV";
"public_name" = KapfenbergWebTV;
"thumbnail_for_watch" = "http://i.ytimg.com/vi/taiK0WKSApg/hqdefault.jpg?w=600&h=360&sigh=6hxibWtgHUAnZzNL9bBYxIQRScU";
"thumbnail_info" = "<null>";
"time_created_text" = "Apr 3, 2013";
title = "HiWay-TV Sendung 07 2013";
"user_image_url" = "//s.ytimg.com/yts/img/silhouette32-vflu0yzhs.png";
"view_count" = 974;
"watch_link" = "/watch?v=taiK0WKSApg";

}

有谁知道问题出在哪里??

最佳答案

持续时间无关紧要。该视频支持多种格式和质量。你需要选择一个可用的。

我有一段基于 ITAG 的代码,希望这会有所帮助。

function GetScreenTag(iTag: Byte): String;
begin
case iTag of
5: Result := 'Low Quality, 240p, FLV, 400x240';
17: Result := 'Low Quality, 144p, 3GP, 0x0';
18: Result := 'Medium Quality, 360p, MP4, 480x360';
22: Result := 'High Quality, 720p, MP4, 1280x720';
34: Result := 'Medium Quality, 360p, FLV, 640x360';
35: Result := 'Standard Definition, 480p, FLV, 854x480';
36: Result := 'Low Quality, 240p, 3GP, 0x0';
37: Result := 'Full High Quality, 1080p, MP4, 1920x1080';
38: Result := 'Original Definition, MP4, 4096x3072';
43: Result := 'Medium Quality, 360p, WebM, 640x360';
44: Result := 'Standard Definition, 480p, WebM, 854x480';
45: Result := 'High Quality, 720p, WebM, 1280x720';
46: Result := 'Full High Quality, 1080p, WebM, 1280x720';
82: Result := 'Medium Quality 3D, 360p, MP4, 640x360';
84: Result := 'High Quality 3D, 720p, MP4, 1280x720';
100: Result := 'Medium Quality 3D, 360p, WebM, 640x360';
102: Result := 'High Quality 3D, 720p, WebM, 1280x720';
else
Result := 'NA';
end;
end;

关于Youtube 流 fmt_stream_map 质量,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16011497/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com