Closed
Bug 1127654
Opened 10 years ago
Closed 10 years ago
Remove monitor from gonk PlatformDeocdeModule
Categories
(Core :: Audio/Video, defect)
Tracking
()
RESOLVED
FIXED
mozilla38
Tracking | Status | |
---|---|---|
firefox38 | --- | fixed |
People
(Reporter: ayang, Assigned: ayang)
Details
Attachments
(1 file, 1 obsolete file)
15.19 KB,
patch
|
ayang
:
review+
|
Details | Diff | Splinter Review |
Follow up bug of from https://bugzilla.mozilla.org/show_bug.cgi?id=1122447#c15.
Assignee | ||
Comment 1•10 years ago
|
||
Attachment #8562560 -
Flags: review?(bwu)
Attachment #8562560 -
Flags: review?(ajones)
Comment 2•10 years ago
|
||
Comment on attachment 8562560 [details] [diff] [review]
remove_monitor
Review of attachment 8562560 [details] [diff] [review]:
-----------------------------------------------------------------
LGTM. Have some nits and questions for you.
::: dom/media/fmp4/gonk/GonkAudioDecoderManager.h
@@ +22,5 @@
>
> class GonkAudioDecoderManager : public GonkDecoderManager {
> typedef android::MediaCodecProxy MediaCodecProxy;
> public:
> + GonkAudioDecoderManager(MediaTaskQueue* aTaskQueue, const mp4_demuxer::AudioDecoderConfig& aConfig);
nit: alignment
::: dom/media/fmp4/gonk/GonkDecoderModule.cpp
@@ +40,5 @@
> MediaDataDecoderCallback* aCallback)
> {
> nsRefPtr<MediaDataDecoder> decoder =
> + new GonkMediaDataDecoder(new GonkVideoDecoderManager(aVideoTaskQueue,
> + aImageContainer,aConfig),
nit: Space after ","
::: dom/media/fmp4/gonk/GonkVideoDecoderManager.cpp
@@ +412,5 @@
> GVDM_LOG("Failed to create video data");
> return NS_ERROR_UNEXPECTED;
> }
> aOutData = data;
> + mDecoder->flush();
Is it required for EOS since it should be used for seek case?
@@ +487,5 @@
> + }
> +
> + GonkVideoDecoderManager* mManager;
> + };
> +
This class is similar to the one GonkDecoderManager's Flush(). Could this to be put in a header file and be used by GonkDecoderManager as well?
::: dom/media/fmp4/gonk/GonkVideoDecoderManager.h
@@ +37,5 @@
> typedef android::MediaCodecProxy MediaCodecProxy;
> typedef mozilla::layers::TextureClient TextureClient;
>
> public:
> + GonkVideoDecoderManager(MediaTaskQueue* aTaskQueue, mozilla::layers::ImageContainer* aImageContainer,
nit: alignment
Attachment #8562560 -
Flags: review?(bwu)
Updated•10 years ago
|
Attachment #8562560 -
Flags: review?(ajones) → review+
Comment 3•10 years ago
|
||
Comment on attachment 8562560 [details] [diff] [review]
remove_monitor
Review of attachment 8562560 [details] [diff] [review]:
-----------------------------------------------------------------
::: dom/media/fmp4/gonk/GonkVideoDecoderManager.cpp
@@ +487,5 @@
> + }
> +
> + GonkVideoDecoderManager* mManager;
> + };
> +
Sorry. I didn't notice these two class name is different.
Assignee | ||
Comment 4•10 years ago
|
||
Comment on attachment 8562560 [details] [diff] [review]
remove_monitor
Review of attachment 8562560 [details] [diff] [review]:
-----------------------------------------------------------------
::: dom/media/fmp4/gonk/GonkVideoDecoderManager.cpp
@@ +412,5 @@
> GVDM_LOG("Failed to create video data");
> return NS_ERROR_UNEXPECTED;
> }
> aOutData = data;
> + mDecoder->flush();
According to MediaCodec document:
"The codec will continue to return output buffers until it eventually signals the end of the output stream by specifying the same flag (BUFFER_FLAG_END_OF_STREAM) on the BufferInfo returned in dequeueOutputBuffer(MediaCodec.BufferInfo, long). Do not submit additional input buffers after signaling the end of the input stream, unless the codec has been flushed, or stopped and restarted."
It needs to send a flush after EOS if the player seeks to another place after EOS. Maybe it should be better to fix at bug 1131467, I'll remove this.
@@ +487,5 @@
> + }
> +
> + GonkVideoDecoderManager* mManager;
> + };
> +
The Run() method in both classes are different, it requirements more complicated logic to put them into one class.
Comment 5•10 years ago
|
||
(In reply to Alfredo Yang from comment #4)
> Comment on attachment 8562560 [details] [diff] [review]
> remove_monitor
>
> Review of attachment 8562560 [details] [diff] [review]:
> -----------------------------------------------------------------
>
> ::: dom/media/fmp4/gonk/GonkVideoDecoderManager.cpp
> @@ +412,5 @@
> > GVDM_LOG("Failed to create video data");
> > return NS_ERROR_UNEXPECTED;
> > }
> > aOutData = data;
> > + mDecoder->flush();
>
> According to MediaCodec document:
>
> "The codec will continue to return output buffers until it eventually
> signals the end of the output stream by specifying the same flag
> (BUFFER_FLAG_END_OF_STREAM) on the BufferInfo returned in
> dequeueOutputBuffer(MediaCodec.BufferInfo, long). Do not submit additional
> input buffers after signaling the end of the input stream, unless the codec
> has been flushed, or stopped and restarted."
>
> It needs to send a flush after EOS if the player seeks to another place
> after EOS. Maybe it should be better to fix at bug 1131467, I'll remove this.
Yeah. flush() would be better to be put in the seek case.
>
> @@ +487,5 @@
> > + }
> > +
> > + GonkVideoDecoderManager* mManager;
> > + };
> > +
>
> The Run() method in both classes are different, it requirements more
> complicated logic to put them into one class.
Understood.
Comment 6•10 years ago
|
||
Attachment #8562560 -
Flags: review+
Assignee | ||
Comment 7•10 years ago
|
||
Attachment #8562560 -
Attachment is obsolete: true
Attachment #8563269 -
Flags: review+
Assignee | ||
Updated•10 years ago
|
Keywords: checkin-needed
Comment 8•10 years ago
|
||
can we get a try run here ? Thanks!
Flags: needinfo?(ayang)
Keywords: checkin-needed
Assignee | ||
Comment 9•10 years ago
|
||
(In reply to Carsten Book [:Tomcat] from comment #8)
> can we get a try run here ? Thanks!
Sure.
https://treeherder.mozilla.org/#/jobs?repo=try&revision=862ca4f5b1db
Waiting the result.
Flags: needinfo?(ayang)
Comment 10•10 years ago
|
||
(In reply to Alfredo Yang from comment #9)
> (In reply to Carsten Book [:Tomcat] from comment #8)
> > can we get a try run here ? Thanks!
>
> Sure.
> https://treeherder.mozilla.org/#/jobs?repo=try&revision=862ca4f5b1db
>
> Waiting the result.
The results look good.
Keywords: checkin-needed
Comment 11•10 years ago
|
||
Keywords: checkin-needed
Comment 12•10 years ago
|
||
Status: NEW → RESOLVED
Closed: 10 years ago
status-firefox38:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla38
You need to log in
before you can comment on or make changes to this bug.
Description
•