# US 10,123,045 B2 · Modification to block size for transform mode in display stream compression

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 10,123,045 B2
- Document ID: US10123045B2
- Status: Granted
- Kind: B2
- Application number: 15/213,966
- Filed: 2016-07-19
- Published: 2017-01-26
- Granted: 2018-11-06
- Earliest claimed: 2015-07-24
- Assignees: QUALCOMM Incorporated
- Applicants: QUALCOMM Incorporated
- Inventors: Vijayaraghavan Thirumalai; Natan Haim Jacobson; Rajan Laxman Joshi
- Web page: https://patentgrep.com/patent/US10123045B2

## CPC

- H04N 19/60: using transform coding
- H04N 19/122: Selection of transform size, e.g. 8x8 or 2x4x8 DCT; Selection of sub-band transforms of varying structure or type
- H04N 19/14: Coding unit complexity, e.g. amount of activity or edge presence estimation (H04N19/146 takes precedence)
- H04N 19/147: according to rate distortion criteria (rate-distortion as a criterion for motion estimation H04N19/567)
- H04N 19/154: Measured or subjectively estimated visual quality after decoding, e.g. measurement of distortion (use of rate-distortion criteria H04N19/147)
- H04N 19/167: Position within a video image, e.g. region of interest [ROI]
- H04N 19/176: the region being a block, e.g. a macroblock
- H04N: PICTORIAL COMMUNICATION, e.g. TELEVISION

## Abstract

Methods and apparatuses for modification to block size for transform mode in display stream compression are disclosed. In one aspect, the method involves selecting a current block and a next block of video data, calculating a first rate-distortion (RD) cost for coding the current and next blocks with a larger block size transform (LBT) mode, and calculating a second RD cost for coding each of the current and next blocks with another coding mode different from the LBT mode. The method may further involve determining whether the first RD cost is less than a sum of the second RD costs for the current and next blocks and coding the current and next blocks with the LBT mode in response to the first RD cost being less than the sum of the second RD costs for the current and next blocks.

## Claims

### Claim 1

A method operable by a video coding circuit for selecting a coding mode from a plurality of coding modes for coding video data, the method comprising:
selecting a current block and a next block of the video data, wherein the current and next blocks each have a size of P×Q;
determining whether to evaluate larger block size transform (LBT) mode coding performance based on one or more conditions of a plurality of conditions being satisfied for either of the current or next blocks, wherein the plurality of conditions comprises (i) pattern mode is determined to be an optimal coding mode, (ii) a flat block is detected, (iii) a transition from complex to flat region is detected, and (iv) a transition from flat to complex region is detected;
in response to determining to evaluate LBT mode coding performance, calculating a first rate-distortion (RD) cost for coding samples in the current and next blocks together with a LBT mode, wherein the LBT mode operates on a LBT size of P×M, wherein M>Q;
calculating second RD costs for coding each of the current and next blocks individually with a second coding mode different from the LBT mode, wherein calculating the second RD costs comprises calculating, for each of the current and next blocks, a respective second RD cost for coding a respective block individually with the second coding mode;
determining whether the first RD cost is less than a sum of the second RD costs for the current and next blocks; and
coding the samples in the current and next blocks with the LBT mode in response to the first RD cost being less than the sum of the second RD costs for the current and next blocks.

### Claim 2 (depends on 1)

The method of claim 1, further comprising:
selecting an additional block of the video data in response to the first RD cost being less than the sum of the second RD costs;
calculating an updated first RD cost for coding samples in the current, next, and additional blocks together with the LBT mode;
calculating a third RD cost for coding the additional block with the second coding mode;
determining whether the updated first RD cost is less than a sum of the second RD costs for the current and next blocks and the third RD cost for the additional block; and
coding the current, next, and additional blocks with the LBT mode in response to the updated first RD cost being less than the sum of the second RD costs for the current and next blocks and the third RD cost for the additional block.

### Claim 3 (depends on 2)

The method of claim 2, further comprising coding the current and next blocks with the LBT mode in response to: i) the first RD cost being less than the sum of the second RD costs for the current and next blocks and ii) the updated first RD cost being not less than the sum of the second RD costs for the current, next, and additional blocks.

### Claim 4 (depends on 1)

The method of claim 1, further comprising coding the current block with the second coding mode in response to the first RD cost not being less than the sum of the second RD costs for the current and next blocks.

### Claim 5 (depends on 1)

The method of claim 1, wherein calculating the second RD costs for coding each of the current and next blocks with the second coding mode comprises:
calculating a plurality of third RD costs for coding the current block with each of the plurality of coding modes other than the LBT mode;
determining a lowest third RD cost from the calculated third RD costs;
calculating a plurality of fourth RD costs for coding the next block with each of the plurality of coding modes other than the LBT modes; and
determining a lowest fourth RD cost from the calculated fourth RD costs,
wherein the sum of the second RD costs is the sum of the lowest third RD cost and the lowest fourth RD cost.

### Claim 6 (depends on 1)

The method of claim 1, further comprising refraining from calculating the first RD cost in response to one or more of the following conditions being satisfied for either of the current or next blocks (i) pattern mode is determined to be an optimal coding mode, (ii) a flat block is detected, (iii) a transition from complex to flat region is detected, and (iv) a transition from flat to complex region is detected.

### Claim 7 (depends on 1)

The method of claim 1, further comprising:
calculating a third RD cost for coding a minimum number (Mmin) of blocks starting from the current block with the LBT mode;
calculating a fourth RD cost for coding each of the Mmin blocks with the second coding mode;
determining whether the third RD cost is less than a sum of the fourth RD costs for the Mmin blocks; and
coding the Mmin blocks with the LBT mode in response to the third RD cost being less than the sum of the fourth RD costs for the Mmin blocks.

### Claim 8 (depends on 7)

The method of claim 7, further comprising:
selecting an additional block of the video data in response to the third RD cost being less than the sum of the fourth RD costs;
calculating an updated third RD cost for coding the Mmin blocks and the additional block with the LBT mode;
calculating a fourth RD cost for coding the additional block with the second coding mode;
determining whether the updated third RD cost is less than a sum of the fourth RD costs for the Mmin blocks and the additional block; and
coding the Mmin blocks and the additional block with the LBT mode in response to the updated third RD cost being less than the sum of the fourth RD costs for the Mmin blocks and the additional block.

### Claim 9 (depends on 8)

The method of claim 8, further comprising:
determining whether adding another additional block to the Mmin blocks and the additional block would reach an LBT block size of greater than Mmax; and
in response to determining that adding another additional block to the Mmin blocks and the additional block would reach an LBT block size of greater than Mmax, refraining from adding the another additional block to the Mmin blocks and the additional block.

### Claim 10

A device for selecting a coding mode from a plurality of coding modes for coding video data, comprising:
a memory configured to store video data including a previous block and a current block; and
at least one processor circuit coupled to the memory and configured to:
select a current block and a next block of the video data, wherein the current and next blocks each have a size of P×Q;
determine whether to evaluate larger block size transform (LBT) mode coding performance based on one or more conditions of a plurality of conditions being satisfied for either of the current or next blocks, wherein the plurality of conditions comprises (i) pattern mode is determined to be an optimal coding mode, (ii) a flat block is detected, (iii) a transition from complex to flat region is detected, and (iv) a transition from flat to complex region is detected;
in response to determining to evaluate LBT mode coding performance, calculate a first rate-distortion (RD) cost for coding samples in the current and next blocks together with a LBT mode, wherein the LBT mode operates on a LBT size of P×M, wherein M>Q;
calculate second RD costs for coding each of the current and next blocks individually with a second coding mode different from the LBT mode, wherein to calculate the second RD costs, the processor circuit is configured to calculate, for each of the current and next blocks, a respective second RD cost for coding a respective block individually with the second coding mode;
determine whether the first RD cost is less than a sum of the second RD costs for the current and next blocks; and
code the samples in the current and next blocks with the LBT mode in response to the first RD cost being less than the sum of the second RD costs for the current and next blocks.

### Claim 11 (depends on 10)

The device of claim 10, wherein the processor circuit is further configured to:
select an additional block of the video data in response to the first RD cost being less than the sum of the second RD costs;
calculate an updated first RD cost for coding samples in the current, next, and additional blocks together with the LBT mode;
calculate a third RD cost for coding the additional block with the second coding mode;
determine whether the updated first RD cost is less than a sum of the second RD costs for the current and next blocks and the third RD cost for the additional block; and
code the current, next, and additional blocks with the LBT mode in response to the updated first RD cost being less than the sum of the second RD costs for the current and next blocks and the third RD cost for the additional block.

### Claim 12 (depends on 11)

The device of claim 11, wherein the processor circuit is further configured to code the current and next blocks with the LBT mode in response to: i) the first RD cost being less than the sum of the second RD costs for the current and next blocks and ii) the updated first RD cost being not less than the sum of the second RD costs for the current, next, and additional blocks.

### Claim 13 (depends on 10)

The device of claim 10, wherein the processor circuit is further configured to code the current block with the second coding mode in response to the first RD cost not being less than the sum of the second RD costs for the current and next blocks.

### Claim 14 (depends on 10)

The device of claim 10, wherein the processor circuit is further configured to:
calculate a plurality of third RD costs for coding the current block with each of the plurality of coding modes other than the LBT mode;
determine a lowest third RD cost from the calculated third RD costs;
calculate a plurality of fourth RD costs for coding the next block with each of the plurality of coding modes other than the LBT modes; and
determine a lowest fourth RD cost from the calculated fourth RD costs,
wherein the sum of the second RD costs is the sum of the lowest third RD cost and the lowest fourth RD cost.

### Claim 15 (depends on 10)

The device of claim 10, wherein the processor circuit is further configured to refrain from calculating the first RD cost in response to one or more of the following conditions being satisfied for either of the current or next blocks (i) pattern mode is determined to be an optimal coding mode, (ii) a flat block is detected, (iii) a transition from complex to flat region is detected, and (iv) a transition from flat to complex region is detected.

### Claim 16 (depends on 10)

The device of claim 10, wherein the processor circuit is further configured to:
calculate a third RD cost for coding a minimum number (Mmin) of blocks starting from the current block with the LBT mode;
calculate a fourth RD cost for coding each of the Mmin blocks with the second coding mode;
determine whether the third RD cost is less than a sum of the fourth RD costs for the Mmin blocks; and
code the Mmin blocks with the LBT mode in response to the third RD cost being less than the sum of the fourth RD costs for the Mmin blocks.

### Claim 17 (depends on 16)

The device of claim 16, wherein the processor circuit is further configured to:
select an additional block of the video data in response to the third RD cost being less than the sum of the fourth RD costs;
calculate an updated third RD cost for coding the Mmin blocks and the additional block with the LBT mode;
calculate a fourth RD cost for coding the additional block with the second coding mode;
determine whether the updated third RD cost is less than a sum of the fourth RD costs for the Mmin blocks and the additional block; and
code the Mmin blocks and the additional block with the LBT mode in response to the updated third RD cost being less than the sum of the fourth RD costs for the Mmin blocks and the additional block.

### Claim 18

An apparatus, comprising:
means for selecting a current block and a next block of the video data, wherein the current and next blocks each have a size of P×Q;
means for determining whether to evaluate larger block size transform (LBT) mode coding performance based on one or more conditions of a plurality of conditions being satisfied for either of the current or next blocks, wherein the plurality of conditions comprises (i) pattern mode is determined to be an optimal coding mode, (ii) a flat block is detected, (iii) a transition from complex to flat region is detected, and (iv) a transition from flat to complex region is detected;
means for calculating a first rate-distortion (RD) cost for coding samples in the current and next blocks together with a LBT mode in response to determining to evaluate LBT mode coding performance, wherein the LBT mode operates on a LBT size of P×M, wherein M>Q;
means for calculating second RD costs for coding each of the current and next blocks individually with a second coding mode different from the LBT mode, wherein the means for calculating the second RD costs comprises means for calculating, for each of the current and next blocks, a respective second RD cost for coding a respective block individually with the second coding mode;
means for determining whether the first RD cost is less than a sum of the second RD costs for the current and next blocks; and
means for coding the samples in the current and next blocks with the LBT mode in response to the first RD cost being less than the sum of the second RD costs for the current and next blocks.

### Claim 19 (depends on 18)

The apparatus of claim 18, further comprising:
means for selecting an additional block of the video data in response to the first RD cost being less than the sum of the second RD costs;
means for calculating an updated first RD cost for coding samples in the current, next, and additional blocks together with the LBT mode;
means for calculating a third RD cost for coding the additional block with the second coding mode;
means for determining whether the updated first RD cost is less than a sum of the second RD costs for the current and next blocks and the third RD cost for the additional block; and
means for coding the current, next, and additional blocks with the LBT mode in response to the updated first RD cost being less than the sum of the second RD costs for the current and next blocks and the third RD cost for the additional block.

### Claim 20 (depends on 19)

The apparatus of claim 19, further comprising means for coding the current and next blocks with the LBT mode in response to: i) the first RD cost being less than the sum of the second RD costs for the current and next blocks and ii) the updated first RD cost being not less than the sum of the second RD costs for the current, next, and additional blocks.

### Claim 21 (depends on 18)

The apparatus of claim 18, further comprising means for coding the current block with the second coding mode in response to the first RD cost not being less than the sum of the second RD costs for the current and next blocks.

### Claim 22 (depends on 18)

The apparatus of claim 18, further comprising:
means for calculating a plurality of third RD costs for coding the current block with each of the plurality of coding modes other than the LBT mode;
means for determining a lowest third RD cost from the calculated third RD costs;
means for calculating a plurality of fourth RD costs for coding the next block with each of the plurality of coding modes other than the LBT modes; and
means for determining a lowest fourth RD cost from the calculated fourth RD costs,
wherein the sum of the second RD costs is the sum of the lowest third RD cost and the lowest fourth RD cost.

### Claim 23 (depends on 18)

The apparatus of claim 18, further comprising means for refraining from calculating the first RD cost in response to one or more of the following conditions being satisfied for either of the current or next blocks (i) pattern mode is determined to be an optimal coding mode, (ii) a flat block is detected, (iii) a transition from complex to flat region is detected, and (iv) a transition from flat to complex region is detected.

### Claim 24 (depends on 18)

The apparatus of claim 18, further comprising:
means for calculating a third RD cost for coding a minimum number (Mmin) of blocks starting from the current block with the LBT mode;
means for calculating a fourth RD cost for coding each of the Mmin blocks with the second coding mode;
means for determining whether the third RD cost is less than a sum of the fourth RD costs for the Mmin blocks; and
means for coding the Mmin blocks with the LBT mode in response to the third RD cost being less than the sum of the fourth RD costs for the Mmin blocks.

### Claim 25 (depends on 24)

The apparatus of claim 24, further comprising:
means for selecting an additional block of the video data in response to the third RD cost being less than the sum of the fourth RD costs;
means for calculating an updated third RD cost for coding the Mmin blocks and the additional block with the LBT mode;
means for calculating a fourth RD cost for coding the additional block with the second coding mode;
means for determining whether the updated third RD cost is less than a sum of the fourth RD costs for the Mmin blocks and the additional block; and
means for coding the Mmin blocks and the additional block with the LBT mode in response to the updated third RD cost being less than the sum of the fourth RD costs for the Mmin blocks and the additional block.

### Claim 26

A non-transitory computer readable storage medium having stored thereon instructions that, when executed, cause a processor of a device to:
select a current block and a next block from video data, wherein the current and next blocks each have a size of P×Q;
determine whether to evaluate larger block size transform (LBT) mode coding performance based on one or more conditions of a plurality of conditions being satisfied for either of the current or next blocks, wherein the plurality of conditions comprises (i) pattern mode is determined to be an optimal coding mode, (ii) a flat block is detected, (iii) a transition from complex to flat region is detected, and (iv) a transition from flat to complex region is detected;
in response to determining to evaluate LBT mode coding performance, calculate a first rate-distortion (RD) cost for coding samples in the current and next blocks together with a LBT mode, wherein the LBT mode operates on a LBT size of P×M, wherein M>Q;
calculate second RD costs for coding each of the current and next blocks individually with a second coding mode different from the LBT mode, wherein the instructions to calculate the second RD costs comprises instructions to calculate, for each of the current and next blocks, a respective second RD cost for coding a respective block individually with the second coding mode;
determine whether the first RD cost is less than a sum of the second RD costs for the current and next blocks; and
code the samples in the current and next blocks with the LBT mode in response to the first RD cost being less than the sum of the second RD costs for the current and next blocks.

### Claim 27 (depends on 26)

The non-transitory computer readable storage medium of claim 26, further having stored thereon instructions that, when executed, cause the processor to:
select an additional block of the video data in response to the first RD cost being less than the sum of the second RD costs;
calculate an updated first RD cost for coding samples in the current, next, and additional blocks together with the LBT mode;
calculate a third RD cost for coding the additional block with the second coding mode;
determine whether the updated first RD cost is less than a sum of the second RD costs for the current and next blocks and the third RD cost for the additional block; and
code the current, next, and additional blocks with the LBT mode in response to the updated first RD cost being less than the sum of the second RD costs for the current and next blocks and the third RD cost for the additional block.

### Claim 28 (depends on 27)

The non-transitory computer readable storage medium of claim 27, further having stored thereon instructions that, when executed, cause the processor to code the current and next blocks with the LBT mode in response to: i) the first RD cost being less than the sum of the second RD costs for the current and next blocks and ii) the updated first RD cost being not less than the sum of the second RD costs for the current, next, and additional blocks.

### Claim 29 (depends on 26)

The non-transitory computer readable storage medium of claim 26, further having stored thereon instructions that, when executed, cause the processor to code the current block with the second coding mode in response to the first RD cost not being less than the sum of the second RD costs for the current and next blocks.

### Claim 30 (depends on 26)

The non-transitory computer readable storage medium of claim 26, further having stored thereon instructions that, when executed, cause the processor to:
calculate a plurality of third RD costs for coding the current block with each of the plurality of coding modes other than the LBT mode;
determine a lowest third RD cost from the calculated third RD costs;
calculate a plurality of fourth RD costs for coding the next block with each of the plurality of coding modes other than the LBT modes; and
determine a lowest fourth RD cost from the calculated fourth RD costs,
wherein the sum of the second RD costs is the sum of the lowest third RD cost and the lowest fourth RD cost.
