fix a bug of deriving scan_idx, now the first CTU is fully parsed.