Posts by Bromor

    Hello!

    I am facing playback issues of videos (recorded by VDR) when seeking the video by BigStepForward (and sometimes also when using StepForward). After doing some consecutive BigStepForward steps video is broken into single frames showing up after some seconds or black screens. Audio plays for some seconds after a new frame/image is provided to TV but stops after some seconds. In between the loading cycle (100%) of kodi is showing during black screens like during buffering of streaming content. This failure symptom is repeating, playback does not recover to normal playback.

    The same video file plays fine when starting from beginning or seeking the file by absolute position (giving the position with the number block during playback).

    The file is stored on local disk, no network streaming.

    Debug log: pastebin

    Line 1445: Playback started

    Line 2334: Start of pressing BigStepForward sequence

    Additional information: screenshots

    Hello!

    Background of my issue: I have a somewhat old TV which only supports 16 Bit and 20 Bit PCM audi input.

    ELD of TV

    Unfortunately something is going wrong somewhere and I do not get any audio from my TV in stock configuration. I assume there is a problem with the 20 Bit PCM format for my TV. By default, audio is passed to ALSA in 32 Bit format.

    default hw_params
    Code
    LibreELEC:~ # cat /proc/asound/card0/pcm3p/sub0/hw_params
    access: RW_INTERLEAVED
    format: S32_LE
    subformat: STD
    channels: 2
    rate: 48000 (48000/1)
    period_size: 2400
    buffer_size: 9600

    After some tries, i figured out that audio is playing fine from TV if passed as 16 Bit PCM format.

    audio working hw_params
    Code
    LibreELEC:~ # cat /proc/asound/card0/pcm3p/sub0/hw_params
    access: RW_INTERLEAVED
    format: S16_LE
    subformat: STD
    channels: 2
    rate: 48000 (48000/1)
    period_size: 6000
    buffer_size: 24000

    Now I am searching for any solution to convert the audi coming from Kodi to 16 Bit PCM format before passed to TV over HDMI. (Any solution welcome)

    My approach was to convert die audio stream in the ALSA layer by a plug, so i configured ~/.config/asound.conf as follows (based on the description from alsa-project.org)

    This works as expected at the ALSA layer and now a can play e.g. 24 Bit audio passed to ALSA default device by aplay and hear the sound from my TV.

    aplay 24 Bit audio

    But in Kodi, the default ALSA device is not updated (still shows analog output and no audio on TV) and the HDMI selection as audio output still uses the 32 Bit format for ALSA. Also, my complex_convert alias (from asound.conf) is not showing as ALSA sink in the Kodi audi selection list.

    Is it possible to use the complex_convert ALSA alias as audio sink for Kodi?


    Other approach: Kodi selects audio sample format as AE_FMT_S32NE, is there a way to force it to AE_FMT_S16LE?

    Kodi debug log

    Any ideas how I can solve my issue?