aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-evs.c
diff options
context:
space:
mode:
authorNan Xiao <nan@chinadtrace.org>2021-10-21 10:43:42 +0800
committerWireshark GitLab Utility <gerald+gitlab-utility@wireshark.org>2021-10-21 07:31:12 +0000
commit63b602973d8012f3dc8deedda77e014a0f5f1ed5 (patch)
treef69b97dfa4159c2a770f03e37e7d7097b17bce66 /epan/dissectors/packet-evs.c
parentf58ccfc068d8a8e96571f44546ee13fe6b85d18b (diff)
EVS: Support decoding Primary 7.2/8.0 kbps packets
Diffstat (limited to 'epan/dissectors/packet-evs.c')
-rw-r--r--epan/dissectors/packet-evs.c33
1 files changed, 33 insertions, 0 deletions
diff --git a/epan/dissectors/packet-evs.c b/epan/dissectors/packet-evs.c
index 1b22537655..210fee6127 100644
--- a/epan/dissectors/packet-evs.c
+++ b/epan/dissectors/packet-evs.c
@@ -55,6 +55,7 @@ static int hf_evs_core_sample_rate = -1;
static int hf_evs_132_bwctrf_idx = -1;
static int hf_evs_28_frame_type = -1;
static int hf_evs_28_bw_ppp_nelp = -1;
+static int hf_evs_72_80_bwct_idx = -1;
static int ett_evs = -1;
static int ett_evs_header = -1;
@@ -401,6 +402,24 @@ static const value_string evs_28_bw_ppp_nelp_vals[] = {
{ 0, NULL }
};
+static const value_string evs_72_80_bwct_idx_vals[] = {
+ { 0x0, "NB generic" },
+ { 0x1, "NB unvoiced" },
+ { 0x2, "NB voiced" },
+ { 0x3, "NB transition" },
+ { 0x4, "NB audio" },
+ { 0x5, "NB inactive" },
+ { 0x6, "WB generic" },
+ { 0x7, "WB unvoiced" },
+ { 0x8, "WB voiced" },
+ { 0x9, "WB transition" },
+ { 0xa, "WB audio" },
+ { 0xb, "WB inactive" },
+ { 0xc, "NB generic" },
+ { 0xd, "WB generic" },
+ { 0xe, "NB lrMDCT" },
+ { 0, NULL }
+};
static void
dissect_evs_cmr(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *evs_tree, int offset, guint8 cmr_oct)
@@ -667,6 +686,15 @@ dissect_evs(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
proto_tree_add_bits_item(vd_tree, hf_evs_28_bw_ppp_nelp, tvb, bit_offset, 2, ENC_BIG_ENDIAN);
}
break;
+ case 18: /* 144 EVS Primary 7.2 */
+ case 20: /* 160 EVS Primary 8.0 */
+ /* 7.1.1 Bit allocation at VBR 5.9, 7.2 – 9.6 kbps
+ * Note that the BW and CT parameters are combined together to form a single index at 7.2 and 8.0 kbps. This index
+ * conveys the information whether CELP core or HQ-MDCT core is used.
+ */
+ /* BW, CT, 4*/
+ proto_tree_add_bits_item(vd_tree, hf_evs_72_80_bwct_idx, tvb, bit_offset, 4, ENC_BIG_ENDIAN);
+ break;
case 61: /* 488 EVS Primary 24.4 */
/* 7.1.3 Bit allocation at 16.4 and 24.4 kbps */
/* BW 2 bits*/
@@ -915,6 +943,11 @@ proto_register_evs(void)
FT_UINT8, BASE_DEC, VALS(evs_28_bw_ppp_nelp_vals), 0x0,
NULL, HFILL }
},
+ { &hf_evs_72_80_bwct_idx,
+ { "BW CT Index", "evs.72.80.bwct_idx",
+ FT_UINT8, BASE_DEC, VALS(evs_72_80_bwct_idx_vals), 0x0,
+ NULL, HFILL }
+ },
};