mirror of https://github.com/mpv-player/mpv
stream.h: Add 2 prototypes instead of declaring them in cache2.c
Declare stream_fill_buffer() and stream_seek_long() always (before they were only declared if cache was disabled and those were used instead of cached versions). Remove the now redundant declarations in cache2.c.
This commit is contained in:
parent
17d3e4b36d
commit
0d09176078
|
@ -35,9 +35,6 @@ static void ThreadProc( void *s );
|
|||
#include "stream.h"
|
||||
extern int use_gui;
|
||||
|
||||
int stream_fill_buffer(stream_t *s);
|
||||
int stream_seek_long(stream_t *s,off_t pos);
|
||||
|
||||
typedef struct {
|
||||
// constats:
|
||||
unsigned char *buffer; // base pointer of the alllocated buffer memory
|
||||
|
|
|
@ -119,14 +119,14 @@ typedef struct stream {
|
|||
unsigned char buffer[STREAM_BUFFER_SIZE>VCD_SECTOR_SIZE?STREAM_BUFFER_SIZE:VCD_SECTOR_SIZE];
|
||||
} stream_t;
|
||||
|
||||
int stream_fill_buffer(stream_t *s);
|
||||
int stream_seek_long(stream_t *s,off_t pos);
|
||||
#ifdef CONFIG_STREAM_CACHE
|
||||
int stream_enable_cache(stream_t *stream,int size,int min,int prefill);
|
||||
int cache_stream_fill_buffer(stream_t *s);
|
||||
int cache_stream_seek_long(stream_t *s,off_t pos);
|
||||
#else
|
||||
// no cache, define wrappers:
|
||||
int stream_fill_buffer(stream_t *s);
|
||||
int stream_seek_long(stream_t *s,off_t pos);
|
||||
#define cache_stream_fill_buffer(x) stream_fill_buffer(x)
|
||||
#define cache_stream_seek_long(x,y) stream_seek_long(x,y)
|
||||
#define stream_enable_cache(x,y,z,w) 1
|
||||
|
|
Loading…
Reference in New Issue