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
Remove unused Inputstream addon functions and increase max props #17620
Conversation
0d45cfa
to
6d116de
Compare
I plan to merge this (hopefully tonight) once Jenkins is happy. |
@@ -2821,6 +2822,22 @@ void CVideoPlayer::HandleMessages() | |||
std::shared_ptr<CInputStreamPVRBase> pvrinputstream = std::static_pointer_cast<CInputStreamPVRBase>(m_pInputStream); | |||
pvrinputstream->Pause(speed == 0); | |||
} | |||
|
|||
// Inform an inputstream addon with a demuxer that an (un)pause has occurred | |||
if (m_pInputStream->IsStreamType(DVDSTREAM_TYPE_ADDON) && speed != m_playSpeed && |
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.
this block is nonsense, same applies to the pvr related code above. videoplayer controls reading from demuxer with SetSpeed. if user pauses player and buffers are not full, player continues to read until buffers are full.
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.
Why is it nonsense? The api docs for pausestream simply state that a pause action has occurred. This happens for inputstreams without a demuxer but not for ones with one.
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.
Ok, in hindsight, I agree 👍 this time can be inferred from the demux.
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.
btw, wherever you see m_pInputStream->IsStreamType, you can safely assume that it is outdated crap and following this path does more harm than any good.
you should really elaborate on this and make sure the root cause is not in your addon (which is very likely) before changing an API |
The only inputstream in kodi that uses this API call is the addon inputstream. All the other ignore it. Is there an issue with supplying a bPaused bool with this? |
The alternative is create a function only in an Inpustream addon to provide this. But the thinking was why not make the current API more useful. |
See it that way, this function is not used anywhere else except for Inputstream. In History it was not immediately possible to find out when this was added. On my part, it can be a good thing to inform an addon about it, especially if the addon also knows the associated time. Since the function already exists on the addon interface, it would be good to extend it so that it is always called (and not only if addon has no demux). |
I will revert the PauseTime changes and replace them with a comment stating that PauseStream is only ever called for an inputstream without it's own demuxer. Thanks for the guidance again @FernetMenta and sorry for the noise. |
Will merge this much smaller PR in the morning ;) (Hopefully) |
I suggest to drop this function from the api. It is outdated and not needed. Inputstream addon started as a clone of pvr and this function was copied though not having been required. |
I will do a follow up PR removing this function later today. I will need to preserve the functionality in the inputstream addon though as it is used there. |
Remove unused Inputstream addon functions and increase max props
Remove unused Inputstream addon functions and increase max props
Remove unused Inputstream addon functions and increase max props
Remove unused Inputstream addon functions and increase max props
Remove unused Inputstream addon functions and increase max props
Remove unused Inputstream addon functions and increase max props
Remove unused Inputstream addon functions and increase max props
Remove unused Inputstream addon functions and increase max props
Remove unused Inputstream addon functions and increase max props
Remove unused Inputstream addon functions and increase max props
Description
Motivation and Context
Not enough properties for inputstream.ffmpegdirect.
How Has This Been Tested?
On inputstream.ffmpegdirect on OSX
Screenshots (if appropriate):
Types of change
Checklist: