<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
The Vivante libraries can map the physical buffers produced by<br>
the VPU directly, so they could do format conversion on their<br>
way to the graphics stack if the Chromium bindings have access<br>
to that (the "single copy" I referred to above).<br></blockquote><div><br></div><div>in my experience "zero-copy" really means zero memcpy() (or similar system call, or really anything that involves the cpu to move around image data. <i>metadata </i>such as buffer pointers is generally allowed). in other words having the GPU do format conversion isn't considered a copy.</div>
<div><br></div><div>here's a great article on this general technique implemented in webkit/gtk+: <a href="http://blogs.igalia.com/vjaquez/2013/07/26/composited-video-support-in-webkitgtk/">http://blogs.igalia.com/vjaquez/2013/07/26/composited-video-support-in-webkitgtk/</a></div>
<div><br></div><div>moving beyond semantics... let me tell you what i know about this particular issue:</div><div><br></div><div>there is source code in chromium to accomplish a similar goal. specifically there is a "generic" android driver, which works out of the box with i.mx6 because freescale implements the standard android video decode interface that allows VPU -> GPU texture uploading (don't quote me on this, i'm just reading the source code: <a style="color:rgb(52,101,164)" href="https://chromium.googlesource.com/chromium/src/+/a361fce28da709ea872062f30fb4b65fcc37b695/content/common/gpu/media/android_video_decode_accelerator.cc">https://chromium.googlesource.com/chromium/src/+/a361fce28da709ea872062f30fb4b65fcc37b695/content/common/gpu/media/android_video_decode_accelerator.cc</a>)<br>
<br>sadly there is no such standard interface on GNU/Linux. outside of android (i.e. chromeos), there are drivers for particular chipsets, like samsung exynos. here is the source for that: <a style="color:rgb(52,101,164)" href="https://chromium.googlesource.com/chromium/src/+/a361fce28da709ea872062f30fb4b65fcc37b695/content/common/gpu/media/exynos_video_decode_accelerator.cc">https://chromium.googlesource.com/chromium/src/+/a361fce28da709ea872062f30fb4b65fcc37b695/content/common/gpu/media/exynos_video_decode_accelerator.cc</a><br>
</div><div><br></div><div>the group should also be aware of the current situation regarding these modules <i>only</i> working when certain flags to enable "chromeos" are used (explained here: <a href="https://code.google.com/p/chromium/wiki/LinuxHWVideoDecode">https://code.google.com/p/chromium/wiki/LinuxHWVideoDecode</a>). in other words: this stuff doesn't work on your x86 with the chrome you download from google.</div>
<div><br></div><div>@carlos: have you implemented a module along the lines of this exynos accelerator or did you take another route? a team member is actually about to attack this problem next week so it'd be great to see what you have before we reinvent your wheel. </div>
<div><br></div></div></div></div>