Jump to content
fizzyade

IPTV Plugin users

Recommended Posts

fizzyade

Hi,

 

Would it be possible to limit the IPTV channels to specific users (like we do with libraries), I have just installed and added our security cameras to the IPTV plugin and there appears to be no way of limiting who can see what, obviously I don't want friends and family seeing our cameras, just us.

 

The plugin is working brilliantly, I tried the tv plugin a while back with m3u file and couldn't get it to work properly, but this works really well.

 

This would be a really useful feature.

Share this post


Link to post
Share on other sites
fizzyade

Just realised the source for this plugin is available and there's a "isAvailableFor" function which returns true for every user, so I should be able to hack this in fairly easily if it works how I expect it to.

 

This would be a nice feature though.

Share this post


Link to post
Share on other sites
legallink

Can it not be restricted either via live tv access or channel access in each users profile?

Share this post


Link to post
Share on other sites
fizzyade

Can it not be restricted either via live tv access or channel access in each users profile?

 

Cheers, must have had a brain fart, yep I can disable the IPTV channel for those users through their profile.  Perfect.

Share this post


Link to post
Share on other sites
fizzyade

@@Luke as this is one of yours judging by the git repo, I'm seeing a time delay in the rtsp stream.  If I open it in emby it takes maybe 7-8 seconds before it starts to play which corresponds to the amount of real time lag I'm seeing.  If I open the stream in VLC there appears to be no lag, it's in realtime (although there is "corruption" of the stream until it receives key frames)

 

Any thoughts on this?

Share this post


Link to post
Share on other sites
fizzyade

No thoughts. How to report a media playback issue:

https://emby.media/community/index.php?/topic/739-how-to-report-a-problem/

Thanks.

 

Having a read around it appears that the "-probesize" switch for ffmpeg should be set to a low value for low latency streaming (just read a load of pages from a google search and they all say the same thing), is it possible to do this?

Share this post


Link to post
Share on other sites
Luke

No it's not. That can also cause problems.

Share this post


Link to post
Share on other sites
fizzyade

No it's not. That can also cause problems.

 

Yeah, I appreciate that it's probably not desired for 99% of applications, but for rtsp streaming it appears to be a requirement for low latency streaming.  I wish there were an option in transcoding settings to add your own switches to ffmpeg (with warning, only for developers) so that testing things like this was easier.

Share this post


Link to post
Share on other sites
fizzyade

i realise this is a different issue, but i believe it’s related to this as it has the same behaviour.

 

Live TV is incredibly slow to switch channels, we’re talking 5+ seconds.  i’m using tvheadend with a m3u playlist in emby.  If i directly start a stream in VLC it’s pretty much instant at playing, but emby takes an age to get going.

Share this post


Link to post
Share on other sites
Luke

What kind of tuner? If it's something you can import into emby directly without tvh it will likely be better.

Share this post


Link to post
Share on other sites
fizzyade

What kind of tuner? If it's something you can import into emby directly without tvh it will likely be better.

 

 

Sadly not, i’m using the xboxone usb tuners but my emby is a docker container under unraid, unraid doesn’t include the drivers for dvb cards so it won’t work.  there is a modified kernel with the DVB drivers, but i already use the Nvidia kernel for hardware transcoding.

Share this post


Link to post
Share on other sites
Luke

What are you trying to compare against Vlc?

Share this post


Link to post
Share on other sites
fizzyade

What are you trying to compare against Vlc?

 

A stream, if I manually copy say the "BBC ONE" entry from the m3u and paste it into VLC it starts almost immediately.

 

If I select "BBC ONE" in Emby then it takes considerably longer for the playback to begin.

Share this post


Link to post
Share on other sites
Luke

What do you mean in Emby? What Emby app?

Share this post


Link to post
Share on other sites
fizzyade

What do you mean in Emby? What Emby app?

 

If I go to the channel in live tv and open it then it takes quite a while before it starts to stream from emby.

 

If I copy the same stream (or a different one so that the tuner is not set to it) http link from the m3u file into VLC it plays almost immediately.

 

Doesn't matter which emby client, I've tried Shield (Adnroid TV), iOS (iPad & iPhone), Web client, they all behave exactly the same say, it takes a long time for the stream to start from inside emby from live tv.

 

I'm running all the latest clients and my server is running the latest beta.

Share this post


Link to post
Share on other sites
Luke

You can't compare the web app to Vlc as it has limited format support. if you want to make an equal comparison, try something like Emby Theater for Windows desktop.

Share this post


Link to post
Share on other sites
fizzyade

You can't compare the web app to Vlc as it has limited format support. if you want to make an equal comparison, try something like Emby Theater for Windows desktop.

 

I had a quick go on a VM (I'm a mac user) running on my unraid server, it still didn't seem as quick as I'd expect, but I'll have to do more testing to be sure.

Share this post


Link to post
Share on other sites
fizzyade

You can't compare the web app to Vlc as it has limited format support. if you want to make an equal comparison, try something like Emby Theater for Windows desktop.

 

 

actually, i’ve just tried again on my shield and it’s showing as direct streaming in emby to it.  i only mentioned web before as it was one thing i tried, but i don’t actually use the web client, 99% of the time its playback through the shield.

 

And the issue still shows up, theres a considerable lag before playback starts on the nvidia shield when it is direct streaming from the server.  As mentioned, playing the same stream directly in VLC (cutting and pasting the link from the m3u file) results in almost immediate playback.

 

Both VLC and Emby are effectively direct streaming unless i’m missing something fundamental here.

Share this post


Link to post
Share on other sites
Luke

We'd have to look at an example. Thanks.

Share this post


Link to post
Share on other sites
fizzyade

We'd have to look at an example. Thanks.

 

 

cool, i’ll prepare some log files tomorrow and try to give some idea of the times taken for playback to start.

Share this post


Link to post
Share on other sites
fizzyade

having done a lot of trial and error with ffmpeg in tvheadend i know what is going on.

 

ps -ax on my emby server shows the Emby ffmpeg command with the command line, analyseduration is set to 3 seconds, this is part of the issue with the long start up times affecting this issue and what i posted about before with IPTV viewing.

 

Allowing us to change that (per source, i.e per tv m3u and per iptv source) would allow us to tune the output to our particular needs.

 if we know what we’re doing.

 

i even set up hardware transcoding on tvheadend converting the video to 264 with a analyze duration of 100000, this gave me a much faster startup when using ffmpeg in tvheadend (it defaults to 5 seconds, so when i was trying ffmpeg initially in tvheadend i was seeing the same sort of delay).

 

however, once emby gets hold of the stream it then has a duration of 3 seconds to detect the stream, but once it’s done that it direct plays because tvh is providing a h264 stream instead of a mpeg2 which causes emby to do the transcoding.

 

i’m almost tempted to write a python script to proxy the ffmpeg command and dynamically change your duration on the fly to test out my theory.

Share this post


Link to post
Share on other sites
fizzyade

well, there’s still a lag.....but it’s better by 2 seconds!
 

i just renamed ffmpeg and created a shell script that nieavely replaced 3000000 with 1000000 and then called the original binary.

Share this post


Link to post
Share on other sites
fizzyade

What kind of tuner? If it's something you can import into emby directly without tvh it will likely be better.

 

 

i’m really stumped by this, the latency on m3u streams into emby is just so high.  My Security cameras take 10 seconds to start showing a stream and we’re talking 5 seconds + for tv to stream.

 

If i expose some of this stuff to the net and give you access will you be able to take a look?

 

Thanks

Share this post


Link to post
Share on other sites
Luke

If it can't direct play then it's not a big surprise.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...