mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 18:31:55 -04:00
New ffmpeg function
This commit is contained in:
parent
f9e03850dd
commit
5a4eff9759
@ -120,8 +120,9 @@ open_vfs(const Filename &filename) {
|
|||||||
|
|
||||||
// Now we can open the stream.
|
// Now we can open the stream.
|
||||||
int result =
|
int result =
|
||||||
av_open_input_file(&_format_context, url.c_str(), NULL, 0, NULL);
|
avformat_open_input(&_format_context, url.c_str(), NULL, NULL);
|
||||||
if (result < 0) {
|
if (result < 0) {
|
||||||
|
_format_context = NULL;
|
||||||
close();
|
close();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -176,8 +177,9 @@ open_subfile(const SubfileInfo &info) {
|
|||||||
|
|
||||||
// Now we can open the stream.
|
// Now we can open the stream.
|
||||||
int result =
|
int result =
|
||||||
av_open_input_file(&_format_context, url.c_str(), NULL, 0, NULL);
|
avformat_open_input(&_format_context, url.c_str(), NULL, NULL);
|
||||||
if (result < 0) {
|
if (result < 0) {
|
||||||
|
_format_context = NULL;
|
||||||
close();
|
close();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user