Subversion Repositories Kolibri OS

Rev

Blame | Last modification | View Log | RSS feed

  1. /*
  2.  * Load all reference Y samples from neighboring macroblocks
  3.  * Copyright © <2010>, Intel Corporation.
  4.  *
  5.  * This program is licensed under the terms and conditions of the
  6.  * Eclipse Public License (EPL), version 1.0.  The full text of the EPL is at
  7.  * http://www.opensource.org/licenses/eclipse-1.0.php.
  8.  *
  9.  */
  10. #if !defined(__LOAD_INTRA_REF_Y__)              // Make sure this is only included once
  11. #define __LOAD_INTRA_REF_Y__
  12.  
  13. // Module name: load_Intra_Ref_Y.asm
  14. //
  15. // Load all reference Y samples from neighboring macroblocks
  16. //
  17. load_Intra_Ref_Y:
  18. //      shl (2) I_ORIX<1>:uw    ORIX<2;2,1>:ub  4:w             // Convert MB origin to pixel unit
  19.  
  20. // First load top 28x1 row reference samples
  21. // 4 from macroblock D (actually use 1), 16 from macroblock B, and 8 from macroblock C
  22. //
  23.     add (2)     MSGSRC.0<1>:d   I_ORIX<2;2,1>:w TOP_REF_OFFSET<2;2,1>:b {NoDDClr}       // Reference samples positioned at (-4, -1)
  24.     mov (1)     MSGSRC.2:ud             0x0000001B:ud {NoDDChk}                                                         // Block width and height (28x1)
  25.     add (1)     MSGDSC  REG_MBAFF_FIELD<0;1,0>:uw       RESP_LEN(1)+DWBRMSGDSC_RC+DESTY:ud  // Set message descriptor
  26.     send (8)    INTRA_REF_TOP_D(0)      MSGHDRY0        MSGSRC<8;8,1>:ud        DAPREAD MSGDSC
  27.  
  28. // Then load left 4x16 reference samples (actually use 1x16 column)
  29. //
  30.     add (1)     MSGSRC.1<1>:d   MSGSRC.1<0;1,0>:d       1:w {NoDDClr}   // Reference samples positioned next row
  31.     mov (1)     MSGSRC.2:ud             0x00F0003:ud    {NoDDChk}                       // Block width and height (4x16)
  32.     add (1)     MSGDSC                  MSGDSC  RESP_LEN(1):ud  // Need to read 1 more GRF register
  33.     send (8)    INTRA_REF_LEFT_D(0)     MSGHDRY1        MSGSRC<8;8,1>:ud        DAPREAD MSGDSC
  34.  
  35.         RETURN
  36. // End of load_Intra_Ref_Y
  37. #endif  // !defined(__LOAD_INTRA_REF_Y__)
  38.