text: [{"Owner":"Raghavender Mylagary","Date":"2017-03-16T21:37:45Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\tHi_co_\n_lt_/p_gt_\n\n_lt_p_gt_\n\t         Is it possible to draw video onto the canvas element of the dynamic texture?\n_lt_/p_gt_\n\n_lt_p_gt_\n\tThanks\n_lt_/p_gt_\n\n_lt_p_gt_\n\t- Raghavender Mylagary\n_lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"Deltakosh","Date":"2017-03-16T21:39:18Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\thi!\n_lt_/p_gt_\n\n_lt_p_gt_\n\tyep. You can call context.drawImage and provide the video element as source _lt_img alt_eq__qt__sm_)_qt_ data-emoticon_eq__qt__qt_ height_eq__qt_20_qt_ src_eq__qt_http_dd_//www.html5gamedevs.com/uploads/emoticons/default_wink.png_qt_ srcset_eq__qt_http_dd_//www.html5gamedevs.com/uploads/emoticons/wink@2x.png 2x_qt_ title_eq__qt__sm_)_qt_ width_eq__qt_20_qt_ /_gt__lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"Raghavender Mylagary","Date":"2017-03-16T21:43:17Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\t \n_lt_/p_gt_\n\n_lt_pre_gt_\n_lt_code_gt_&lt_sm_!DOCTYPE html&gt_sm_\n&lt_sm_html&gt_sm_\n    &lt_sm_head&gt_sm_\n        &lt_sm_title&gt_sm_&lt_sm_/title&gt_sm_\n        &lt_sm_script src_eq__qt_scripts/babylon.js_qt_&gt_sm_&lt_sm_/script&gt_sm_\n        &lt_sm_script src_eq__qt_http_dd_//www.babylonjs.com/cannon.js_qt_&gt_sm_&lt_sm_/script&gt_sm_\n        &lt_sm_script src_eq__qt_http_dd_//www.babylonjs.com/oimo.js_qt_&gt_sm_&lt_sm_/script&gt_sm_\n        &lt_sm_style&gt_sm_\n            html_co_ body {\n                overflow_dd_ hidden_sm_\n                width_dd_ 100%_sm_\n                height_dd_ 100%_sm_\n                margin_dd_ 0_sm_\n                padding_dd_ 0_sm_\n            }\n\n            #renderCanvas {\n                width_dd_ 100%_sm_\n                height_dd_ 100%_sm_\n                touch-action_dd_ none_sm_\n            }\n             \n        &lt_sm_/style&gt_sm_\n    &lt_sm_/head&gt_sm_\n    &lt_sm_body&gt_sm_\n        &lt_sm_canvas id_eq__qt_renderCanvas_qt_&gt_sm_&lt_sm_/canvas&gt_sm_\n        &lt_sm_canvas id_eq__qt_c_qt_&gt_sm_&lt_sm_/canvas&gt_sm_\n        &lt_sm_video id_eq__qt_v_qt_ controls&gt_sm_\n            &lt_sm_source src_eq_video.mp4 type_eq_video/mp4&gt_sm_\n        &lt_sm_/video&gt_sm_ \n        &lt_sm_script type_eq__qt_text/javascript_qt_&gt_sm_\n            window.addEventListener(_t_DOMContentLoaded_t__co_ function () {\n                var canvas _eq_ document.getElementById(_qt_renderCanvas_qt_)_sm_\n                var engine _eq_ new BABYLON.Engine(canvas_co_ true)_sm_\n                var scene _eq_ new BABYLON.Scene(engine)_sm_\n                var v _eq_ document.getElementById(_t_v_t_)_sm_\n\n                // Setup environment\n                var light _eq_ new BABYLON.PointLight(_qt_Omni_qt__co_ new BABYLON.Vector3(10_co_ 10_co_ 50)_co_ scene)_sm_\n                var light2 _eq_ new BABYLON.PointLight(_qt_Omni_qt__co_ new BABYLON.Vector3(10_co_ 10_co_ -20)_co_ scene)_sm_\n                var camera _eq_ new BABYLON.ArcRotateCamera(_qt_Camera_qt__co_ -1_co_ 0.8_co_ 100_co_ new BABYLON.Vector3.Zero()_co_ scene)_sm_\n                camera.attachControl(canvas)_sm_\n\n                // Video plane\n                var videoPlane _eq_ BABYLON.Mesh.CreatePlane(_qt_Screen_qt__co_ 50_co_ scene)_sm_\n                videoPlane.position.y _eq_ 10_sm_\n                videoPlane.position.z _eq_ 30_sm_\n\n                // Video material\n                var videoMat _eq_ new BABYLON.StandardMaterial(_qt_textVid_qt__co_ scene)_sm_\n                videoMat.diffuseTexture _eq_ new BABYLON.DynamicTexture(_qt_dynamic texture_qt__co_ 512_co_ scene_co_ true)_sm_\n                videoMat.backFaceCulling _eq_ false_sm_\n                var context _eq_ videoMat.diffuseTexture.getContext()_sm_\n\n                //Applying materials\n                videoPlane.material _eq_ videoMat_sm_\n\n                \n                    context.drawImage(v_co_ 0_co_ 0)_sm_\n                    videoMat.diffuseTexture.update()_sm_\n\n                engine.runRenderLoop(function () {\n                    scene.render()_sm_\n                })_sm_\n\n                window.addEventListener(_t_resize_t__co_ function () {\n                    engine.resize()_sm_\n                })_sm_\n            })_sm_\n        &lt_sm_/script&gt_sm_          \n     &lt_sm_/body&gt_sm_\n&lt_sm_/html&gt_sm_\n_lt_/code_gt__lt_/pre_gt_\n\n_lt_p_gt_\n\t_lt_a data-ipshover_eq__qt__qt_ data-ipshover-target_eq__qt_http_dd_//www.html5gamedevs.com/profile/4442-deltakosh/?do_eq_hovercard_qt_ data-mentionid_eq__qt_4442_qt_ href_eq__qt_http_dd_//www.html5gamedevs.com/profile/4442-deltakosh/_qt_ rel_eq__qt__qt__gt_@Deltakosh_lt_/a_gt_ I tried to implement it but it_t_s not working. Can you please look into the above code? playground link _lt_a href_eq__qt_http_dd_//www.babylonjs-playground.com/#1JQNK1%231_qt_ rel_eq__qt_external nofollow_qt__gt_http_dd_//www.babylonjs-playground.com/#1JQNK1#1_lt_/a_gt_\n_lt_/p_gt_\n\n_lt_p_gt_\n\t \n_lt_/p_gt_\n\n_lt_p_gt_\n\t \n_lt_/p_gt_\n\n_lt_p_gt_\n\t_lt_a class_eq__qt_ipsAttachLink ipsAttachLink_image_qt_ data-fileid_eq__qt_12071_qt_ href_eq__qt_http_dd_//www.html5gamedevs.com/uploads/monthly_2017_03/Canvas.png.d3bb45c7716ed5248824bc6b74626397.png_qt_ rel_eq__qt__qt__gt__lt_img alt_eq__qt_Canvas.png_qt_ class_eq__qt_ipsImage ipsImage_thumbnailed_qt_ data-fileid_eq__qt_12071_qt_ src_eq__qt_http_dd_//www.html5gamedevs.com/uploads/monthly_2017_03/Canvas.thumb.png.96600224cdbaadc0560f09f496660d14.png_qt_ /_gt__lt_/a_gt_\n_lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"Deltakosh","Date":"2017-03-17T16:44:34Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\tHello if you just want to display a video_co_ we provide the video texture object_dd_\n_lt_/p_gt_\n\n_lt_p_gt_\n\t_lt_a href_eq__qt_http_dd_//www.babylonjs-playground.com/#140LZL%238_qt_ rel_eq__qt_external nofollow_qt__gt_http_dd_//www.babylonjs-playground.com/#140LZL#8_lt_/a_gt_\n_lt_/p_gt_\n\n_lt_p_gt_\n\t \n_lt_/p_gt_\n\n_lt_p_gt_\n\tIf you want to update your dynamictexture with a video_dd_\n_lt_/p_gt_\n\n_lt_p_gt_\n\t_lt_a href_eq__qt_http_dd_//www.babylonjs-playground.com/#1JQNK1%233_qt_ rel_eq__qt_external nofollow_qt__gt_http_dd_//www.babylonjs-playground.com/#1JQNK1#3_lt_/a_gt_\n_lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"Raghavender Mylagary","Date":"2017-03-17T20:29:04Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t_lt_p_gt_\n\t_lt_a data-ipshover_eq__qt__qt_ data-ipshover-target_eq__qt_http_dd_//www.html5gamedevs.com/profile/4442-deltakosh/?do_eq_hovercard_qt_ data-mentionid_eq__qt_4442_qt_ href_eq__qt_http_dd_//www.html5gamedevs.com/profile/4442-deltakosh/_qt_ rel_eq__qt__qt__gt_@Deltakosh_lt_/a_gt_ I want to display the video with HTML5 Video controls. I tried with video texture but isn_t_t working so I tried to draw video element with controls onto the dynamic texture canvas. It is also not working_co_ is there any way we can display the video with controls??\n_lt_/p_gt_\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"Deltakosh","Date":"2017-03-20T18:04:46Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\tWhat about asking the good question directly when starting the thread? _lt_img alt_eq__qt__dd_)_qt_ data-emoticon_eq__qt__qt_ height_eq__qt_20_qt_ src_eq__qt_http_dd_//www.html5gamedevs.com/uploads/emoticons/default_smile.png_qt_ srcset_eq__qt_http_dd_//www.html5gamedevs.com/uploads/emoticons/smile@2x.png 2x_qt_ title_eq__qt__dd_)_qt_ width_eq__qt_20_qt_ /_gt__lt_/p_gt_\n\n_lt_p_gt_\n\t \n_lt_/p_gt_\n\n_lt_p_gt_\n\tYou cannot render HTML element inside a texture. But you can use _lt_a href_eq__qt_http_dd_//doc.babylonjs.com/tutorials/picking_collisions_qt_ rel_eq__qt_external nofollow_qt__gt_picking _lt_/a_gt_to simulate click on buttons. In this case you will have to draw your own buttons.\n_lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"}]