From 498b6460a1ed6b0cc0b96e507b90f07c625cc9f2 Mon Sep 17 00:00:00 2001
From: Dmitry Kovalev <dkovalev@google.com>
Date: Fri, 17 May 2013 15:50:26 -0700
Subject: [PATCH] Removing clamp_type from the bitstream.

Change-Id: Ica75bdd4905c4a04b7f92795d0b8ce6836a99ef4
---
 vp9/common/vp9_alloccommon.c | 1 -
 vp9/common/vp9_onyxc_int.h   | 6 ------
 vp9/decoder/vp9_decodframe.c | 1 -
 vp9/encoder/vp9_bitstream.c  | 1 -
 4 files changed, 9 deletions(-)

diff --git a/vp9/common/vp9_alloccommon.c b/vp9/common/vp9_alloccommon.c
index ec81fbd7ae..d149f31b42 100644
--- a/vp9/common/vp9_alloccommon.c
+++ b/vp9/common/vp9_alloccommon.c
@@ -205,7 +205,6 @@ void vp9_create_common(VP9_COMMON *oci) {
   oci->no_lpf = 0;
   oci->use_bilinear_mc_filter = 0;
   oci->clr_type = REG_YUV;
-  oci->clamp_type = RECON_CLAMP_REQUIRED;
 
   // Initialize reference frame sign bias structure to defaults
   vpx_memset(oci->ref_frame_sign_bias, 0, sizeof(oci->ref_frame_sign_bias));
diff --git a/vp9/common/vp9_onyxc_int.h b/vp9/common/vp9_onyxc_int.h
index 2d4cd30ccd..b6a0e6be92 100644
--- a/vp9/common/vp9_onyxc_int.h
+++ b/vp9/common/vp9_onyxc_int.h
@@ -98,11 +98,6 @@ typedef struct frame_contexts {
   unsigned int mv_ref_ct[INTER_MODE_CONTEXTS][4][2];
 } FRAME_CONTEXT;
 
-typedef enum {
-  RECON_CLAMP_REQUIRED        = 0,
-  RECON_CLAMP_NOTREQUIRED     = 1
-} CLAMP_TYPE;
-
 typedef enum {
   SINGLE_PREDICTION_ONLY = 0,
   COMP_PREDICTION_ONLY   = 1,
@@ -139,7 +134,6 @@ typedef struct VP9Common {
   int subsampling_y;
 
   YUV_TYPE clr_type;
-  CLAMP_TYPE  clamp_type;
 
   YV12_BUFFER_CONFIG *frame_to_show;
 
diff --git a/vp9/decoder/vp9_decodframe.c b/vp9/decoder/vp9_decodframe.c
index b200e6ccce..732bf02d41 100644
--- a/vp9/decoder/vp9_decodframe.c
+++ b/vp9/decoder/vp9_decodframe.c
@@ -986,7 +986,6 @@ int vp9_decode_frame(VP9D_COMP *pbi, const uint8_t **p_data_end) {
                        "Failed to allocate bool decoder 0");
 
   pc->clr_type = (YUV_TYPE)vp9_read_bit(&header_bc);
-  pc->clamp_type = (CLAMP_TYPE)vp9_read_bit(&header_bc);
   pc->error_resilient_mode = vp9_read_bit(&header_bc);
 
   setup_loopfilter(pc, xd, &header_bc);
diff --git a/vp9/encoder/vp9_bitstream.c b/vp9/encoder/vp9_bitstream.c
index bcec13c4be..168c2a3efc 100644
--- a/vp9/encoder/vp9_bitstream.c
+++ b/vp9/encoder/vp9_bitstream.c
@@ -1529,7 +1529,6 @@ void vp9_pack_bitstream(VP9_COMP *cpi, uint8_t *dest, unsigned long *size) {
 
   // TODO(jkoleszar): remove these two unused bits?
   vp9_write_bit(&header_bc, pc->clr_type);
-  vp9_write_bit(&header_bc, pc->clamp_type);
 
   // error resilient mode
   vp9_write_bit(&header_bc, pc->error_resilient_mode);
-- 
GitLab