[Asterisk-code-review] codecs: Add Codec 2 Mode 2400. (asterisk[master])

Alexander Traud asteriskteam at digium.com
Wed Jul 27 02:42:44 CDT 2016


Alexander Traud has posted comments on this change.

Change subject: codecs: Add Codec 2 Mode 2400.
......................................................................


Patch Set 1:

(3 comments)

https://gerrit.asterisk.org/#/c/3244/1/codecs/codec_codec2.c
File codecs/codec_codec2.c:

Line 26: #define CODEC2_FRAME_LEN  6    /* consider codec2_bits_per_frame(.)    */
> Minor nit: This should be bytes per frame instead of bits per frame.
Mhm, I am not sure, I understand yet. CODEC2_FRAME_LEN is in bytes. codec2_bits_per_frame(.) is the name of a public symbol of that library and returns bits. Shall I re-write the comment to "consider (codec2_bits_per_frame(.) + 7) / 8"?


Line 139: 	.format = "slin8",
> This should just be "slin". In main/codec_builtin.c, the slin8 codec is jus
Done


https://gerrit.asterisk.org/#/c/3244/1/codecs/ex_codec2.h
File codecs/ex_codec2.h:

Line 18: 		.samples = CODEC2_SAMPLES,
> I think I'm missing something here. How is this compiling when CODEC2_SAMPL
That "coding style" is used by several codecs. Within the codec module, the symbol is defined and then this header is included. Therefore, xyz_SAMPLES is defined before this part of the source code is seen. If you want, I use ARRAY_LEN(ex_codec2) instead.


-- 
To view, visit https://gerrit.asterisk.org/3244
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I1e45d8084683fab5f2b272bf35f4a149cea8b8d6
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Alexander Traud <pabstraud at compuserve.com>
Gerrit-Reviewer: Alexander Traud <pabstraud at compuserve.com>
Gerrit-Reviewer: Anonymous Coward #1000019
Gerrit-Reviewer: Mark Michelson <mmichelson at digium.com>
Gerrit-HasComments: Yes



More information about the asterisk-code-review mailing list