Using pjsua to create a mp3 stream

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Regarding MP3 recording ... what I do, is to re-add the code to pjsua-lib,
which was there until mp3 writer was moved to the third-party folder. 
Just find


    if (file_format == FMT_WAV) {
	status = pjmedia_wav_writer_port_create(pool, path,
						pjsua_var.media_cfg.clock_rate,
						pjsua_var.mconf_cfg.channel_count,
						pjsua_var.mconf_cfg.samples_per_frame,
						pjsua_var.mconf_cfg.bits_per_sample,
						options, 0, &port);

in pjsua_media.c and add the following lines right after

    } else if (file_format == FMT_MP3) {
	status = pjmedia_mp3_writer_port_create(pjsua_var.pool, path,
						pjsua_var.media_cfg.clock_rate,
						pjsua_var.mconf_cfg.channel_count,
						pjsua_var.mconf_cfg.samples_per_frame,
						pjsua_var.mconf_cfg.bits_per_sample,
						enc_param, &port);

... and include mp3_writer.c and mp3_port.h to pjsua-lib project. This works
for any pjsua-lib based applications.


Greets, Toni

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.





[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux