SageTV Community  

Go Back   SageTV Community > SageTV Development and Customizations > SageTV Customizations
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

SageTV Customizations This forums is for discussing and sharing user-created modifications for the SageTV application created by using the SageTV Studio or through the use of external plugins. Use this forum to discuss customizations for SageTV version 6 and earlier, or for the SageTV3 UI.

Reply
 
Thread Tools Search this Thread Display Modes
  #1481  
Old 03-27-2007, 12:53 PM
jamart3d's Avatar
jamart3d jamart3d is offline
Sage User
 
Join Date: Jun 2006
Location: earth
Posts: 24
How different is vlc started from the webserver? verse cmd line?

I've noticed better transcoding when I start a stream from the web interface of
vlc or from cmd line, than what the webserver does.

when started from webserver some sections of the image are blocky, and never really recover.
where when started from the http interface or cmd line from vlc, no blockyness..

probably a bug in vlc

Also vlc doesn't respect the --one-instance arg when started from web server
but does when started from cmd line


transcode.properties
VlcOpts=-I http --http-host :8080 --high-priority --one-instance --no-sub-autodetect-file %LOCAL_PATH% \:sout\=\#transcode{vcodec\=%VIDEO_CODEC%,vb\=%VIDEO_BITRATE%,scale\=%SCALE%,acodec\=%AUDIO_CODEC%,ab\=%AUDIO_BITRATE%,channels\=2,threads\=2%DEINTERLACE%}\:duplicate{dst\=std{access\=http,mux\=%MUX%,dst\=%SERVERPORT%}}

transcodeMode/work/256\ kbps\ mpeg2=mode\=vlc&vc\=mp1v&vb\=256&ac\=mpga&ab\=64&scale\=.5&mux\=mpeg1&serverport\=1080

cmd from cmd line that works well..
"c:\Program Files\VideoLAN\VLC\vlc.exe" -I http --http-host :8080 --high-priority --one-instance --no-sub-autodetect-file "H:\sage\StarTrek-TheGalileoSeven-2757054-0.mpg" :sout="#transcode{vcodec=mp1v,vb=256,scale=0.5,acodec=mpga,ab=64,channels=1}:duplicate{dst=std{access=http,mux=mpeg1,dst=:1080}}"


any thoughts? anyone else see this behavior?

thanks...
__________________
"don't praise the machine"
Reply With Quote
  #1482  
Old 03-27-2007, 04:30 PM
emok emok is offline
Sage Advanced User
 
Join Date: Jan 2006
Location: San Francisco Bay Area
Posts: 189
Quote:
Originally Posted by jamart3d View Post
I've noticed better transcoding when I start a stream from the web interface of
vlc or from cmd line, than what the webserver does.

when started from webserver some sections of the image are blocky, and never really recover.
where when started from the http interface or cmd line from vlc, no blockyness..

probably a bug in vlc

Also vlc doesn't respect the --one-instance arg when started from web server
but does when started from cmd line


transcode.properties
VlcOpts=-I http --http-host :8080 --high-priority --one-instance --no-sub-autodetect-file %LOCAL_PATH% \:sout\=\#transcode{vcodec\=%VIDEO_CODEC%,vb\=%VIDEO_BITRATE%,scale\=%SCALE%,acodec\=%AUDIO_CODEC%,ab\=%AUDIO_BITRATE%,channels\=2,threads\=2%DEINTERLACE%}\:duplicate{dst\=std{access\=http,mux\=%MUX%,dst\=%SERVERPORT%}}

transcodeMode/work/256\ kbps\ mpeg2=mode\=vlc&vc\=mp1v&vb\=256&ac\=mpga&ab\=64&scale\=.5&mux\=mpeg1&serverport\=1080

cmd from cmd line that works well..
"c:\Program Files\VideoLAN\VLC\vlc.exe" -I http --http-host :8080 --high-priority --one-instance --no-sub-autodetect-file "H:\sage\StarTrek-TheGalileoSeven-2757054-0.mpg" :sout="#transcode{vcodec=mp1v,vb=256,scale=0.5,acodec=mpga,ab=64,channels=1}:duplicate{dst=std{access=http,mux=mpeg1,dst=:1080}}"


any thoughts? anyone else see this behavior?

thanks...
I'm not sure about the "--one-instance" argument, but the blockiness you're seeing is most likely because the response from the webserver isn't buffered. I'm actually not seeing the issue you describe (maybe it's because my video quality expectations have already been lowered and I didn't really compare).

Basically, what's happening is vlc is being launched from java as a dos command and the webserver is taking the output from the vlc transcoding stream and writing it to the response that your vlc on the client machine is reading.

Request/Response flow:
VLC client --> Sage Webserver --> VLC "server"
VLC client <-- Sage Webserver <-- VLC "server"

The webserver is basically an extra hop between the vlc client and vlc "server" and there is no additional buffering going on. In addition, if the transcoding machine isn't powerful enough, it may not be able to keep up.

Perhaps a future release will have more intelligent buffering capabilities for this stream. Another option would be to have an "internal" mode which would allow the client to connect directly to the vlc process rather than going through the webserver.

E
Reply With Quote
  #1483  
Old 03-27-2007, 06:55 PM
Trouble's Avatar
Trouble Trouble is offline
Sage User
 
Join Date: Dec 2005
Posts: 11
Problem Playing back video

Hello,
I've been using VLC and the webserver successfully for quite a while now. I used to be able to play back videos just fine in firefox. Now I am getting a screen with no video or sound and the buttons on the webpage do not appear to play pause or skip.

Since I last tried video playback, I've updated to Java SE 6, Firefox 2.0.0.3, and VLC 8.6a. I have version 5 of Sagetv installed, running on Windows XP.

I've used about:plugins in firefox and see VLC listed for the media files I expect.

Any ideas? If use firefox on the machine that has the webserver it works. However I want to use a different computer to watch the videos on.

Thanks in advance!
Reply With Quote
  #1484  
Old 03-27-2007, 11:12 PM
jamart3d's Avatar
jamart3d jamart3d is offline
Sage User
 
Join Date: Jun 2006
Location: earth
Posts: 24
Quote:
Originally Posted by emok View Post
I'm not sure about the "--one-instance" argument, but the blockiness you're seeing is most likely because the response from the webserver isn't buffered. I'm actually not seeing the issue you describe (maybe it's because my video quality expectations have already been lowered and I didn't really compare).

Basically, what's happening is vlc is being launched from java as a dos command and the webserver is taking the output from the vlc transcoding stream and writing it to the response that your vlc on the client machine is reading.

Request/Response flow:
VLC client --> Sage Webserver --> VLC "server"
VLC client <-- Sage Webserver <-- VLC "server"

The webserver is basically an extra hop between the vlc client and vlc "server" and there is no additional buffering going on. In addition, if the transcoding machine isn't powerful enough, it may not be able to keep up.

Perhaps a future release will have more intelligent buffering capabilities for this stream. Another option would be to have an "internal" mode which would allow the client to connect directly to the vlc process rather than going through the webserver.

E
Hi emok,

Thanks for the explanation, I noticed vlc client is requesting the websever
to start streaming... but i didn't think the webserver did the streaming.

On a different machine than the server,
when I compare vlc client logs of webserver -vs- vlc http streams:
I do get alot of "dropping buffer main warning" from a webserver stream,
but not from http/cmd line vlc stream.

--one-instance is an option to "force" only one running instance of vlc,
so the java dos cmd / vlc appears to be doing something different.

vlc transcoding from either webserver or http takes less than half of my servers cpu usage.

I'd like to have the time to muck with the webserver and get it to "internally" control vlc via one of vlc's interfaces, like embedding vlc http interface into streamingoptions page. But just don't have the time..

superthanks tho, emok

I should paypal at least a beer to you, and everyone else
who had anything to do with this very useful sage customization.
__________________
"don't praise the machine"
Reply With Quote
  #1485  
Old 03-28-2007, 12:00 AM
sundansx sundansx is offline
Sage Advanced User
 
Join Date: Aug 2003
Posts: 193
For those of you debugging problems, here is a handy method...

download sysinternals (now ms) process explorer:
http://www.microsoft.com/technet/sys...sExplorer.mspx

open process explorer then start a streamed player via a client (can be local in loopback i presume).

Now right click on the sub-task called vlc.exe under SageTV or SageTVService and select properties.
In that dialog under the Image tab is the exact command line passed to vlc.exe

I have used this quite a bit in the past when launching stuff via php or perl.
Reply With Quote
  #1486  
Old 03-28-2007, 12:01 AM
nielm's Avatar
nielm nielm is offline
SageTVaholic
 
Join Date: Oct 2003
Location: Belgium
Posts: 4,496
Ideally, the webserver should proxy to VLC's VOD service, and control it by it's telnet interface, but that is a bit more complicated

[edit]except that the VLM VOD interface hangs as soon as I add a VOD media item...

Trouble: you need to update VLC/the vlc plugin. They changed the name of the Mozilla plugin a few versions back (compare the case of the name of the aboutlugins list with the one in player.html
__________________
Check out my enhancements for Sage in the Sage Customisations and Sageplugins Wiki

Last edited by nielm; 03-28-2007 at 02:30 AM.
Reply With Quote
  #1487  
Old 03-28-2007, 12:04 AM
Wheemer's Avatar
Wheemer Wheemer is offline
Sage Icon
 
Join Date: Dec 2004
Location: Deer Lake, NL, Canada
Posts: 1,493
Could the webserver ever be linked to orb? I find that a very effective streaming program.
Reply With Quote
  #1488  
Old 03-28-2007, 12:09 AM
emok emok is offline
Sage Advanced User
 
Join Date: Jan 2006
Location: San Francisco Bay Area
Posts: 189
Quote:
Originally Posted by jamart3d View Post
Hi emok,

Thanks for the explanation, I noticed vlc client is requesting the websever
to start streaming... but i didn't think the webserver did the streaming.

On a different machine than the server,
when I compare vlc client logs of webserver -vs- vlc http streams:
I do get alot of "dropping buffer main warning" from a webserver stream,
but not from http/cmd line vlc stream.

--one-instance is an option to "force" only one running instance of vlc,
so the java dos cmd / vlc appears to be doing something different.

vlc transcoding from either webserver or http takes less than half of my servers cpu usage.

I'd like to have the time to muck with the webserver and get it to "internally" control vlc via one of vlc's interfaces, like embedding vlc http interface into streamingoptions page. But just don't have the time..

superthanks tho, emok

I should paypal at least a beer to you, and everyone else
who had anything to do with this very useful sage customization.
haha... virtual beers are fine.

Actually, it's all Nielm. He's the glue that keeps everything together. He seems to spend countless hours on this stuff.

Regarding the one-instance option... if you specified this, would it potentially limit you to a single transcoded stream at once? I don't know how many servers would be able to handle transcoding two streams in realtime at the same time anyway.

I'll see if i can improve the buffer handling and add the ability to control the stream using vlc http interface in the next version.

E
Reply With Quote
  #1489  
Old 03-28-2007, 02:11 AM
nielm's Avatar
nielm nielm is offline
SageTVaholic
 
Join Date: Oct 2003
Location: Belgium
Posts: 4,496
re one-instance. WMP transcodes require a minimum of 2 instances, because for some strange reason, it requests the stream, closes it, then reopens it, and the webserver/VLC is sometimes not quick enough to shutdown the first before the second starts.

The webserver's transcoding manager does limit the number of VLC instances internally...

Quote:
He seems to spend countless hours on this stuff.
the wife would agree, but not in a positive way
__________________
Check out my enhancements for Sage in the Sage Customisations and Sageplugins Wiki
Reply With Quote
  #1490  
Old 03-28-2007, 02:13 AM
nielm's Avatar
nielm nielm is offline
SageTVaholic
 
Join Date: Oct 2003
Location: Belgium
Posts: 4,496
Quote:
Originally Posted by sundansx View Post
For those of you debugging problems, here is a handy method...
[...]
Now right click on the sub-task called vlc.exe under SageTV or SageTVService and select properties.
In that dialog under the Image tab is the exact command line passed to vlc.exe
easier method: look at the webserver's logging

[edit] actually this applies to the not-yet-released 2.14 version - please ignore!
__________________
Check out my enhancements for Sage in the Sage Customisations and Sageplugins Wiki

Last edited by nielm; 03-28-2007 at 07:53 AM.
Reply With Quote
  #1491  
Old 03-28-2007, 04:07 AM
Jason's Avatar
Jason Jason is offline
Sage Expert
 
Join Date: Nov 2003
Location: Texas
Posts: 598
Quote:
Originally Posted by Wheemer View Post
Could the webserver ever be linked to orb? I find that a very effective streaming program.
It actually can... at least according to Orb.

http://forums.sagetv.com/forums/show...postcount=1377

Here is the post on the Orb forums...

http://forums.orb.com/viewtopic.php?t=5919

If they can get the API finalized (working...) a simple command will allow anyone to use Orb's streaming from within another program...

-Jason
__________________
True standalone tuner functionality with the --> HAVA Channel Changer<--
Reply With Quote
  #1492  
Old 03-28-2007, 04:53 AM
nielm's Avatar
nielm nielm is offline
SageTVaholic
 
Join Date: Oct 2003
Location: Belgium
Posts: 4,496
Quote:
Originally Posted by Jason View Post
Exactly right!

<A href="http://mycast.orb.com/orb/data/stream.asx?q=path.filename="BattlestarGalactica-Rapture-4960918-0.mpg">http://mycast.orb.com/orb/data/stream.asx?q=path.filename="BattlestarGalactica-Rapture-4960918-0.mpg"

This will stream the file, based on a filename query... Yohan from Orb said basically the same as you... unfortunately it is not working for me.

If this can ever work, then a simple link from within the WebServer will utilize Orb as the streaming server...

-Jason
I had a quick look at the API doc... the search does work, provided you have an active session, but the format is a little odd..

To search for all video files (outputting all path info in the result)
Code:
https://mycast.orb.com/orb/xml/search?q=mediaType%3dvideo.file&fields=fileName,path.filename,path.extension,path.root,path.directory,path
To search for a specific file:
E:\Video\Movies\Fugitive.avi
you cannot search on a real path, but you can search on the filename only (not including the extension (%3D='=', %22='"', %20=' ')
giving:
Code:
https://mycast.orb.com/orb/xml/search?q=mediaType%3dvideo.file%20path.filename%3D%22fugitive%22&fields=fileName,path.filename,path.extension,path.root,path.directory,path

So, to generate ORB links, the webserver will have to know your ORB username/pass to be able to log onto your ORB account.

It then searches for the path.filename, and matches the full path in the results to get the medium ID

Once it has got the medium ID, the webserver can create streaming playlist links using the mediumID in the results
Code:
http://mycast.orb.com/orb/data/stream.asx?mediumId={mediumID}
http://mycast.orb.com/orb/data/stream.rm?mediumId={mediumID}
Note that if accessed directly, this will delay the detailed info servlet, as it has to access orb. Probably the best option is another OrbHandlerServlet linked in the detailed info servlet that
  • prompts for user/pass (via HTTP auth)
  • logs on to ORB
  • searches for mediumID
  • redirects to Orb's playlist.

Note that I am not going to implement this Someone else is welcome to do so, and I will integrate it

However, there is a quick and dirty method, at least in the current version of ORB.
First open ORB's non Ajax 'Home theater' or 'Mobile' interface by using the URL below:
https://mycast.orb.com/orb/html/inde...at=hometheatre

Then use this interface's search URL to search for the vid (append the filename to search without file extension)
Code:
https://mycast.orb.com/orb/html/video/search.html?title=video+Results&mediaType=video&goBack=3&start=0&search=Search&query=
Provided you have Sages' video paths in Orb, you should have a search result...

To switch back to orb's PC interface, use the Settings, or this URL
https://mycast.orb.com/orb/html/index.html?format=PC

I will put a link in the Streaming box with these links in the next version. Quick+dirty, but it may works.

(PS: Orbs transcoding is very hard on the CPU?!)
__________________
Check out my enhancements for Sage in the Sage Customisations and Sageplugins Wiki

Last edited by nielm; 03-28-2007 at 04:57 AM.
Reply With Quote
  #1493  
Old 03-28-2007, 10:18 PM
Trouble's Avatar
Trouble Trouble is offline
Sage User
 
Join Date: Dec 2005
Posts: 11
Problem Playing back video

Quote:
Originally Posted by nielm View Post
Ideally, the webserver should proxy to VLC's VOD service, and control it by it's telnet interface, but that is a bit more complicated

[edit]except that the VLM VOD interface hangs as soon as I add a VOD media item...

Trouble: you need to update VLC/the vlc plugin. They changed the name of the Mozilla plugin a few versions back (compare the case of the name of the aboutlugins list with the one in player.html
nielm, I've got a bit farther. Now I see a black screen with the text [no video].
Any other ideas? I checked the case of the strings that I found with VLC. I did notice that there are no file types associated with vlc in the plugins listiing. It used to have that before I re-installed vlc.

Thanks in advance.
Reply With Quote
  #1494  
Old 03-29-2007, 04:41 AM
Jason's Avatar
Jason Jason is offline
Sage Expert
 
Join Date: Nov 2003
Location: Texas
Posts: 598
Quote:
Originally Posted by nielm View Post
I had a quick look at the API doc...
Quite different... eh? :-)

Quote:
So, to generate ORB links, the webserver will have to know your ORB username/pass to be able to log onto your ORB account.

It then searches for the path.filename, and matches the full path in the results to get the medium ID

Once it has got the medium ID, the webserver can create streaming playlist links using the mediumID in the results
Actually, it is now (after they got back with me...) much easier. If you know the name of the file, you can stream based on that, ala...

http://mycast.orb.com/orb/data/stream.asx?q=path.filename="BattlestarGalactica-Rapture-4960918-0"

The difference from previous is that Orb does not need the ending file format... in this case ".mpg".

You are right that Orb does need to have an active session or the user/pass needs to be sent, but that is accomplished by the "u=username" and "p=password" prepends.

Quote:
The xml/search API always requires a valid session, even to search public shared lists. However the xml/rss doesn't require a session.
Quote:
I will put a link in the Streaming box with these links in the next version. Quick+dirty, but it may works.

(PS: Orbs transcoding is very hard on the CPU?!)
With this, the requirement of having/searching/knowing the mediumid is not required anymore and having a simple link with the filename can start a stream...

Here is the post from yohan (orb) clarifying this for me...

http://forums.orb.com/viewtopic.php?t=5919

-Jason
__________________
True standalone tuner functionality with the --> HAVA Channel Changer<--
Reply With Quote
  #1495  
Old 03-29-2007, 10:00 AM
nielm's Avatar
nielm nielm is offline
SageTVaholic
 
Join Date: Oct 2003
Location: Belgium
Posts: 4,496
v2.14 released

v 2.14 29/Mar/2007
BUGFIXES
* Transcoding now works on segmented files
* better logging for transcoder
* Quotes paths in transcode.properties

ENHANCEMENTS
* added ToonGal's Full webremote (and ability to switch between them)
* added ability to name extenders using 'extenders.properties' file
* (paused) indication on Home screen for paused playback
* added link to search for file on Orb / stream file via ORB
* basic streamed DVD transcoding added (only title 1 with the default audio track)
__________________
Check out my enhancements for Sage in the Sage Customisations and Sageplugins Wiki

Last edited by nielm; 03-29-2007 at 10:08 AM.
Reply With Quote
  #1496  
Old 03-29-2007, 11:39 AM
rickgillyon's Avatar
rickgillyon rickgillyon is offline
Sage Icon
 
Join Date: Sep 2005
Location: Whitley Bay, England
Posts: 1,950
Wow, that was quick! Thanks, will give it a try tomorrow.
__________________
unRAID Server: Intel Core i5 7600K, 48GB DDR4, 2x512GB PCIe M.2 Cache Pool, 2x10TB SATA3 Parity Drive, 3x8TB SATA Array, 1x hdHomeRun DVB-T2 Quattro, IPTV via xTeVe, unRAID 6.8.3, tvHeadEnd for recording back end, Emby
Clients: 3 Nvidia Shields, 3 FireTV, 3 Win10 Pro PC Clients
Reply With Quote
  #1497  
Old 03-29-2007, 11:59 AM
bcjenkins bcjenkins is offline
SageTVaholic
 
Join Date: Jan 2006
Posts: 3,764
Quote:
Originally Posted by nielm View Post
v 2.14 29/Mar/2007
BUGFIXES
* Transcoding now works on segmented files
* better logging for transcoder
* Quotes paths in transcode.properties

ENHANCEMENTS
* added ToonGal's Full webremote (and ability to switch between them)
* added ability to name extenders using 'extenders.properties' file
* (paused) indication on Home screen for paused playback
* added link to search for file on Orb / stream file via ORB
* basic streamed DVD transcoding added (only title 1 with the default audio track)
yeah! just in time to go on vacation.. Now I can stream DVDs at the inlaws
Reply With Quote
  #1498  
Old 03-30-2007, 10:02 AM
dpackham dpackham is offline
Sage Advanced User
 
Join Date: May 2006
Posts: 160
Can you customize the the Web UI guides to show which shows are recorded in HD? maybe by showing the HD icon like the full guide does?

Dave P
Reply With Quote
  #1499  
Old 03-30-2007, 12:25 PM
jreichen's Avatar
jreichen jreichen is offline
Sage Icon
 
Join Date: Jul 2004
Posts: 1,192
Quote:
Originally Posted by dpackham View Post
Can you customize the the Web UI guides to show which shows are recorded in HD? maybe by showing the HD icon like the full guide does?

Dave P
Click the Show Options link at the bottom of the page to display options for the guide. One of the options is to show HD markers.
__________________
Server: Intel Core i5 760 Quad, Gigabyte GA-H57M-USB3, 4GB RAM, Gigabyte GeForce 210, 120GB SSD (OS), 1TB SATA, HD HomeRun.
Extender: STP-HD300, Harmony 550 Remote,
Netgear MCA1001 Ethernet over Coax.
SageTV: SageTV Server 7.1.8 on Ubuntu Linux 11.04, SageTV Placeshifter for Mac 6.6.2, SageTV Client 7.0.15 for Windows, Linux Placeshifter 7.1.8 on Server and Client
, Java 1.6.
Plugins: Jetty, Nielm's Web Server, Mobile Web Interface.

Reply With Quote
  #1500  
Old 03-30-2007, 07:48 PM
bcjenkins bcjenkins is offline
SageTVaholic
 
Join Date: Jan 2006
Posts: 3,764
Using the DVD playback, I am only able to get a few of the profiles to work.

I am at the inlaws, here's the speedtest.

Current Throughput
KiloBits/Sec : 709.2
KiloBytes/Sec : 88.7

The profiles which work are:

# 128kbit deinterlaced quarter-res

* [Play in Web-player]
* Play in External Player: [wvx] [m3u] [pls]

# 256kbit deinterlaced third-res

* [Play in Web-player]
* Play in External Player: [wvx] [m3u] [pls]

# 352kbit deinterlaced third-res

* [Play in Web-player]
* Play in External Player: [wvx] [m3u] [pls]

If I play

# 480kbit deinterlaced half-res

* [Play in Web-player]
* Play in External Player: [wvx] [m3u] [pls]

I get a strip of video in the web browser window and audio. I would like to bump up the bits to clean up the picture.

Any suggestions? I am using the VLC plugin on OS X.

B
Reply With Quote
Reply

Tags
web


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Plugin: Mobile Web Interface 1.2 jreichen SageTV Customizations 281 06-17-2011 02:20 PM
Can't get Web-based User Interface to install SSBrian SageTV Customizations 3 11-04-2008 08:12 PM
Web User interface link for the metadata file. zzmystique SageTV Customizations 0 06-21-2008 02:26 AM
Idea to enhance the Web User Interface: Messaging jbarr SageTV Customizations 3 05-14-2007 03:59 PM
Linkplayer, Linktheater with SageTV Web User Interface fyodor SageTV Customizations 0 10-08-2006 06:03 PM


All times are GMT -6. The time now is 06:33 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.