mirror of
https://github.com/tuxbox-neutrino/libstb-hal.git
synced 2025-08-26 15:02:58 +02:00
libeplayer: remove inject_raw_pcm (unused)
This commit is contained in:
@@ -386,36 +386,16 @@ static void FFMPEGThread(Context_t * context)
|
||||
currentAudioPts = /* CHECK audioTrack->pts = */pts = calcPts(avContext, audioTrack->stream, packet.pts);
|
||||
|
||||
ffmpeg_printf(200, "AudioTrack index = %d\n", pid);
|
||||
if (audioTrack->inject_raw_pcm == 1) {
|
||||
ffmpeg_printf(200, "write audio raw pcm\n");
|
||||
avOut.data = packet_data;
|
||||
avOut.len = packet_size;
|
||||
avOut.pts = pts;
|
||||
avOut.packet = &packet;
|
||||
avOut.type = "audio";
|
||||
avOut.stream = audioTrack->stream;
|
||||
avOut.avfc = avContext;
|
||||
|
||||
avOut.uNoOfChannels = ((AVStream *) audioTrack->stream)->codec->channels;
|
||||
avOut.uSampleRate = ((AVStream *) audioTrack->stream)->codec->sample_rate;
|
||||
avOut.uBitsPerSample = 16;
|
||||
avOut.bLittleEndian = 1;
|
||||
|
||||
avOut.data = packet_data;
|
||||
avOut.len = packet_size;
|
||||
avOut.pts = pts;
|
||||
avOut.packet = &packet;
|
||||
avOut.type = "audio";
|
||||
avOut.stream = audioTrack->stream;
|
||||
avOut.avfc = avContext;
|
||||
|
||||
if (context->output->audio->Write(context, &avOut) < 0)
|
||||
ffmpeg_err("(raw pcm) writing data to audio device failed\n");
|
||||
} else {
|
||||
avOut.data = packet_data;
|
||||
avOut.len = packet_size;
|
||||
avOut.pts = pts;
|
||||
avOut.packet = &packet;
|
||||
avOut.type = "audio";
|
||||
avOut.stream = audioTrack->stream;
|
||||
avOut.avfc = avContext;
|
||||
|
||||
if (context->output->audio->Write(context, &avOut) < 0)
|
||||
if (context->output->audio->Write(context, &avOut) < 0)
|
||||
ffmpeg_err("writing data to audio device failed\n");
|
||||
}
|
||||
}
|
||||
} else if (subtitleTrack && (subtitleTrack->Id == pid)) {
|
||||
float duration = 3.0;
|
||||
|
@@ -45,15 +45,6 @@ typedef struct Track_s {
|
||||
AVFormatContext *avfc;
|
||||
/* stream from ffmpeg */
|
||||
AVStream *stream;
|
||||
/* codec extra data (header or some other stuff) */
|
||||
// int uNoOfChannels;
|
||||
// int uSampleRate;
|
||||
// int uBitsPerSample;
|
||||
// int bLittleEndian;
|
||||
|
||||
/* If player2 or the elf do not support decoding of audio codec set this.
|
||||
* AVCodec is than used for softdecoding and stream will be injected as PCM */
|
||||
int inject_raw_pcm;
|
||||
|
||||
int pending;
|
||||
int is_static;
|
||||
|
Reference in New Issue
Block a user