TPESystem/Media/VideoThumbnail: Difference between revisions

Line 18: Line 18:


== Possible Solutions ==
== Possible Solutions ==
<UL>
<LI><b>Use existing APIs or move some implementations to JS</b><br>
For item#1.1~1.2, they could be solved by using a JavaScript module to parse video file and find the time of proper key-frame to seek it. This is under discussion in Bug#971645[https://bugzilla.mozilla.org/show_bug.cgi?id=971645]. <br>
For item#1.3, there seems no existing way to inform gecko not init audio part. <br>
For item#2, createImageBitmap() should be able to reduce the memory usage. <br>
<LI><b>Introduce a new API, mozCreateThumbnail(double time, unsigned long width, unsigned long height) </b> <br>
For item#1.1~1.3, with some modifications in MediaDecoderReader and MediaDecoderStateMachine in gecko could fix those problems. Application can also use the javascript parser module to find a proper time and set it via "time" parameter, or let gecko find a proper frame. <br>
For item#2, memory usage could be reduced in gecko implementations by setting "width" and "height".  <br>
</UL>
20

edits