summaryrefslogtreecommitdiff
path: root/contrib/ffmpeg/libavcodec/rpza.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/ffmpeg/libavcodec/rpza.c')
-rw-r--r--contrib/ffmpeg/libavcodec/rpza.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/contrib/ffmpeg/libavcodec/rpza.c b/contrib/ffmpeg/libavcodec/rpza.c
index 8ab5dbb92..ea36393aa 100644
--- a/contrib/ffmpeg/libavcodec/rpza.c
+++ b/contrib/ffmpeg/libavcodec/rpza.c
@@ -17,7 +17,6 @@
* You should have received a copy of the GNU Lesser General Public
* License along with FFmpeg; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- *
*/
/**
@@ -40,7 +39,6 @@
#include <string.h>
#include <unistd.h>
-#include "common.h"
#include "avcodec.h"
#include "dsputil.h"
@@ -50,7 +48,7 @@ typedef struct RpzaContext {
DSPContext dsp;
AVFrame frame;
- unsigned char *buf;
+ const unsigned char *buf;
int size;
} RpzaContext;
@@ -232,11 +230,10 @@ static void rpza_decode_stream(RpzaContext *s)
static int rpza_decode_init(AVCodecContext *avctx)
{
- RpzaContext *s = (RpzaContext *)avctx->priv_data;
+ RpzaContext *s = avctx->priv_data;
s->avctx = avctx;
avctx->pix_fmt = PIX_FMT_RGB555;
- avctx->has_b_frames = 0;
dsputil_init(&s->dsp, avctx);
s->frame.data[0] = NULL;
@@ -246,9 +243,9 @@ static int rpza_decode_init(AVCodecContext *avctx)
static int rpza_decode_frame(AVCodecContext *avctx,
void *data, int *data_size,
- uint8_t *buf, int buf_size)
+ const uint8_t *buf, int buf_size)
{
- RpzaContext *s = (RpzaContext *)avctx->priv_data;
+ RpzaContext *s = avctx->priv_data;
s->buf = buf;
s->size = buf_size;
@@ -271,7 +268,7 @@ static int rpza_decode_frame(AVCodecContext *avctx,
static int rpza_decode_end(AVCodecContext *avctx)
{
- RpzaContext *s = (RpzaContext *)avctx->priv_data;
+ RpzaContext *s = avctx->priv_data;
if (s->frame.data[0])
avctx->release_buffer(avctx, &s->frame);