Video Encoding Mode Selection Using Bidirectional Prediction Costs

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

The high computation complexity and efficiency issues in real-time video encoding on mobile platforms due to the complexity of the H.264/AVC standard, particularly in selecting optimal prediction modes for B frames, hinder effective video transmission and compression.

Innovation Solution

A video encoding method that simplifies the mode selection process by computing and comparing mode costs after motion compensation using bidirectional, forward, and backward prediction motion vectors, selecting the mode with the smallest cost as the optimal prediction direction, and limiting the process to only the Skip and Direct prediction modes, reducing unnecessary computations.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Manufacturing precision

If H.264/AVC standard is used for video encoding, then encoding efficiency and image quality are improved, but computation complexity increases

Engineering Contradiction:
Improveencoding efficiencyVSAvoidcomputation complexity
Core Design Contradiction:
Manufacturing precisionVSDevice complexity

Solution Approach 1:

The macroblock is divided into four 8x8 luma blocks and two 8x4 or 4x8 chroma blocks. Each block can be independently processed with its own prediction mode selection, allowing the complex encoding process to be broken down into manageable segments that can be processed in parallel

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent performs mode cost computation for all nine prediction modes (three intra-mode and six inter-mode) for each block, even though in practice not all modes will be selected. This exhaustive approach ensures optimal quality but increases computation, which is then managed through the segmentation principle

Inventive Principle:
Principle #16Partial or excessive action

2Manufacturing precision

If multiple prediction modes are computed and compared for B frame encoding, then encoding quality is improved, but computation complexity and time increase

Engineering Contradiction:
Improveencoding qualityVSAvoidencoding time
Core Design Contradiction:
Manufacturing precisionVSLoss of time

Solution Approach 1:

The prediction mode selection is segmented into independent evaluations for each block type (luma and chroma) and each prediction direction (intra and inter). This allows the system to compute costs for multiple modes in parallel across different blocks rather than sequentially evaluating all modes for one block before moving to the next

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent pre-computes motion compensation results and mode costs for all candidate prediction modes before final mode selection. By preparing these calculations in advance, the system avoids repeated computations during the mode decision phase, reducing overall encoding time

Inventive Principle:
Principle #10Preliminary action

3Measurement precision

If motion estimation and mode selection are performed for each macroblock, then prediction accuracy is improved, but computation complexity increases

Engineering Contradiction:
Improveprediction accuracyVSAvoidcomputation complexity
Core Design Contradiction:
Measurement precisionVSDevice complexity

Solution Approach 1:

The macroblock prediction process is segmented into separate intra-mode prediction and inter-mode prediction pathways. Each pathway handles specific prediction types with dedicated motion compensation logic, allowing the system to optimize each segment independently rather than processing all prediction types uniformly across all blocks

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

Different prediction modes and computation strategies are applied to different blocks based on local characteristics. Luma blocks use 8x8 processing while chroma blocks use 8x4 or 4x8 processing. Motion compensation parameters are optimized locally for each block based on its specific content and motion characteristics

Inventive Principle:
Principle #3Local quality

Data Source

PatentUS9307241B2Video encoding method and a video encoding apparatus using the same
Publication Date: 2016.04.05 TENCENT TECHNOLOGY (SHENZHEN) CO LTD
  • US9307241B2 patent drawing
  • US9307241B2 patent drawing
  • US9307241B2 patent drawing

AI summary

The present application provides a video encoding method that includes setting frame types for a video sequence; obtaining a B frame; determining whether a current macroblock of the B frame satisfies a Direct prediction mode, and if yes determining whether the current macroblock satisfies a Skip prediction mode; if the current macroblock does not meet either mode, computing at least one of a mode cost after performing motion compensation on the current macroblock using two bidirectional prediction motion vectors obtained in the Direct prediction mode; a mode cost after performing motion compensation on the current macroblock using a forward prediction motion vector obtained in the Direct prediction mode; and a mode cost after performing motion compensation on the current macroblock using a backward prediction motion vector obtained in the Direct prediction mode; and selecting a mode with a smallest cost as an optimal prediction direction to encode the current macroblock.