videoDecoder ,
This commit is contained in:
parent
04008c0ef8
commit
146a955841
8
main.cc
8
main.cc
@ -1,11 +1,12 @@
|
||||
#include <iostream>
|
||||
#include <thread>
|
||||
#include <SDL2/SDL.h>
|
||||
#include <filesystem>
|
||||
#include <opencv2/opencv.hpp>
|
||||
#define SDL_MAIN_HANDLED
|
||||
#include <SDL2/SDL.h>
|
||||
|
||||
#include "util.h"
|
||||
#include "decoder.h"
|
||||
#include "videoDecoder.h"
|
||||
#include "shaderService.h"
|
||||
#include "shader.h"
|
||||
using std::cout;
|
||||
@ -151,7 +152,8 @@ void OpenglRenderVideo(VideoParam& videoParam, const OpenglVideoParam& openglVid
|
||||
glDrawElements(GL_TRIANGLES, 6, GL_UNSIGNED_INT, nullptr);
|
||||
}
|
||||
|
||||
int main(int argc, char** const argv)
|
||||
|
||||
int main(int argc, char** argv)
|
||||
{
|
||||
// Check File
|
||||
const char* targetFilepath = argv[1];
|
||||
|
@ -1,4 +1,4 @@
|
||||
#include "decoder.h"
|
||||
#include "videoDecoder.h"
|
||||
#include <thread>
|
||||
#include <chrono>
|
||||
using namespace std::literals::chrono_literals;
|
||||
@ -37,6 +37,7 @@ void RequestPacket(VideoParam& param) {
|
||||
std::this_thread::sleep_for(100ms);
|
||||
continue;
|
||||
}
|
||||
//FIX:
|
||||
const int ret = av_read_frame(fmtCtx, packet);
|
||||
if (param.eof) {
|
||||
std::this_thread::sleep_for(100ms);
|
Loading…
Reference in New Issue
Block a user