diff options
author | TheTroll <trolldev@gmail.com> | 2010-03-29 21:41:02 +0200 |
---|---|---|
committer | TheTroll <trolldev@gmail.com> | 2010-03-29 21:41:02 +0200 |
commit | 4366ae3eef7e78ea2a1f68d281cff6b5bb62dc13 (patch) | |
tree | f71b7b9dd87966b959e243b0fe9a0bc17296499e | |
parent | 757a348d254dc4dffe2042b0690942208222f106 (diff) | |
parent | 975b28552b104962598ea484d0bf6b11fdd1f6aa (diff) | |
download | istreamdev-4366ae3eef7e78ea2a1f68d281cff6b5bb62dc13.tar.gz istreamdev-4366ae3eef7e78ea2a1f68d281cff6b5bb62dc13.tar.bz2 |
Merge branch 'master' of projects.vdr-developer.org:istreamdev
* 'master' of projects.vdr-developer.org:istreamdev:
fixed version in history
typo README
ramdir still missing in git
readme
-rwxr-xr-x | HISTORY | 2 | ||||
-rw-r--r-- | README | 163 | ||||
-rw-r--r-- | index.php | 2 | ||||
-rw-r--r-- | js/functions.js | 20 | ||||
-rw-r--r-- | playlist/MP3STREAMDIR | 0 |
5 files changed, 185 insertions, 2 deletions
@@ -1,7 +1,7 @@ iStreamdev History ------------------ -03.29.2010 - 0.1.0 +03.29.2010 - 1.0.0 - Massive rework from scratch - Now based on JQuery/JQTouch @@ -0,0 +1,163 @@ + ________________________________________________________ +| | +| [ iStreamdev ] | +|________________________________________________________| + + Written by: + Alib <aliboba@free.fr> + TheTroll <trolldev@gmail.com> + + Website: + http://www.istreamdev.com + + Project's homepage: + http://projects.vdr-developer.org/projects/show/istreamdev + + + Latest version available at: + http://projects.vdr-developer.org/projects/list_files/istreamdev + + git repository: + git://projects.vdr-developer.org/istreamdev.git + + See the file COPYING for license information. + + About: + ----- + + iStreamdev lets you live stream your TV channels & recordings from VDR and all your Video & Music files to your iPhone. +Your Iphone don't needs to be jailbroken, it uses native iphone Quicktime player. +Your iPhone needs at least firmware 3.0 to support HTTP Live Streaming protocol. + +TV, recordings & video files are rencoded in mpeg2 TS stream with H264 video and mp3 audio. +Audio files are streamed to their native formats. So only mp3, aac & wave are supported. + + Features: + -------- + + * 100% webapp compatible user interface using jQtouch framework ( http://www.jqtouch.com/ ) + * Full Ajax/Json client/server communication using JQuery ( jquery.com ) + * Channel selection throught categories + * Channels listed with logo and current epg. + * Streaming format selection: Edge, 3g, Wifi + * Recording streaming: Access your vdr recordings with epg. + * Timers support: Add/Edit/Delete/Activate/Deactivate timers. + * Video files support: Stream to all your video files ( avi, mkv, mov, etc ) to your Iphone. If you have a movie.tbn poster.jpg or folder.jpg file in the same folder as the video file, it will display it as thumbnail. If there's no picture, it will generate a thumbnail from the video. + * Music files support: Stream all your mp3/aac/wav files with dynamic playlist support. + * Electronic Program Guide. + + Webapp: + ------ +First time you use istreamdev, add it to your iPhone using Favorites menu & launch it in fullscreen mode as a normal Appstore app. + + Usage: + ----- + +Select a channels category, then a channel. +Select your stream mode: Edge , 3g or Wifi. The Play icon +will appear automatically after few seconds when the feed is +ready. +This is the same for recordings and videos files. +To Stop the stream server, hit Stop stream button. + +Video thumbnails: +iStreamdev takes videoname.tbn , poster.jpg or folder.jpg file ( from xbmc export library ) as thumbnail source, or grab a picture in the video stream if there's not. + +Channel logos: +Put your 80x80 png logos in logos/ folder. They needs to have the same name/caps as your channels.conf If a channel have a / character in the name, replace it by _ ( cf RTL/TELEVISION > RTL_TELEVISION.png ) + +Music: +iStreamdev generate a playlist from the requested file to the last file of the folder. Then you can listen next track easily. To play an entire album, just launch the first track. + + What you need: + ------------- + +- an http server with PHP5 enabled like apache or lighthttpd + +- having "at" package. + +- www-data user should allowed to use "at". + + Check on your /etc/at/deny if www-data is there, and remove it if so. + +- ffmpeg compiled with libx264 and libmp3lame support + +- segmenter: use modded version included with istreamdev. + +_________________________________________________________ + INSTALL +_________________________________________________________ + + +Download a stable release from Files or development revision from Git repository: + + git clone git://projects.vdr-developer.org/istreamdev.git + +Copy the file in your webfolder. /istreamdev for example. +Copy the config_default.php to config.php and edit it. + +Compiles segmenter provided by typing make in segmenter folder and install it: +"make & cp segmenter /usr/bin/" + +At each update, don't forget to remove your old config file and replace it by the new default one to prevent not updated config files. + +$httpath needs to point to your istreamdev http path ( /istreamdev/ if your site is http://mydomain/istreamdev/ ). Caution: don't use the full url path like http://. + +The ram folder and playlist one shoulds be writable. +To prevent hard disk usage, you can mount it in /dev/shm to use ram instead of disk. +If you don't have /dev/shm , you need to mount it on boot: +On your /etc/mtab, add this line: + + tmpfs /dev/shm tmpfs rw,nosuid,nodev 0 0 + +From your istreamdev folder: + + rm -Rf ram + mkdir /dev/shm/ram + ln -s /dev/shm/ram ram + +Check your files permissions. All php script and istream.sh should be executable by www-data user. +www-data needs rights to launch ffmpeg, segmenter, and some shell commands. + +From your istreamdev directory: +# set owner and group + + sudo chown -R root.www-data ./* + +# strict default permissions for files and directories + + sudo find ./ -type f | xargs sudo chmod 644 + sudo find ./ -type d | xargs sudo chmod 755 + +# ram and playlist directories need to be group-writable + + sudo chmod 775 ram playlist + +# istream.sh shoudl be executable + + sudo chmod 755 bin//istream.sh + +# if you moved the ram directory to a ramdisk as suggested: + + sudo chown root.www-data /dev/shm/ram + sudo chmod 775 /dev/shm/ram + +Check everything is ok with ffmpeg by launching the above command logued as your http server user ( www-data ) : + + ./bin/istream.sh http://localhost:3000/TS/1 512k 128k 480x320 /istreamdev/ 3 /usr/bin/ffmpeg /usr/bin/segmenter session0 + +You should see ffmpeg access streamdev http://localhost:3000/TS/1 and encode the stream. + +You can add your logos channels pictures ( 80x80 png ) in logos/ folder. +If some channels have a / in the name, replace it by a space. Ex: "RTL\RTL Television" > "RTL RTL Television.png" + +Now everything is ok you can login from your iphone: http://yourip/istreamdev +Add it to your Iphone home menu as shortcut ( IMPORTANT if you want to have it in fullscreen mode ). + +ACTIVATE DEBUG: +-------------- +You can active debug logs in your config file: + +$debug=1; logs all events in a file. +$ffmpegdebug=1; logs all ffmpeg output in a file. + @@ -15,7 +15,7 @@ if (substr_count($_SERVER['HTTP_ACCEPT_ENCODING'], 'gzip')) ob_start("ob_gzhandl <link rel="stylesheet" href="min/?b=css&f=jqtouch.css,theme.css,istreamdev.css,spinningwheel.css" type="text/css" media="screen" /> <script src="min/?b=js&f=jquery-1.4.2.min.js,jqtouch.js,jqtouch.transitions.js,functions.js,spinningwheel.js,jquery.scrollTo-1.4.2.js,istreamdev.js" type="text/javascript" charset="utf-8"></script> </head> - <body> + <body onorientationchange=\"updateOrientation();\"> <div id="loader"></div> <div id="status_box"></div> <div id="jqt"> diff --git a/js/functions.js b/js/functions.js index f628142..2ea12d6 100644 --- a/js/functions.js +++ b/js/functions.js @@ -120,3 +120,23 @@ function str_pad (input, pad_length, pad_string, pad_type) { return input;
}
+
+function updateOrientation() {
+ switch(window.orientation) {
+ case 0:
+ orient = "portrait";
+ break;
+ case -90:
+ orient = "landscape";
+ break;
+ case 90:
+ orient = "landscape";
+ break;
+ case 180:
+ orient = "portrait";
+ break;
+ }
+ document.body.setAttribute("orient", orient);
+ window.scrollTo(0, 1);
+
+}
\ No newline at end of file diff --git a/playlist/MP3STREAMDIR b/playlist/MP3STREAMDIR deleted file mode 100644 index e69de29..0000000 --- a/playlist/MP3STREAMDIR +++ /dev/null |