Search code examples
actionscript-3apache-flexflex4flash-builder

No video when using spark VideoPlayer AS3


I am using this code but I am getting only audio and no video .. it is an FLV file and working correctly on other players.

<s:VideoPlayer id="vidPl"
                   source="com\gcs\quest\assets\videos\TheUltimateFailsCompilation.flv"
                   skinClass="skins.CustomVideoPlayerSkin"
                   autoPlay="true"
                   muted="false"
                   horizontalCenter="0" verticalCenter="0" />

Solution

  • Black video frame but audio is playing fine:

    You did not say if this is running via browser-based Flash or desktop/mobile Air, so for anything using stage video:

    • HTML: in the object tag, add the parameter <param value='direct' name='mode'>
    • HTML: in the embed tag, add the attribute wmode='direct'
    • AIR: change the render mode: <renderMode>direct</renderMode>

    Ref: https://helpx.adobe.com/flash/kb/flash-object-embed-tag-attributes.html

    Ref: http://help.adobe.com/en_US/air/build/WSfffb011ac560372f2fea1812938a6e463-8000.html