Posts Tagged ‘xbox’
Note: Remuxing mkv to avi for the Xbox 360
Thanks to Zeroshade, details here.
Packages Needed:
mkvmerge, mkvextract (package mkvtoolnix), bbe, mplayer, normalize-audio, neroAacEnc, and mp4creator
Install command:
sudo apt-get update && sudo apt-get install mkvtoolnix bbe mplayer normalize-audio mpeg4ip-server
Get neroAacEnc here.
Manual Install:
unzip NeroDigitalAudio.zip cd linux sudo mv neroAacEnc /usr/bin sudo chmod +x /usr/bin/neroAacEnc
vidconv.sh here.
Example Usage:
./vidconv.sh file1.mkv
#!/bin/bash
# zeroshade's script for remuxing mkv to mp4
# http://cantthinkofa.com
VERSION="1.0"
## remuxer to remux AVC mkv videos to mp4's that can be sent to xbox 360.
# requires: mkvmerge, mkvextract (package mkvtoolnix), bbe, mplayer, normalize-audio
# neroAacEnc (http://www.nero.com/eng/downloads-nerodigital-nero-aac-codec.php)
# mp4creator (package mpeg4ip-server)
MKV=$1
if [ -z "$MKV" ]; then
echo "Usage: `basename $0` <MKV>";
exit 5
fi
# using a tmp file allows for extensibility
# if desired, the script can be extended using the audio track
# and codec by uncommenting the lines below
mkvmerge -i "$MKV" > /tmp/info.$$.txt
VID=`grep "Track ID .: video" /tmp/info.$$.txt | awk '{ print sprintf("%d",$3) }'`
#AUDINF=`grep "Track ID .: audio"`/tmp/info.$$.txt`
#AUD=`echo $AUDINF | awk '{ print sprintf("%d",$3) }'`
#AEXT=`echo $AUDINF | awk '{ print $5 }' | sed 's/(A_\|)//g' | awk '{ print tolower($1) }'`
FPS=`mplayer -identify "$MKV" -vc null -ao null -vo null -frames 0 2>/dev/null | grep ^ID_VIDEO_FPS | sed -e 's/^.*=//'`
rm /tmp/info.$$.txt
echo "------Zeroshade's remux script. MKV to mp4 V.$VERSION"
echo
if [ -z "$VID" ]; then
echo "Error getting video track from mkvmerge."
exit 5
fi
if [ -z "$FPS" ]; then
echo "Error getting framerate from mplayer"
exit 5
fi
BASE=`echo $MKV | sed 's/\.mkv//'`
echo "------Extracting video track-----------"
mkvextract tracks "$MKV" "$VID:$BASE.h264"
echo "------Changing Profile-----------------"
bbe -e "r 7 \41" --output="$BASE.tmp.h264" "$BASE.h264"
rm "$BASE.h264"
echo "------Extracting audio track-----------"
mplayer "$MKV" -novideo -vc null -vo null -ao pcm:fast:file="$BASE.wav" -channels 2
echo "------Normalizing audio----------------"
normalize-audio "$BASE.wav"
echo "------Encoding audio to m4a------------"
neroAacEnc -lc -ignorelength -q 0.50 -if "$BASE.wav" -of "$BASE.m4a"
echo "------Removing origingal audio dump----"
rm "$BASE.wav"
echo "------Converting m4a to aac"
mp4creator --extract=1 "$BASE.m4a" "$BASE.aac"
echo "------Cleaning up m4a------------------"
rm "$BASE.m4a"
echo "------Creating mp4 video---------------"
mp4creator --create="$BASE.tmp.h264" -rate=$FPS "$BASE.mp4"
echo "------Adding audio to the video--------"
mp4creator --create="$BASE.aac" -rate=$FPS "$BASE.mp4"
echo "------Removing h264 and aac------------"
rm "$BASE.tmp.h264" "$BASE.aac"
echo "------Done! Enjoy your video! =)-------"
___
*Ignore this* Working example of WordPress sourcecode: [sourcecode light="true"] [sourcecode language="bash" collapse="true"]
Note: ushare -x
ushare -x
Interface eth0 is down. Recheck uShare's configuration and try again ! uShare (version 1.1a), a lightweight UPnP A/V and DLNA Media Server. Benjamin Zores (C) 2005-2007, for GeeXboX Team. See http://ushare.geexbox.org/ for updates. Initializing UPnP subsystem ... Starting in XboX 360 compliant profile ... UPnP MediaServer listening on ***.***.*.***:***** Sending UPnP advertisement for device ... Listening for control point connections ... Building Metadata List ... Looking for files in content directory : /home/sab Found files and subdirectories.
Note: nmap (find xbox or laptop ip)
sudo nmap -sP ***.***.1.0/24
Starting Nmap 5.00 ( http://nmap.org ) at 2010-04-18 12:53 BST Host ***.***.*.* is up (0.014s latency). MAC Address: **:**:**:**:**:** (Router) Host ***.***.*.*** is up. Host ***.***.*.*** is up (0.017s latency). MAC Address: **:**:**:**:**:** (Microsoft) Nmap done: 256 IP addresses (3 hosts up) scanned in 4.68 seconds
Audit your network.
-sP: Ping Scan – go no further than determining if host is online.