<h5 dir="auto">Description of the problem</h5>
<p dir="auto">When I set .lights to false on a MeshStandardMaterial the renderer crashes setting up the uniforms for the material.</p>
<p dir="auto">Here is an example taken from the MeshStandardMaterial demo in the three documentation.</p>
<p dir="auto"><a href="https://jsfiddle.net/cleveard/xyu5tav2/" rel="nofollow">https://jsfiddle.net/cleveard/xyu5tav2/</a></p>
<p dir="auto">I am not sure what is happening, but the shader is being created with the lighting chunks, but the uniform values aren't being initialized because material.lights is false.</p>
<h5 dir="auto">Three.js version</h5>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Dev</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> r91</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> r90</li>
</ul>
<h5 dir="auto">Browser</h5>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> All of them</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> Chrome</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Firefox</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Internet Explorer</li>
</ul>
<h5 dir="auto">OS</h5>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> All of them</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Windows</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> macOS</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Linux</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Android</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> iOS</li>
</ul>
<h5 dir="auto">Hardware Requirements (graphics card, VR Device, ...)</h5>
<p dir="auto">As reported in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="277095939" data-permission-text="Title is private" data-url="https://github.com/mrdoob/three.js/issues/12763" data-hovercard-type="pull_request" data-hovercard-url="/mrdoob/three.js/pull/12763/hovercard?comment_id=364320372&amp;comment_type=issue_comment" href="https://github.com/mrdoob/three.js/pull/12763#issuecomment-364320372">#12763 (comment)</a>, we're currently updating the video texture at 60 (or 90 in VR) fps.</p>
<p dir="auto">Ideally we'll only update the texture on the GPU in sync with the video framerate (usually 25-30). Unfortunately the web platform does not provide any API for figuring out the framerate of a video so something like <code class="notranslate">videoTexture.frameRate = 25</code> is needed.</p>
<p dir="auto">It seemed easy enough so I tried to implement this (<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="296523938" data-permission-text="Title is private" data-url="https://github.com/mrdoob/three.js/issues/13304" data-hovercard-type="pull_request" data-hovercard-url="/mrdoob/three.js/pull/13304/hovercard" href="https://github.com/mrdoob/three.js/pull/13304">#13304</a>) but I hit some browser bugs and I had to revert (<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="296555028" data-permission-text="Title is private" data-url="https://github.com/mrdoob/three.js/issues/13305" data-hovercard-type="pull_request" data-hovercard-url="/mrdoob/three.js/pull/13305/hovercard" href="https://github.com/mrdoob/three.js/pull/13305">#13305</a>).</p>
<p dir="auto">It'll be good to investigate this a bit more and report bugs to browsers if needed.</p>