Merge remote-tracking branch 'newdev/master'
* newdev/master: dsputil: allow to skip drawing of top/bottom edges. Split fate-psx-str-v3 into a video-only and audio-only test. Conflicts: libavcodec/dsputil.c libavcodec/mpegvideo.c libavcodec/snow.c libavcodec/x86/dsputil_mmx.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
commit
3c8493074b
@ -303,12 +303,6 @@ static void draw_edges_c(uint8_t *buf, int wrap, int width, int height, int w, i
|
||||
uint8_t *ptr, *last_line;
|
||||
int i;
|
||||
|
||||
last_line = buf + (height - 1) * wrap;
|
||||
for(i=0;i<w;i++) {
|
||||
/* top and bottom */
|
||||
if (sides&EDGE_TOP) memcpy(buf - (i + 1) * wrap, buf, width);
|
||||
if (sides&EDGE_BOTTOM) memcpy(last_line + (i + 1) * wrap, last_line, width);
|
||||
}
|
||||
/* left and right */
|
||||
ptr = buf;
|
||||
for(i=0;i<height;i++) {
|
||||
@ -316,18 +310,16 @@ static void draw_edges_c(uint8_t *buf, int wrap, int width, int height, int w, i
|
||||
memset(ptr + width, ptr[width-1], w);
|
||||
ptr += wrap;
|
||||
}
|
||||
/* corners */
|
||||
for(i=0;i<w;i++) {
|
||||
if (sides&EDGE_TOP) {
|
||||
memset(buf - (i + 1) * wrap - w, buf[0], w); /* top left */
|
||||
memset(buf - (i + 1) * wrap + width, buf[width-1], w); /* top right */
|
||||
}
|
||||
|
||||
if (sides&EDGE_BOTTOM) {
|
||||
memset(last_line + (i + 1) * wrap - w, last_line[0], w); /* top left */
|
||||
memset(last_line + (i + 1) * wrap + width, last_line[width-1], w); /* top right */
|
||||
}
|
||||
}
|
||||
/* top and bottom + corners */
|
||||
buf -= w;
|
||||
last_line = buf + (height - 1) * wrap;
|
||||
if (sides & EDGE_TOP)
|
||||
for(i = 0; i < w; i++)
|
||||
memcpy(buf - (i + 1) * wrap, buf, width + w + w); // top
|
||||
if (sides & EDGE_BOTTOM)
|
||||
for (i = 0; i < w; i++)
|
||||
memcpy(last_line + (i + 1) * wrap, last_line, width + w + w); // bottom
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1165,9 +1165,9 @@ void MPV_frame_end(MpegEncContext *s)
|
||||
&& !(s->flags&CODEC_FLAG_EMU_EDGE)) {
|
||||
int edges = EDGE_BOTTOM | EDGE_TOP, h = s->v_edge_pos;
|
||||
|
||||
s->dsp.draw_edges(s->current_picture_ptr->data[0], s->linesize , s->h_edge_pos , h , EDGE_WIDTH , edges);
|
||||
s->dsp.draw_edges(s->current_picture_ptr->data[1], s->uvlinesize, s->h_edge_pos>>1, h>>1, EDGE_WIDTH/2, edges);
|
||||
s->dsp.draw_edges(s->current_picture_ptr->data[2], s->uvlinesize, s->h_edge_pos>>1, h>>1, EDGE_WIDTH/2, edges);
|
||||
s->dsp.draw_edges(s->current_picture.data[0], s->linesize , s->h_edge_pos , h , EDGE_WIDTH , edges);
|
||||
s->dsp.draw_edges(s->current_picture.data[1], s->uvlinesize, s->h_edge_pos>>1, h>>1, EDGE_WIDTH/2, edges);
|
||||
s->dsp.draw_edges(s->current_picture.data[2], s->uvlinesize, s->h_edge_pos>>1, h>>1, EDGE_WIDTH/2, edges);
|
||||
|
||||
}
|
||||
|
||||
|
@ -836,9 +836,9 @@ static void draw_edges_mmx(uint8_t *buf, int wrap, int width, int height, int w,
|
||||
);
|
||||
}
|
||||
|
||||
for(i=0;i<w;i+=4) {
|
||||
/* top and bottom (and hopefully also the corners) */
|
||||
if (sides&EDGE_TOP) {
|
||||
/* top and bottom (and hopefully also the corners) */
|
||||
if (sides&EDGE_TOP) {
|
||||
for(i = 0; i < w; i += 4) {
|
||||
ptr= buf - (i + 1) * wrap - w;
|
||||
__asm__ volatile(
|
||||
"1: \n\t"
|
||||
@ -854,8 +854,10 @@ static void draw_edges_mmx(uint8_t *buf, int wrap, int width, int height, int w,
|
||||
: "r" ((x86_reg)buf - (x86_reg)ptr - w), "r" ((x86_reg)-wrap), "r" ((x86_reg)-wrap*3), "r" (ptr+width+2*w)
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
if (sides&EDGE_BOTTOM) {
|
||||
if (sides&EDGE_BOTTOM) {
|
||||
for(i = 0; i < w; i += 4) {
|
||||
ptr= last_line + (i + 1) * wrap - w;
|
||||
__asm__ volatile(
|
||||
"1: \n\t"
|
||||
|
@ -204,8 +204,10 @@ FATE_TESTS += fate-pcm_dvd
|
||||
fate-pcm_dvd: CMD = framecrc -i $(SAMPLES)/pcm-dvd/coolitnow-partial.vob -vn
|
||||
FATE_TESTS += fate-psx-str
|
||||
fate-psx-str: CMD = framecrc -i $(SAMPLES)/psx-str/descent-partial.str
|
||||
FATE_TESTS += fate-psx-str-v3
|
||||
fate-psx-str-v3: CMD = framecrc -i $(SAMPLES)/psx-str/abc000_cut.str
|
||||
FATE_TESTS += fate-psx-str-v3-mdec
|
||||
fate-psx-str-v3-mdec: CMD = framecrc -i $(SAMPLES)/psx-str/abc000_cut.str -an
|
||||
FATE_TESTS += fate-psx-str-v3-adpcm_xa
|
||||
fate-psx-str-v3-adpcm_xa: CMD = framecrc -i $(SAMPLES)/psx-str/abc000_cut.str -vn
|
||||
FATE_TESTS += fate-ptx
|
||||
fate-ptx: CMD = framecrc -i $(SAMPLES)/ptx/_113kw_pic.ptx -pix_fmt rgb24
|
||||
FATE_TESTS += fate-pva-demux
|
||||
|
37
tests/ref/fate/psx-str-v3-adpcm_xa
Normal file
37
tests/ref/fate/psx-str-v3-adpcm_xa
Normal file
@ -0,0 +1,37 @@
|
||||
0, 0, 8064, 0xa307ed8c
|
||||
0, 4800, 8064, 0xd2551927
|
||||
0, 9600, 8064, 0x3264a799
|
||||
0, 14400, 8064, 0x75da1393
|
||||
0, 19200, 8064, 0x68665f59
|
||||
0, 24000, 8064, 0xaf266a18
|
||||
0, 28800, 8064, 0x4d4b69fd
|
||||
0, 33600, 8064, 0x129d7e17
|
||||
0, 38400, 8064, 0x78c56725
|
||||
0, 43200, 8064, 0x59902cf1
|
||||
0, 48000, 8064, 0x6e699c87
|
||||
0, 52800, 8064, 0xc30692d7
|
||||
0, 57600, 8064, 0x29c043e5
|
||||
0, 62400, 8064, 0x61907704
|
||||
0, 67200, 8064, 0xf9210630
|
||||
0, 72000, 8064, 0xc0bdda08
|
||||
0, 76800, 8064, 0x6171b96d
|
||||
0, 81600, 8064, 0x082947cf
|
||||
0, 86400, 8064, 0xf7bbf1ce
|
||||
0, 91200, 8064, 0xe50e4436
|
||||
0, 96000, 8064, 0x2a860844
|
||||
0, 100800, 8064, 0xedcb502c
|
||||
0, 105600, 8064, 0x448e3c7f
|
||||
0, 110400, 8064, 0xf782f366
|
||||
0, 115200, 8064, 0xf57f66a5
|
||||
0, 120000, 8064, 0xdcc36939
|
||||
0, 124800, 8064, 0x34959d99
|
||||
0, 129600, 8064, 0xa5c20433
|
||||
0, 134400, 8064, 0xf1364e9b
|
||||
0, 139200, 8064, 0x232fe9c7
|
||||
0, 144000, 8064, 0xdc068d5a
|
||||
0, 148800, 8064, 0x4962e812
|
||||
0, 153600, 8064, 0x36a6709b
|
||||
0, 158400, 8064, 0xa2837bd8
|
||||
0, 163200, 8064, 0x68612ddb
|
||||
0, 168000, 8064, 0x8d76d1cb
|
||||
0, 172800, 8064, 0x7707cfc7
|
@ -1,69 +1,32 @@
|
||||
0, 0, 76800, 0x2677be82
|
||||
1, 0, 8064, 0xa307ed8c
|
||||
1, 4800, 8064, 0xd2551927
|
||||
0, 6000, 76800, 0x1f323c75
|
||||
1, 9600, 8064, 0x3264a799
|
||||
0, 12000, 76800, 0xc8be3be9
|
||||
1, 14400, 8064, 0x75da1393
|
||||
0, 18000, 76800, 0x1f323c75
|
||||
1, 19200, 8064, 0x68665f59
|
||||
0, 24000, 76800, 0x7e484488
|
||||
1, 24000, 8064, 0xaf266a18
|
||||
1, 28800, 8064, 0x4d4b69fd
|
||||
0, 30000, 76800, 0x8bd644aa
|
||||
1, 33600, 8064, 0x129d7e17
|
||||
0, 36000, 76800, 0xaa62e7b8
|
||||
1, 38400, 8064, 0x78c56725
|
||||
0, 42000, 76800, 0xaa62e7b8
|
||||
1, 43200, 8064, 0x59902cf1
|
||||
0, 48000, 76800, 0x53fadb39
|
||||
1, 48000, 8064, 0x6e699c87
|
||||
1, 52800, 8064, 0xc30692d7
|
||||
0, 54000, 76800, 0x53fadb39
|
||||
1, 57600, 8064, 0x29c043e5
|
||||
0, 60000, 76800, 0x1ff9d964
|
||||
1, 62400, 8064, 0x61907704
|
||||
0, 66000, 76800, 0x1ff9d964
|
||||
1, 67200, 8064, 0xf9210630
|
||||
0, 72000, 76800, 0xd8c8d947
|
||||
1, 72000, 8064, 0xc0bdda08
|
||||
1, 76800, 8064, 0x6171b96d
|
||||
0, 78000, 76800, 0xd8c8d947
|
||||
1, 81600, 8064, 0x082947cf
|
||||
0, 84000, 76800, 0x6d0bd94c
|
||||
1, 86400, 8064, 0xf7bbf1ce
|
||||
0, 90000, 76800, 0x6d0bd94c
|
||||
1, 91200, 8064, 0xe50e4436
|
||||
0, 96000, 76800, 0x7e66d948
|
||||
1, 96000, 8064, 0x2a860844
|
||||
1, 100800, 8064, 0xedcb502c
|
||||
0, 102000, 76800, 0x7e66d948
|
||||
1, 105600, 8064, 0x448e3c7f
|
||||
0, 108000, 76800, 0x8eecfd72
|
||||
1, 110400, 8064, 0xf782f366
|
||||
0, 114000, 76800, 0xb15f29ab
|
||||
1, 115200, 8064, 0xf57f66a5
|
||||
0, 120000, 76800, 0x08e5502e
|
||||
1, 120000, 8064, 0xdcc36939
|
||||
1, 124800, 8064, 0x34959d99
|
||||
0, 126000, 76800, 0xaa58796d
|
||||
1, 129600, 8064, 0xa5c20433
|
||||
0, 132000, 76800, 0xe254a27c
|
||||
1, 134400, 8064, 0xf1364e9b
|
||||
0, 138000, 76800, 0xeec8cf68
|
||||
1, 139200, 8064, 0x232fe9c7
|
||||
0, 144000, 76800, 0x812bf8ee
|
||||
1, 144000, 8064, 0xdc068d5a
|
||||
1, 148800, 8064, 0x4962e812
|
||||
0, 150000, 76800, 0x929922ef
|
||||
1, 153600, 8064, 0x36a6709b
|
||||
0, 156000, 76800, 0xe1174e06
|
||||
1, 158400, 8064, 0xa2837bd8
|
||||
0, 162000, 76800, 0x2da77bf1
|
||||
1, 163200, 8064, 0x68612ddb
|
||||
0, 168000, 76800, 0xd0f6a727
|
||||
1, 168000, 8064, 0x8d76d1cb
|
||||
1, 172800, 8064, 0x7707cfc7
|
||||
0, 174000, 76800, 0x31bfd168
|
||||
0, 180000, 76800, 0xb87af225
|
||||
0, 186000, 76800, 0xd0080859
|
Loading…
x
Reference in New Issue
Block a user