mirror of
https://github.com/mpv-player/mpv
synced 2025-02-02 05:01:56 +00:00
stream_memory: remove trivial ffmpeg dependency
This commit is contained in:
parent
a5461b29c4
commit
6fdfa7c991
@ -15,8 +15,6 @@
|
|||||||
* License along with mpv. If not, see <http://www.gnu.org/licenses/>.
|
* License along with mpv. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <libavutil/common.h>
|
|
||||||
|
|
||||||
#include "common/common.h"
|
#include "common/common.h"
|
||||||
#include "stream.h"
|
#include "stream.h"
|
||||||
|
|
||||||
@ -30,7 +28,7 @@ static int fill_buffer(stream_t *s, char* buffer, int len)
|
|||||||
bstr data = p->data;
|
bstr data = p->data;
|
||||||
if (s->pos < 0 || s->pos > data.len)
|
if (s->pos < 0 || s->pos > data.len)
|
||||||
return 0;
|
return 0;
|
||||||
len = FFMIN(len, data.len - s->pos);
|
len = MPMIN(len, data.len - s->pos);
|
||||||
memcpy(buffer, data.start + s->pos, len);
|
memcpy(buffer, data.start + s->pos, len);
|
||||||
return len;
|
return len;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user