New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix thumbnails issues #3858
Fix thumbnails issues #3858
Conversation
@theodab can you review? |
Why do we need imageHeight and imageWidth? Isn't height/width and offset x, y enough? |
@joeyparrish , we need the imageHeight and imageWidth because the thumbnail height/width and the offset don't allow us calculate the full image size. Also before the commit 264c842 the getImageTracks returned the full image size. |
I see that it doesn't allow you to compute the full image size, but if you only need to display a single thumbnail, I don't understand why you need the full image size in the first place. I'm not against providing it, but I want to understand the purpose. |
@joeyparrish |
I am seeing that this PR has not fired github action, why? 😮 |
I'm not sure why. We have only very recently deployed a GitHub Actions workflow, so I'm sure we will still be surprised and have more to learn. I'll look into it now. |
I can't find any reason for the PR workflow to be skipped. I also can't find any way to trigger it in a way that is linked to this PR. I was able to trigger it manually to run against your commit, but it isn't linked back to this PR. I'm going to try closing and re-opening the PR to see if that triggers the workflow. |
That seems to have worked. I'm really not sure why it didn't work correctly the first time. I'll double-check our workflow triggers for mistakes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was going to suggest an alternative approach, which involved making Player.getImageTracks
async so that we can create the segment index if necessary.
However, you are right that the segment references are only assigned tilesLayout
values by the HLS parser, at the moment. So changing the interface so that we guaranteed can check the segment references would be future-proofing, at best. Probably not worth the hassle of changing our public interface over.
Given that, I think that your approach here is probably ideal.
@theodab I do not agree to do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, I guess it needs to be:
tilesLayout: layout || null,
Since the stream's tilesLayout is string|undefined
, not ?string
.
Fixed, I used my iPad for the commit instead of turning on the mac ... sorry |
@theodab, sorry for re-requesting your review here. The page was not refreshed, and you had already approved and merged it. Please disregard. |
This has been fixed in Shaka: - shaka-project/shaka-player#3840 - shaka-project/shaka-player#3858
The commit 264c842 introduce 2 issues:
stream.segmentIndex
is not always constructed (eg: DASH)getThumbnails
so that later the UI can correctly place the image if the layout is different to 1x1.