-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Cleaned up code * Cleaned up more code * Moved media folder config to seperate file
- Loading branch information
Showing
8 changed files
with
88 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
cache/ | ||
.idea/ | ||
private/ | ||
__pycache__ | ||
*.pyc | ||
|
||
|
||
mediaconf.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
export LANG='en_US.UTF-8' | ||
export LC_ALL='en_US.UTF-8' | ||
export PATH=~/bin:$PATH | ||
/usr/local/opt/python-3.4/bin/python3 library/server.py | ||
|
||
|
||
/usr/bin/python3 library/server.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,30 @@ | ||
port= 8124 | ||
|
||
# library config | ||
|
||
media_folder= "/mnt/stuff/Public/" | ||
root_items= [ { "name": "Eltern", "target": "Shared Videos/Videos/Eltern" }, { "name": "Kinder", "target": "Shared Videos/Videos/Kinder" }, { "name": "Music", "target": "Shared Music" }, {"name": "Test Music", "target": "/home/daniel/Music"}, {"name": "Test Video", "target": "/home/daniel/TEST"} ] | ||
|
||
media_folder= "/mnt/Public/" | ||
root_items= [ { "name": "Eltern", "target": "Shared Videos/Videos/Eltern" }, { "name": "Aufnahmen", "target": "Shared Videos/Aufnahmen2" }, { "name": "Kinder", "target": "Shared Videos/Videos/Kinder" }, { "name": "Music", "target": "Shared Music" }, { "name": "Fotos", "target": "Shared Pictures" } ] | ||
"""Config file.""" | ||
|
||
port = 8124 | ||
|
||
# transcoder config | ||
|
||
ffmpeg= "ffmpeg" | ||
ffmpeg = "ffmpeg" | ||
|
||
types = { | ||
"mp3": "audio", | ||
"jpg": "image", | ||
"mp4": "video"} | ||
|
||
|
||
transcode_mime = { | ||
"*" : "video/mp4", | ||
transcode_mime = { | ||
"*": "video/mp4", | ||
"mp3": "audio/mp3", | ||
"jpg": "image/jpg"} | ||
|
||
|
||
ffmpeg_transcode_args_2 = { | ||
"*": ["-f", "mp4", "-strict", "experimental", "-preset", "ultrafast", "-movflags", "frag_keyframe+empty_moov+faststart", "pipe:1"], | ||
"mp3": ["-f", "mp3", "-codec", "copy", "pipe:1"]} | ||
|
||
ffmpeg_transcode_args = { | ||
"*" : [ "-f", "mp4", "-strict", "experimental", "-preset", "ultrafast", "-movflags", "frag_keyframe+empty_moov+faststart", "pipe:1" ], | ||
"mp3": [ "-f", "mp3", "-codec", "copy", "pipe:1" ] } | ||
"*": " -ss {} -i {} -f {} -vcodec {} -acodec {} -strict experimental -preset ultrafast -movflags frag_keyframe+empty_moov+faststart pipe:1", | ||
"mp3": ["-f", "mp3", "-codec", "copy", "pipe:1"]} | ||
|
||
ffmpeg_poster_args = [ "-f", "mjpeg", "-vf", "scale=512x512", "pipe:1" ] | ||
ffmpeg_poster_args = ["-f", "mjpeg", "-vf", "scale=512x512", "pipe:1"] | ||
# "-noaccurate_seek" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
"""Config file for media folder.""" | ||
|
||
"""for usage rename to mediaconf.py""" | ||
|
||
media_folder = "/media/hdd1/TV" | ||
root_items = [{"name": "The-Flash", "target": "/media/hdd1/TV/The-Flash"}, | ||
{"name": "Test", "target": "/home/alexander/tmp/test-media"}, | ||
{"name": "TBBT", "target": "/media/hdd1/TV/The-Big-Bang-Theory"}] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.