crusher11 1101 Posted June 28, 2024 Posted June 28, 2024 Even then, that doesn't help with a situation where the video content is letterboxed or pillarboxed. Could be done by renaming files, or creating a subfolder for each aspect ratio, but other than that...needs either a specific metadata field or to pass tags - and to do so per file, not per title.
Luke 42077 Posted June 29, 2024 Posted June 29, 2024 On 6/28/2024 at 12:48 AM, seanbuff said: 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: 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: Did you look underneath the NowPlayingItem object that is inside the payload?
crusher11 1101 Posted June 30, 2024 Posted June 30, 2024 I did a Ctrl+F for "NowPlayingItem" and it came up empty. That said, this still doesn't address the issue of content letterboxed or pillarboxed into a 16:9 container.
ebr 16169 Posted July 5, 2024 Posted July 5, 2024 My suggestion is that, if aspect ratio is that important to your setup - e.g. you have a projector you wish to zoom - then you should be sure and properly crop your items to that aspect. Any pure metadata solution is too apt to be incorrect and there is no definitive source.
crusher11 1101 Posted July 5, 2024 Posted July 5, 2024 Cropping requires re-encoding, which costs both quality and time. A metadata-sourced number will be right (or near enough) far more often than not, and if the field exists it can be manually edited in the rare cases it needs to be.
crusher11 1101 Posted July 6, 2024 Posted July 6, 2024 And irrespective of that, @Luke seems to think the webhook is sending information it isn't actually sending, given his reference to "NowPlayingItem" which is not a phrase that occurs anywhere in anything I can find.
Luke 42077 Posted July 6, 2024 Posted July 6, 2024 3 hours ago, crusher11 said: And irrespective of that, @Luke seems to think the webhook is sending information it isn't actually sending, given his reference to "NowPlayingItem" which is not a phrase that occurs anywhere in anything I can find. Which webhook event are you referring to?
Luke 42077 Posted July 10, 2024 Posted July 10, 2024 12 hours ago, crusher11 said: @Luke Can you provide an example payload that you're seeing? (the complete payload). Thanks.
crusher11 1101 Posted July 12, 2024 Posted July 12, 2024 On 7/10/2024 at 11:44 AM, Luke said: Can you provide an example payload that you're seeing? (the complete payload). Thanks. { "Title": "$username is playing Poor Things on $device", "Date": "2024-07-12T05:14:30.2915031Z", "Event": "playback.start", "User": { "Name": "$username", "Id": "8e338ff7d455419d95098f69d05c4f67" }, "Item": { "Name": "Poor Things", "OriginalTitle": "Poor Things", "ServerId": "c11c4127bcd8435dab7937b682b24192", "Id": "9179538", "DateCreated": "2024-05-20T17:40:20.0000000Z", "Container": "mkv", "SortName": "Poor Things", "PremiereDate": "2023-12-06T16:00:00.0000000Z", "ExternalUrls": [ { "Name": "IMDb", "Url": "https://www.imdb.com/title/tt14230458" }, { "Name": "MovieDb", "Url": "https://www.themoviedb.org/movie/792307" }, { "Name": "Trakt", "Url": "https://trakt.tv/search/tmdb/792307?id_type=movie" } ], "Path": "$storage\\Emby Libraries\\TN\\Movies\\P\\Poor Things (2023)\\Poor Things (2023).mkv", "OfficialRating": "AU-MA15+", "Overview": "Brought back to life by an unorthodox scientist, a young woman runs off with a debauched lawyer on a whirlwind adventure across the continents. Free from the prejudices of her times, she grows steadfast in her purpose to stand for equality and liberation.", "Taglines": [ "She's like nothing you've ever seen." ], "Genres": [ "Science Fiction", "Romance", "Comedy" ], "CommunityRating": 7.9, "RunTimeTicks": 84999910000, "Size": 37068181141, "FileName": "Poor Things (2023).mkv", "Bitrate": 34887736, "ProductionYear": 2023, "RemoteTrailers": [ { "Url": "https://www.youtube.com/watch?v=RlbR5N6veqw" }, { "Url": "https://www.youtube.com/watch?v=muuLGNH3JRQ" }, { "Url": "https://www.youtube.com/watch?v=-EfYJWRw2FM" } ], "ProviderIds": { "Imdb": "tt14230458", "Tmdb": "792307" }, "IsFolder": false, "ParentId": "9179537", "Type": "Movie", "Studios": [ { "Name": "Searchlight Pictures", "Id": 885999 }, { "Name": "Film4 Productions", "Id": 3374 }, { "Name": "TSG Entertainment", "Id": 3656 }, { "Name": "Element Pictures", "Id": 113982 } ], "GenreItems": [ { "Name": "Science Fiction", "Id": 1615 }, { "Name": "Romance", "Id": 1607 }, { "Name": "Comedy", "Id": 1647 } ], "TagItems": [], "PrimaryImageAspectRatio": 0.6666666666666666, "ImageTags": { "Primary": "1de8b6ef9abfd4e09a07238ae6858dbb", "Logo": "dafb83b6f133b16dbbad749f69071949", "Thumb": "d399680b3be85057d6ff7be9596bdf3c" }, "BackdropImageTags": [ "ab455524e6a2ecb2eb0a8d0415a84c61" ], "MediaType": "Video", "Width": 1920, "Height": 1080 }, "Server": { "Name": "MBEMBY", "Id": "c11c4127bcd8435dab7937b682b24192", "Version": "4.9.0.26" }, "Session": { "RemoteEndPoint": "192.168.0.201", "Client": "Emby Theater", "DeviceName": "$device", "DeviceId": "$device", "ApplicationVersion": "3.0.21", "Id": "dae262a8c675e7107d00d526cb299176" }, "PlaybackInfo": { "PositionTicks": 0, "PlaylistIndex": 0, "PlaylistLength": 1, "PlaySessionId": "0bab1e52e4134eabb318093715e18424" } }
Luke 42077 Posted July 13, 2024 Posted July 13, 2024 23 hours ago, crusher11 said: { "Title": "$username is playing Poor Things on $device", "Date": "2024-07-12T05:14:30.2915031Z", "Event": "playback.start", "User": { "Name": "$username", "Id": "8e338ff7d455419d95098f69d05c4f67" }, "Item": { "Name": "Poor Things", "OriginalTitle": "Poor Things", "ServerId": "c11c4127bcd8435dab7937b682b24192", "Id": "9179538", "DateCreated": "2024-05-20T17:40:20.0000000Z", "Container": "mkv", "SortName": "Poor Things", "PremiereDate": "2023-12-06T16:00:00.0000000Z", "ExternalUrls": [ { "Name": "IMDb", "Url": "https://www.imdb.com/title/tt14230458" }, { "Name": "MovieDb", "Url": "https://www.themoviedb.org/movie/792307" }, { "Name": "Trakt", "Url": "https://trakt.tv/search/tmdb/792307?id_type=movie" } ], "Path": "$storage\\Emby Libraries\\TN\\Movies\\P\\Poor Things (2023)\\Poor Things (2023).mkv", "OfficialRating": "AU-MA15+", "Overview": "Brought back to life by an unorthodox scientist, a young woman runs off with a debauched lawyer on a whirlwind adventure across the continents. Free from the prejudices of her times, she grows steadfast in her purpose to stand for equality and liberation.", "Taglines": [ "She's like nothing you've ever seen." ], "Genres": [ "Science Fiction", "Romance", "Comedy" ], "CommunityRating": 7.9, "RunTimeTicks": 84999910000, "Size": 37068181141, "FileName": "Poor Things (2023).mkv", "Bitrate": 34887736, "ProductionYear": 2023, "RemoteTrailers": [ { "Url": "https://www.youtube.com/watch?v=RlbR5N6veqw" }, { "Url": "https://www.youtube.com/watch?v=muuLGNH3JRQ" }, { "Url": "https://www.youtube.com/watch?v=-EfYJWRw2FM" } ], "ProviderIds": { "Imdb": "tt14230458", "Tmdb": "792307" }, "IsFolder": false, "ParentId": "9179537", "Type": "Movie", "Studios": [ { "Name": "Searchlight Pictures", "Id": 885999 }, { "Name": "Film4 Productions", "Id": 3374 }, { "Name": "TSG Entertainment", "Id": 3656 }, { "Name": "Element Pictures", "Id": 113982 } ], "GenreItems": [ { "Name": "Science Fiction", "Id": 1615 }, { "Name": "Romance", "Id": 1607 }, { "Name": "Comedy", "Id": 1647 } ], "TagItems": [], "PrimaryImageAspectRatio": 0.6666666666666666, "ImageTags": { "Primary": "1de8b6ef9abfd4e09a07238ae6858dbb", "Logo": "dafb83b6f133b16dbbad749f69071949", "Thumb": "d399680b3be85057d6ff7be9596bdf3c" }, "BackdropImageTags": [ "ab455524e6a2ecb2eb0a8d0415a84c61" ], "MediaType": "Video", "Width": 1920, "Height": 1080 }, "Server": { "Name": "MBEMBY", "Id": "c11c4127bcd8435dab7937b682b24192", "Version": "4.9.0.26" }, "Session": { "RemoteEndPoint": "192.168.0.201", "Client": "Emby Theater", "DeviceName": "$device", "DeviceId": "$device", "ApplicationVersion": "3.0.21", "Id": "dae262a8c675e7107d00d526cb299176" }, "PlaybackInfo": { "PositionTicks": 0, "PlaylistIndex": 0, "PlaylistLength": 1, "PlaySessionId": "0bab1e52e4134eabb318093715e18424" } } OK yes I see the issue, thanks.
crusher11 1101 Posted July 24, 2024 Posted July 24, 2024 On 7/5/2024 at 10:46 PM, ebr said: My suggestion is that, if aspect ratio is that important to your setup - e.g. you have a projector you wish to zoom - then you should be sure and properly crop your items to that aspect. Any pure metadata solution is too apt to be incorrect and there is no definitive source. Even just passing tags to the webhook would be a huge help, as long as it passes the tags for that specific file and not just any set of tags for the title (for example, the 3D version of Titanic is 1.78:1, the 2D version is 2.40:1), and could no doubt have many other uses as well.
visproduction 315 Posted November 11, 2024 Posted November 11, 2024 (edited) Media online often has wrong Aspect Ratio (AR): Encoding software rounds off height. The original editor did it wrong. Encoding software can have 2.375, half way between 2.35 and 2.39. This is wrong for both aspect ratios, but the software designer offers it anyway. Perhaps they think no one can see the difference. Media grabbed from DVD starts off squashed by 10% and can easily be converted to the wrong aspect ratio. Black bars in the media makes it easy to make a mistake in the AR. Many editors think that 1.78 is correct, but it should be 1.85. Also they think 1.33 is right when it should be 1.37. Or 1.78 is used for 1.67, 2.35 used for 2.39 or for 2.2. It happens all the time. I would guess that 10 to 20% of online media has the wrong aspect ratio. Encoding to original or reduced resolutions cannot actually get to an exact original aspect ratio. Streaming playback with odd pixel height or width is not allowed. So at certain widths, it is impossible to get the AR exactly right. You can often only get close. A 1280 x 534 (720P) version of a 2.39 aspect ratio film would actually be 2.3970037... A 1920 x 804 (1080P) version would be 2.3880597.... Very often encoders auto set the height on a 1920px width 2.39 AR to 800 exactly without cropping, because encoding is more efficient in multiples of 16 and they think no one can see the difference. This becomes an aspect ratio of 2.40 when the original is listed as 2.39. If the media AR is wrong, isn't it better to show how far off it is? If the media has a wrong aspect ratio and essentially needs to be reencoded to fix it, what is preferred to be shown? Currently, the exact aspect ratio in Emby is shown in the lowest possible whole number fraction. A ratio of height = 1, could be added as a second AR listing, but rounded it up or down is not really nice, because then you won't know how far off the media aspect ratio is. Media currently listed correctly as Aspect Ratio 640:267 can be converted to ratio of 1 = height to 2.3970037... Is this acceptable? You can see that it is a little off, but certainly good enough for setting a variable height projection screen. Do you want to show, instead, what it should be and just show 2.39? What is the point of putting up incorrect information for a media that has wrong or slightly off AR? Interactive calculators on my site for AR Related FYI: I have an aspect ratio encoding calulator page aimed at AVIDemux software. It shows how far off some width / height combinations would be for aspect ratios. https://www.producerelease.com/blu-ray/parcalc.htm#wraphrcalc Notice in the image how close that 1920 width can get to 2.39. It's good enough. Now try getting 1280 (720P) to work with 2.39. Again close, but not perfect. It shows how most AR are compromises. Fraction of 1 pixel cannot really be seen. 4 pixels off, can be seen. Further up the web page are other AR calculators. Edited November 11, 2024 by visproduction
RaptorCentauri 59 Posted November 11, 2024 Posted November 11, 2024 I'd like the aspect ratio given in the media info of a file to reflect the actual aspect ratio of the content, rather than the video file itself. This could be done be either respecting the aspect ratio tag in an nfo, or properly determining the aspect ratio using something like ffmpeg. Tinymediamanager does something similar. The need/ justification for this comes mostly from blu ray remuxes. All BD remuxes are technically 16:9, however the films could actually be something else, such as 2.39:1. I'd like to the information to reflect that.
visproduction 315 Posted November 12, 2024 Posted November 12, 2024 18 hours ago, RaptorCentauri said: I'd like the aspect ratio given in the media info of a file to reflect the actual aspect ratio of the content, rather than the video file itself.... RC, OK, that info has to come from some online database lookup. There is no easy video evaluation test, where are there black bars and what percentage of the media image do these black bars take up? You would have to scan past the titles and look at several places in the video content, make screen shots and run the result through some sort of image analysis, find black bars measure their width and height and run the math on how that changes the aspect ratio of the media. Obviously that is quite intensive, probably not practical and would typically fail to get an accurate percentage often. So, then we are back to pulling from a database, but the film could be released in multiple versions, full frame (4:3), IMAX vs. 2.39 or some other combination. The actual media sold on disc could be multiple possible aspect ratios. Looking up a database will not be 100% accurate. Finally access to such a database like Imdb requires a annual license to pull the advanced info about aspect ratio. Last time I looked it ran more than a couple thousand dollars a year. In this case the payment would only get info that is sometimes correct for the media. It would not adjust for media captured in the wild where the editor did some copy that was non-standard or wrong. This is why pulling the aspect ratio from the media makes sense and trying to give you info on what Aspect Ratio the media should be makes very little sense. If you want to see that, just look it up. Imdb membership is free and you just need to scroll to the bottom of the page. You will find often, there are mulitple Aspect Ratio's for different versions anyway.
RaptorCentauri 59 Posted November 12, 2024 Posted November 12, 2024 1 hour ago, visproduction said: RC, OK, that info has to come from some online database lookup. There is no easy video evaluation test, where are there black bars and what percentage of the media image do these black bars take up? You would have to scan past the titles and look at several places in the video content, make screen shots and run the result through some sort of image analysis, find black bars measure their width and height and run the math on how that changes the aspect ratio of the media. Obviously that is quite intensive, probably not practical and would typically fail to get an accurate percentage often. So, then we are back to pulling from a database, but the film could be released in multiple versions, full frame (4:3), IMAX vs. 2.39 or some other combination. The actual media sold on disc could be multiple possible aspect ratios. Looking up a database will not be 100% accurate. Finally access to such a database like Imdb requires a annual license to pull the advanced info about aspect ratio. Last time I looked it ran more than a couple thousand dollars a year. In this case the payment would only get info that is sometimes correct for the media. It would not adjust for media captured in the wild where the editor did some copy that was non-standard or wrong. This is why pulling the aspect ratio from the media makes sense and trying to give you info on what Aspect Ratio the media should be makes very little sense. If you want to see that, just look it up. Imdb membership is free and you just need to scroll to the bottom of the page. You will find often, there are mulitple Aspect Ratio's for different versions anyway. Tools to detect the AR of the content (not the video file) already exist. They even handle (to some degree) multiple/ changing ARs. However, whether the correct AR comes from a video analysis, scrapping a database, or some other source isn't the point I should have been trying to make. The point is the AR info, wherever it may originally come from, should be a user-settable value. Getting the AR from the media makes sense as a default, but not beyond that.
ebr 16169 Posted November 12, 2024 Posted November 12, 2024 2 hours ago, RaptorCentauri said: The point is the AR info, wherever it may originally come from, should be a user-settable value. Getting the AR from the media makes sense as a default, but not beyond that. We use this information in our video processing so the system needs to know the actual AR of the video. What you are requesting would have to be a separate, display-only piece of metadata because the system cannot rely on it if it is user-editable. BTW - you can crop your items to the proper aspect with most ripping tools.
RaptorCentauri 59 Posted November 12, 2024 Posted November 12, 2024 48 minutes ago, ebr said: We use this information in our video processing so the system needs to know the actual AR of the video. What you are requesting would have to be a separate, display-only piece of metadata because the system cannot rely on it if it is user-editable. BTW - you can crop your items to the proper aspect with most ripping tools. A separate display-only value would be perfectly acceptable. The issue with cropping is that it requires the video to be re-encoded. This means both a loss of quality and time.
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now