<div style="display: flex; flex-wrap: wrap; white-space: pre-wrap; align-items: center; "><img height="20" width="20" style="border-radius:50%; margin-right: 4px;" decoding="async" src="https://avatars.githubusercontent.com/u/34983953?s=20&v=4" /><strong>danielrainer</strong> created an issue <a href="https://github.com/openstreetmap/openstreetmap-website/issues/6240">(openstreetmap/openstreetmap-website#6240)</a></div>
<h3 dir="auto">URL</h3>
<p dir="auto"><em>No response</em></p>
<h3 dir="auto">How to reproduce the issue?</h3>
<p dir="auto">The new vector tile layers (Shortbread, MapTiler OMT) use WebGL. WebGL is not available on all browsers (e.g. disabled for privacy). The code does not seem to be able to handle this and crashes with</p>
<pre lang="text" class="notranslate"><code class="notranslate">Uncaught Error: {"requestedAttributes":{"antialias":false,"preserveDrawingBuffer":false,"powerPreference":"high-performance","failIfMajorPerformanceCaveat":false,"desynchronized":false,"alpha":true,"depth":true,"stencil":true,"premultipliedAlpha":true},"statusMessage":"WebGL is currently disabled.","type":"webglcontextcreationerror","message":"Failed to initialize WebGL"}
</code></pre>
<p dir="auto">This happens as soon as the "Layers" button is clicked, since that tries to render a bit of the map using each style as a preview. The previews of the Shortbread and MapTiler OMT layers just appear gray, and so does the main map if either of them is selected. The main map stays gray even when switching back to a raster layer, which needs a page reload to fix.</p>
<p dir="auto">Tested on Librewolf 140 (with WebGL disabled, the default for this browser).</p>
<h3 dir="auto">Screenshot(s) or anything else?</h3>
<p dir="auto">Shortbread and MapTiler OMT in gray:<br>
<a href="https://github.com/user-attachments/assets/e5f387b8-98e8-4379-a7ce-d3061ac01330">osm_layers_standard.png (view on web)</a></p>
<p dir="auto">Whole map gray if Shortbread is selected:<br>
<a href="https://github.com/user-attachments/assets/f609ae63-98f7-4b58-a496-4877484c89b2">osm_layers_shortbread.png (view on web)</a></p>
<p dir="auto">Map stays gray even when switching back to the Standard layer:<br>
<a href="https://github.com/user-attachments/assets/73c9ee82-abf4-42fd-b5cd-c016a3126599">osm_layers_back_to_standard.png (view on web)</a></p>
<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/issues/6240">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLJNW5N2AYZX5YUQH2D3KDUVHAVCNFSM6AAAAACCJA2QZ6VHI2DSMVQWIX3LMV43ASLTON2WKOZTGI3DAMJRGMYTIMY">unsubscribe</a>.<br />You are receiving this because you are subscribed to this thread.<img src="https://github.com/notifications/beacon/AAK2OLKH2PKEZ4HSI72ZOCT3KDUVHA5CNFSM6AAAAACCJA2QZ6WGG33NNVSW45C7OR4XAZNFJFZXG5LFVJRW63LNMVXHIX3JMTHMEULA64.gif" height="1" width="1" alt="" /><span style="color: transparent; font-size: 0; display: none; visibility: hidden; overflow: hidden; opacity: 0; width: 0; height: 0; max-width: 0; max-height: 0; mso-hide: all">Message ID: <span><openstreetmap/openstreetmap-website/issues/6240</span><span>@</span><span>github</span><span>.</span><span>com></span></span></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/issues/6240",
"url": "https://github.com/openstreetmap/openstreetmap-website/issues/6240",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>