Compare commits
9 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
9153b33a74 | ||
![]() |
a907fc0b21 | ||
![]() |
d77ad6ec2d | ||
![]() |
e122fb594a | ||
![]() |
359383c983 | ||
![]() |
e7f5dacd55 | ||
![]() |
6a968073da | ||
![]() |
c1ac5896ef | ||
![]() |
9c7321e2b8 |
2
Doxyfile
2
Doxyfile
@@ -31,7 +31,7 @@ PROJECT_NAME = FFmpeg
|
||||
# This could be handy for archiving the generated documentation or
|
||||
# if some version control system is used.
|
||||
|
||||
PROJECT_NUMBER = 0.10.13
|
||||
PROJECT_NUMBER = 0.10.14
|
||||
|
||||
# With the PROJECT_LOGO tag one can specify an logo or icon that is included
|
||||
# in the documentation. The maximum height of the logo should not exceed 55
|
||||
|
@@ -247,6 +247,8 @@ static int decode_frame(AVCodecContext *avctx,
|
||||
static av_cold int sgi_init(AVCodecContext *avctx){
|
||||
SgiState *s = avctx->priv_data;
|
||||
|
||||
s->avctx = avctx;
|
||||
|
||||
avcodec_get_frame_defaults(&s->picture);
|
||||
avctx->coded_frame = &s->picture;
|
||||
|
||||
@@ -263,15 +265,6 @@ static av_cold int sgi_end(AVCodecContext *avctx)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static av_cold int sgi_decode_init(AVCodecContext *avctx)
|
||||
{
|
||||
SgiState *s = avctx->priv_data;
|
||||
|
||||
s->avctx = avctx;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
AVCodec ff_sgi_decoder = {
|
||||
.name = "sgi",
|
||||
.type = AVMEDIA_TYPE_VIDEO,
|
||||
@@ -280,7 +273,6 @@ AVCodec ff_sgi_decoder = {
|
||||
.init = sgi_init,
|
||||
.close = sgi_end,
|
||||
.decode = decode_frame,
|
||||
.init = sgi_decode_init,
|
||||
.long_name = NULL_IF_CONFIG_SMALL("SGI image"),
|
||||
};
|
||||
|
||||
|
@@ -62,7 +62,13 @@ static inline int get_byte(LZOContext *c) {
|
||||
static inline int get_len(LZOContext *c, int x, int mask) {
|
||||
int cnt = x & mask;
|
||||
if (!cnt) {
|
||||
while (!(x = get_byte(c))) cnt += 255;
|
||||
while (!(x = get_byte(c))) {
|
||||
if (cnt >= INT_MAX - 1000) {
|
||||
c->error |= AV_LZO_ERROR;
|
||||
break;
|
||||
}
|
||||
cnt += 255;
|
||||
}
|
||||
cnt += mask + x;
|
||||
}
|
||||
return cnt;
|
||||
@@ -88,6 +94,10 @@ static inline int get_len(LZOContext *c, int x, int mask) {
|
||||
static inline void copy(LZOContext *c, int cnt) {
|
||||
register const uint8_t *src = c->in;
|
||||
register uint8_t *dst = c->out;
|
||||
if (cnt < 0) {
|
||||
c->error |= AV_LZO_ERROR;
|
||||
return;
|
||||
}
|
||||
if (cnt > c->in_end - src) {
|
||||
cnt = FFMAX(c->in_end - src, 0);
|
||||
c->error |= AV_LZO_INPUT_DEPLETED;
|
||||
@@ -113,13 +123,17 @@ static inline void memcpy_backptr(uint8_t *dst, int back, int cnt);
|
||||
/**
|
||||
* @brief Copies previously decoded bytes to current position.
|
||||
* @param back how many bytes back we start, must be > 0
|
||||
* @param cnt number of bytes to copy, must be >= 0
|
||||
* @param cnt number of bytes to copy, must be > 0
|
||||
*
|
||||
* cnt > back is valid, this will copy the bytes we just copied,
|
||||
* thus creating a repeating pattern with a period length of back.
|
||||
*/
|
||||
static inline void copy_backptr(LZOContext *c, int back, int cnt) {
|
||||
register uint8_t *dst = c->out;
|
||||
if (cnt <= 0) {
|
||||
c->error |= AV_LZO_ERROR;
|
||||
return;
|
||||
}
|
||||
if (dst - c->out_start < back) {
|
||||
c->error |= AV_LZO_INVALID_BACKPTR;
|
||||
return;
|
||||
|
Reference in New Issue
Block a user