Jump to content

Recommended Posts

Posted

Can we add Aspect Ratio to the movie information???  2:39:1, 1.85:1  etc

Particularly if it uses a Variable Aspect Ratio like many movies now do?? 

Posted

Hi, we do already detect this from the video information.

  • Like 1
Posted (edited)

I see that on my PC, but not on my Roku.  I'll look again, thank you!

Edited by Cain57
Posted (edited)

Also, I'm looking at the Movie  "Abigail" 

IMDB says it is 2.39:1  

Rotten Tomatoes says 2.39:1

Emby says 2.40:1

 

Edited by Cain57
Posted
5 hours ago, Cain57 said:

Also, I'm looking at the Movie  "Abigail" 

IMDB says it is 2.39:1  

Rotten Tomatoes says 2.39:1

Emby says 2.40:1

 

What's your video resolution?

Posted
16 hours ago, Cain57 said:

see that on my PC, but not on my Roku. 

The Roku does not show detailed media information at this time.  We may add this as an option but most Roku users like the clean, simple, uncluttered interface.

  • Like 1
Posted

No wonder I could not find it on the Roku!   FYI. Many people with dedicated home theaters use a Roku. Aspect ratio is important to us.  Exact AR. 
 

bTW love me some Emby!!!! Match made in heaven for my NAS. 

  • Like 1
  • 3 weeks later...
mguebert
Posted

Could this be added to a webhook? It would be very cool to send a webhook request and have it auto load a lens memory on my projector for a given aspect ratio!!!

Posted
2 hours ago, mguebert said:

Could this be added to a webhook? It would be very cool to send a webhook request and have it auto load a lens memory on my projector for a given aspect ratio!!!

Hi, doesn't the playback start webhook have all of the data that you need?

mguebert
Posted

I need to investigate this further, right now it is just triggering a lighting script in Home Assistant. 

 

  • Thanks 1
Posted

Let us know what you find. Thanks.

MohamedKhaldi
Posted

you can use the coverart plugin to add aspect ratio information

mguebert
Posted (edited)
On 6/2/2024 at 1:04 AM, Luke said:

Let us know what you find. Thanks.

Using this mask on the webhook data I do get the apsect ratio of the movie being played.

 {% set data = trigger.json %} {% if data and data['Item'] and
    data['Item']['PrimaryImageAspectRatio'] %}
      Aspect Ratio: {{ data['Item']['PrimaryImageAspectRatio'] }}
    {% else %}
      Aspect Ratio: unknown
    {% endif %}

 

It appears this is static as with movies the change during playback such as Guardians of the Galaxy the initial ap stays. Can this behavior be altered?

 

It also doesn't seem to match, for instance Emby says Joker is 24:13, imdb says 1.85 to 1, and the webhook puts out 

Emby Aspect Ratio

Aspect Ratio: 0.6666666666666666

 

One other thing I noticed is that using cinema intros won't integrate well with using webhooks to trigger lighting scenes, it sends pause, play, pause, play triggers so fast the lighting loses its state and gets caught in a no mans land (read not correct lol), I am going to experiment with delays to prevent it, but was wondering if this could be changed also?

 

 

Edited by mguebert
Posted
Quote

and the webhook puts out 

Emby Aspect Ratio

Aspect Ratio: 0.6666666666666666

Hi, I think you're looking at the wrong field. That sounds like PrimaryImageAspectRatio, which is the aspect ratio of the movie poster, not the video file.

If you look over the whole payload you should see the raw video info in there with the aspect ratio. 

Posted
Quote

One other thing I noticed is that using cinema intros won't integrate well with using webhooks to trigger lighting scenes, it sends pause, play, pause, play triggers so fast the lighting loses its state

Hi, can you please provide a specific example, showing the exact sequence of events in question? Thanks !

mguebert
Posted
On 6/8/2024 at 12:35 AM, Luke said:

Hi, I think you're looking at the wrong field. That sounds like PrimaryImageAspectRatio, which is the aspect ratio of the movie poster, not the video file.

If you look over the whole payload you should see the raw video info in there with the aspect ratio. 

I looked over the whole payload and I don't see it, I see the MediaType":"Video","Width":3840,"Height":2160 and TranscodingStartPositionTicks":0,"Width":3840,"Height":2160 but I don't see any tags or numbers indicating aspect ratio other than the primaryImageAspectRatio

 

I can try and collect the triggers on the webhooks, is there a specific way you would like me to do that?

I can load the trace for the Home Assistant scripts if that would help? 

Posted
34 minutes ago, mguebert said:

I looked over the whole payload and I don't see it, I see the MediaType":"Video","Width":3840,"Height":2160 and TranscodingStartPositionTicks":0,"Width":3840,"Height":2160 but I don't see any tags or numbers indicating aspect ratio other than the primaryImageAspectRatio

 

I can try and collect the triggers on the webhooks, is there a specific way you would like me to do that?

I can load the trace for the Home Assistant scripts if that would help? 

OK maybe we're not sending everything there, but you can use Width and Height, no?

crusher11
Posted

Detecting AR that way only works if the content has been cropped to remove black bars, and then re-encoded.

mguebert
Posted
On 6/9/2024 at 1:53 PM, Luke said:

OK maybe we're not sending everything there, but you can use Width and Height, no?

Yeah that is the video resolution, the black bars are encoded into the video and I use the motorized zoom on my projector to fill the screen. So I was hoping to use that info to automate that for my wife :)

As far a the lighting it works awesome if I turn off the cinema intros, when they are on it seems any time the audio codec videos play the lighting goes wonky. So for now I have them turned off, but I would like to get them working so how would you like me to document?

 

A video showing it?

Home assistant logs?

Thx

crusher11
Posted

Right, for a projector lens memory you need to know the aspect ratio of the actual content, not the video file. Emby currently doesn't store that. I believe it was stored at one time, but that was removed.

Mind you, releases are often not quite the same AR as the theatrical presentation, and I've even encountered discs where the movie is wildly off-center, so best-case you're doing it manually anyway, but Emby still needs a place to store the info and send it on playback for automation.

And do it per file, not per movie.

crusher11
Posted
On 6/4/2024 at 8:54 PM, mguebert said:

It also doesn't seem to match, for instance Emby says Joker is 24:13, imdb says 1.85 to 1

24 ÷ 13 = 1.85.

I've never used webhooks and have no idea how they work. How does one send all this info? I only see checkboxes for, eg, "playback start", nothing about aspect ratio or video size or tags or any other useful attributes.

Posted

@Cain57so what you are actually asking for is the original film aspect ratio in metadata?

 

seanbuff
Posted
On 24/06/2024 at 22:37, crusher11 said:

I've never used webhooks and have no idea how they work. How does one send all this info? I only see checkboxes for, eg, "playback start", nothing about aspect ratio or video size or tags or any other useful attributes.

Extended information of the media is sent in the payload of the webhook for a 'Playback Start' event for example. You can quickly test this out yourself by creating a webhook in Emby for 'Playback > Start' and sending it to a unique URL provided by https://webhook.site/

They will generate a unique URL such as:
image.png.12d0449bf0c3a42b2c64606ed1bd3d8a.png


which you can then use to have Emby send the 'Playback START' event to:
image.png.74dc03948d5ea4f69c9b9a11320422f5.png


Click 'Play' on something, and back in the Webhook.site window, you'll instantly see the payload come through with all the information sent from Emby:

Quote

{
    "Title": "TestyMcTest is playing The Bourne Identity on Chrome Windows",
    "Date": "2024-06-27T23:55:19.3093682Z",
    "Event": "playback.start",
    "User": {
      "Name": "TestyMcTest",
      "Id": "85d493d7ce3b4ecc9a765bd3885116cf"
    },
    "Item": {
      "Name": "The Bourne Identity",
      "OriginalTitle": "The Bourne Identity",
...
      ],
      "MediaType": "Video",
      "Width": 1920,
      "Height": 816
    },

However, as discussed further up in this thread, the "Aspect Ratio" information for the media is noticeably missing from the payload.

So while the above is good as a quick test to see the information being sent from Emby, what you ultimately do with that information is up to you. A common use would be to send this information to an automation platform like Home Assistant where you can use it to trigger actions tied to IR blasters, or curtain motors, SwitchBots, etc.

But as it stands currently, probably a non-starter without at least the detected aspect ratio information being sent from Emby, @Lukeis that something that can be added?

Posted

All of the media info that the server has should be part of the webhook payload.

seanbuff
Posted
17 minutes ago, Luke said:

All of the media info that the server has should be part of the webhook payload.

Well I'm not sure what you're referring to when you say "all of the media info" because I can see the info is there on the server, but it's just not passed along in the payload:
image.png.d9fd30cfe83ae725e979bf3189ceea3b.png

The only part of the media that is in the payload is what I shared above, the width and height

I have checked numerous payloads of media that I know the server has info for, and it is in fact not included in the payload.

I think you even confirmed that yourself:

On 10/06/2024 at 04:53, Luke said:

OK maybe we're not sending everything there

 

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...