vp9_decodframe.c 33.1 KB
Newer Older
  cm->last_height = cm->height;
  new_fb->corrupted |= xd->corrupted;
John Koleszar's avatar
John Koleszar committed

  if (!pbi->decoded_key_frame) {
    if (keyframe && !new_fb->corrupted)
John Koleszar's avatar
John Koleszar committed
      pbi->decoded_key_frame = 1;
    else
      vpx_internal_error(&cm->error, VPX_CODEC_CORRUPT_FRAME,
John Koleszar's avatar
John Koleszar committed
                         "A stream must start with a complete key frame");
  }
  if (!cm->error_resilient_mode && !cm->frame_parallel_decoding_mode) {
    vp9_adapt_coef_probs(cm);
    if (!keyframe && !cm->intra_only) {
      vp9_adapt_mode_probs(cm);
      vp9_adapt_mv_probs(cm, xd->allow_high_precision_mv);
John Koleszar's avatar
John Koleszar committed
  }
  if (cm->refresh_frame_context)
    cm->frame_contexts[cm->frame_context_idx] = cm->fc;
  update_segmentation_map(cm);

John Koleszar's avatar
John Koleszar committed
  return 0;
John Koleszar's avatar
John Koleszar committed
}