OSDN Git Service

i965_drv_video: add support for H264 on Clarkdale/Arrandale
[android-x86/hardware-intel-common-libva.git] / i965_drv_video / shaders / h264 / mc / save_8x8_UV.asm
1 /*\r
2  * Save decoded U/V picture data to frame buffer\r
3  * Copyright © <2010>, Intel Corporation.\r
4  *\r
5  * This program is licensed under the terms and conditions of the\r
6  * Eclipse Public License (EPL), version 1.0.  The full text of the EPL is at\r
7  * http://www.opensource.org/licenses/eclipse-1.0.php.\r
8  *\r
9  */\r
10 #if !defined(__SAVE_8x8_UV__)           // Make sure this is only included once\r
11 #define __SAVE_8x8_UV__\r
12 \r
13 // Module name: save_8x8_UV.asm\r
14 //\r
15 // Save decoded U/V picture data to frame buffer\r
16 //\r
17 \r
18     mov (1) MSGSRC.2:ud     0x0007000F:ud {NoDDClr}             // Block width and height (16x8)\r
19     mov (2) MSGSRC.0<1>:ud  I_ORIX<2;2,1>:w     {NoDDChk}       // I_ORIX has already been adjusted for NV12\r
20 \r
21 //  Update message descriptor based on previous read setup\r
22 //\r
23 #ifdef DEV_ILK\r
24     add (1)             MSGDSC  MSGDSC MSG_LEN(4)+DWBWMSGDSC_WC-DWBRMSGDSC_RC-0x00100000:ud  // Set message descriptor\r
25 #else\r
26     add (1)             MSGDSC  MSGDSC MSG_LEN(4)+DWBWMSGDSC_WC-DWBRMSGDSC_RC-0x00010000:ud  // Set message descriptor\r
27 #endif  // DEV_ILK\r
28 \r
29 // Write U/V picture data\r
30 //\r
31 #ifndef MONO\r
32     mov     MSGPAYLOAD(0,0)<1>  DEC_UV(0)REGION(16,2)   // U/V row 0\r
33     mov     MSGPAYLOAD(0,16)<1> DEC_UV(1)REGION(16,2)   // U/V row 1\r
34     mov     MSGPAYLOAD(1,0)<1>  DEC_UV(2)REGION(16,2)   // U/V row 2\r
35     mov     MSGPAYLOAD(1,16)<1> DEC_UV(3)REGION(16,2)   // U/V row 3\r
36     mov     MSGPAYLOAD(2,0)<1>  DEC_UV(4)REGION(16,2)   // U/V row 4\r
37     mov     MSGPAYLOAD(2,16)<1> DEC_UV(5)REGION(16,2)   // U/V row 5\r
38     mov     MSGPAYLOAD(3,0)<1>  DEC_UV(6)REGION(16,2)   // U/V row 6\r
39     mov     MSGPAYLOAD(3,16)<1> DEC_UV(7)REGION(16,2)   // U/V row 7\r
40 #else   // defined(MONO)\r
41     $for(0; <4; 2) {\r
42         mov (16)        MSGPAYLOADD(%1)<1>              0x80808080:ud {Compr}\r
43         }\r
44 \r
45 #endif  // !defined(MONO)\r
46 \r
47         send (8)        REG_WRITE_COMMIT_UV<1>:ud       MSGHDR  MSGSRC<8;8,1>:ud        DAPWRITE        MSGDSC\r
48 \r
49 // End of save_8x8_UV\r
50 \r
51 #endif  // !defined(__SAVE_8x8_UV__)\r