[REQUEST] External Audio [.ac3] [.dts]
#1
Hello,
Im Sure, in many countries, people do not watch movies in English.
Unfortunately, in many cases, other audio is included in separate files: .ac3 or .dts.

I'm not a programmer, but i build a little bash script.
First, I search the files ac3 and dts
find \ media \ sdb1 \ Films-name \ *. ac3
find \ media \ sdb1 \ Films-name \ *. dts
Then use the script:
Code:
#!/bin/bash

DTS="$1.dts"
AC3="$1.ac3"
SRT="$1.srt"
MKV="$1.mkv"
OUT="$1.pl.mkv"

LANG="pol"
CHARSET="CP1250"

echo "--------------------------"
echo "    MKVTOOLNIX SCRIPT"
echo "--------------------------"
echo ""
echo "--------"
echo "  MENU "
echo "--------"
echo "1. AC3"
echo "2. AC3 + subtitles"
echo "3. DTS"
echo "4. DTS + subtitles"
echo "5. subtitles"
echo ""
echo "Working on "$1
echo ""
echo "Available files:"
ls "$PWD" -1 | grep $1
echo ""
echo -n "Select option : "
read opcja

case "$opcja" in
    1)
        mkvmerge -o "$OUT" "$MKV" --language 0:$LANG "$AC3"
        if [ "$?" != "0" ]
        then
        echo "error"; exit 4        
        else
        rm "$AC3" "$MKV"
        mv "$OUT" "$MKV"
        fi
        ;;
    2)
        mkvmerge -o "$OUT" "$MKV" --language 0:$LANG "$AC3" --sub-charset 0:$CHARSET --language 0:$LANG "$SRT"
        if [ "$?" != "0" ]
        then
        echo "error"; exit 4    
        else
        rm "$AC3" "$SRT" "$MKV"
        mv "$OUT" "$MKV"
        fi
        ;;
    3)
        mkvmerge -o "$OUT" "$MKV" --language 0:$LANG "$DTS"
        if [ "$?" != "0" ]
        then
        echo "error"; exit 4    
        else
        rm "$DTS" "$MKV"
        mv "$OUT" "$MKV"
        fi
        ;;
    4)
        mkvmerge -o "$OUT" "$MKV" --language 0:$LANG "$DTS"  --sub-charset 0:$CHARSET --language 0:$LANG "$SRT"
        if [ "$?" != "0" ]
        then
        echo "error"; exit 4    
        else
        rm "$DTS" "$SRT" "$MKV"
        mv "$OUT" "$MKV"
        fi
        ;;
    5)
        mkvmerge -o "$OUT" "$MKV" --sub-charset 0:$CHARSET --language 0:$LANG "$SRT"
        if [ "$?" != "0" ]
        then
        echo "error"; exit 4    
        else
        rm "$SRT" "$MKV"
        mv "$OUT" "$MKV"
        fi
        ;;
    *)
        echo "You select wrong option"
        ;;
esac

Unfortunately, on ION platform takes a long time (and you need keyboard or telnet).

Q1.
Is it possible to write a script that would "see" external files AC3/DTS
and told them to play without muxing?...

Q2.
...Alternatively, the script for XBMC, which displays a list of all directories (films), which contains the files *. ac3 and *. dts, and ask which of them to muxing. Something like that:
Image

Im waiting for responseSmile
Regards,
Pawel

ps. sorry for my ugly english
Reply
#2
Ok, perhaps I wrote too much.
Please answer me for one question:
Is it possible to write simple a plugin/script for playing external files AC3/DTS with MKV videos in the same time?

Regards,
Pawel
Reply
#3
No, xbmc doesn't support external audio streams at all. You'd have to remux them into the container externally.
Reply
#4
Thanks for your reply. So... the script to help muxing, makes sense.
I will try to learn python and write it! Maybe half a year will be enough for me. Wink

Pawel

ps. I understand that the restriction is the internal xbmc player? plug-ins not help?
Reply
#5
pablolite Wrote:I will try to learn python and write it! Maybe half a year will be enough for me. Wink

ps. I understand that the restriction is the internal xbmc player? plug-ins not help?

The multi-language python remuxing plugin seems pretty complicated compared to the ability to select an external file, but the ability to select an external file would have to be patched into the internal xbmc player, as you say. You'd have to learn C++ to add this functionality to the internal player, not python. I appreciate your enthusiasm and share your interest in such a feature!

=darwin
Reply
#6
try using mkvtoolnix to mux it together, if the files are already present then it should take 60sec. tops
Image
Reply

Logout Mark Read Team Forum Stats Members Help
[REQUEST] External Audio [.ac3] [.dts]0