第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問題,去搜搜看,總會(huì)有你想問的

如下是一個(gè)FFmpeg測(cè)試程序,出現(xiàn)RT的錯(cuò)誤,怎么辦?

如下是一個(gè)FFmpeg測(cè)試程序,出現(xiàn)RT的錯(cuò)誤,怎么辦?

UYOU 2022-07-01 07:07:09
#define inline _inline#ifndef INT64_C#define INT64_C(c) (c ## LL)#define UINT64_C(c) (c ## ULL)#endif#ifdef __cplusplusextern "C" {#endif#include <libavformat/avformat.h>#include <libavcodec/avcodec.h>#include <libswscale/swscale.h>#ifdef __cplusplus}#endif#include <stdio.h>static void SaveFrame(AVFrame *pFrame, int width, int height, int iFrame);int main (int argc, const char * argv[]){char* filename = "E:\\A.mp4";AVFormatContext *pFormatCtx = NULL;int i, videoStream;AVCodecContext *pCodecCtx;AVCodec *pCodec;AVFrame *pFrame;AVFrame *pFrameRGB;AVPacket packet;int frameFinished;int numBytes;uint8_t *buffer;// Register all formats and codecsav_register_all();// Open video file//if(avformat_open_input(&pFormatCtx, argv[1], NULL, NULL)!=0)if(avformat_open_input(&pFormatCtx, filename, NULL, NULL)!=0)return -1; // Couldn't open file// Retrieve stream informationif(av_find_stream_info(pFormatCtx)<0)return -1; // Couldn't find stream information// Dump information about file onto standard errorav_dump_format(pFormatCtx, 0, filename, false);return 0;}
查看完整描述

1 回答

?
慕碼人2483693

TA貢獻(xiàn)1860條經(jīng)驗(yàn) 獲得超9個(gè)贊

用 avformat_find_stream_info 代替,由于ffmpeg 版本不同,新版本的會(huì)把老版本的一些函數(shù)摒棄或者刪除掉。一般都有替代函數(shù)可選。

查看完整回答
反對(duì) 回復(fù) 2022-07-05
  • 1 回答
  • 0 關(guān)注
  • 181 瀏覽

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購(gòu)課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)