On Fri Jul 30, 2021 at 8:53 PM CEST, Pablo Rodriguez via ntg-context wrote:
Hi Michal and Hans,
many thanks for your patch to fix multimedia objects in PDF and your extremely interesting and in-depth explanation about multimedia in PDF. Many thanks to Hans for the release of an updated latest with also updated documentation.
By the way, Pablo, your issue https://www.mail-archive.com/ntg-context@ntg.nl/msg88204.html was also solved in the last upload. Unfortunately it will probably not help you, because Acrobat no longer supports this. \useexternalsoundtrack [myaudio][audio.mp3] \checksoundtrack{myaudio} \goto{PLAY SOUND}[StartSound{myaudio}] But, you can use renderings instead: \useexternalrendering[myaudiorendering] [audio/mp3][audio.mp3][embed=yes] \definerenderingwindow[audiowindow] [width=0sp, height=0sp] \definelayer[resources] \setupbackgrounds[page][background=resources] \setlayer[resources]{\placerenderingwindow[audiowindow][myaudiorendering]} \goto{PLAY SOUND}[StartRendering{myaudiorendering}] This is basically the example from "/back-swf.mkiv". Works in Acrobat. And one can use either of the three possible file methods (embedded, external, URL), not just external files. The layer is so that the empty frame doesn't interfere with normal page content. No frame is drawn when both dimensions are 0, not sure if that is a behaviour one can take as granted. But currenntly the dimensions can't be zero. Hans, I would omit the check for 0 dimensions of rendering window (as already noted in the source, it is useful for sound). See patch below. Michal Vlasák --- a/tex/context/base/mkxl/lpdf-wid.lmt +++ b/tex/context/base/mkxl/lpdf-wid.lmt @@ -655,9 +655,6 @@ local function insertrenderingwindow(specification) } local width = specification.width or 0 local height = specification.height or 0 - if height == 0 or width == 0 then - -- todo: sound needs no window - end context(nodeinjections.annotation(width,height,0,d(),r)) -- save ref return pdfreference(r) end