Revision fcc01ba5 src/Chunkiser/input-stream-avf.c

View differences:

src/Chunkiser/input-stream-avf.c
13 13
#include "chunkiser_iface.h"
14 14

  
15 15
#define STATIC_BUFF_SIZE 1000 * 1024
16
struct input_stream {
16
struct chunkiser_ctx {
17 17
  AVFormatContext *s;
18 18
  int loop;	//loop on input file infinitely
19 19
  int audio_stream;
......
106 106
  frame_header_write(data, size, pts, dts);
107 107
}
108 108

  
109
static int input_stream_rewind(struct input_stream *s)
109
static int input_stream_rewind(struct chunkiser_ctx *s)
110 110
{
111 111
    int ret;
112 112

  
......
119 119

  
120 120
/* Interface functions */
121 121

  
122
static struct input_stream *avf_open(const char *fname, int *period, const char *config)
122
static struct chunkiser_ctx *avf_open(const char *fname, int *period, const char *config)
123 123
{
124
  struct input_stream *desc;
124
  struct chunkiser_ctx *desc;
125 125
  int i, res;
126 126
  struct tag *cfg_tags;
127 127

  
128 128
  avcodec_register_all();
129 129
  av_register_all();
130 130

  
131
  desc = malloc(sizeof(struct input_stream));
131
  desc = malloc(sizeof(struct chunkiser_ctx));
132 132
  if (desc == NULL) {
133 133
    return NULL;
134 134
  }
......
182 182
  return desc;
183 183
}
184 184

  
185
static void avf_close(struct input_stream *s)
185
static void avf_close(struct chunkiser_ctx *s)
186 186
{
187 187
  int i;
188 188

  
......
195 195
  free(s);
196 196
}
197 197

  
198
static uint8_t *avf_chunkise(struct input_stream *s, int id, int *size, uint64_t *ts)
198
static uint8_t *avf_chunkise(struct chunkiser_ctx *s, int id, int *size, uint64_t *ts)
199 199
{
200 200
    AVPacket pkt;
201 201
    int res;

Also available in: Unified diff