mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
update demo, support acodec
This commit is contained in:
parent
acdd5a827e
commit
15f651bccd
11 changed files with 97 additions and 20 deletions
|
@ -189,7 +189,7 @@ int SrsCodec::audio_aac_demux(int8_t* data, int size, SrsCodecSample* sample)
|
|||
// only support aac
|
||||
if (audio_codec_id != SrsCodecAudioAAC) {
|
||||
ret = ERROR_HLS_DECODE_ERROR;
|
||||
srs_error("hls only support audio aac codec. ret=%d", ret);
|
||||
srs_error("hls only support audio aac codec. actual=%d, ret=%d", audio_codec_id, ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -299,7 +299,7 @@ int SrsCodec::video_avc_demux(int8_t* data, int size, SrsCodecSample* sample)
|
|||
// only support h.264/avc
|
||||
if (codec_id != SrsCodecVideoAVC) {
|
||||
ret = ERROR_HLS_DECODE_ERROR;
|
||||
srs_error("hls only support video h.264/avc codec. ret=%d", ret);
|
||||
srs_error("hls only support video h.264/avc codec. actual=%d, ret=%d", codec_id, ret);
|
||||
return ret;
|
||||
}
|
||||
video_codec_id = codec_id;
|
||||
|
|
|
@ -289,7 +289,7 @@ int SrsRtmpConn::stream_service_cycle()
|
|||
}
|
||||
|
||||
bool enabled_cache = _srs_config->get_gop_cache(req->vhost);
|
||||
srs_info("source found, url=%s, enabled_cache=%d", req->get_stream_url().c_str(), enabled_cache);
|
||||
srs_trace("source found, url=%s, enabled_cache=%d", req->get_stream_url().c_str(), enabled_cache);
|
||||
source->set_cache(enabled_cache);
|
||||
|
||||
switch (type) {
|
||||
|
|
|
@ -418,7 +418,7 @@ SrsSource* SrsSource::find(SrsRequest* req)
|
|||
|
||||
if (pool.find(stream_url) == pool.end()) {
|
||||
pool[stream_url] = new SrsSource(req);
|
||||
srs_verbose("create new source for url=%s, vhost=%s", stream_url.c_str(), vhost.c_str());
|
||||
srs_info("create new source for url=%s, vhost=%s", stream_url.c_str(), vhost.c_str());
|
||||
}
|
||||
|
||||
return pool[stream_url];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue