wasm: fix build error when WebGPU is disabled (SW/GL only)

Fixed a build error that occurred when the WebGPU feature was disabled due to a missing feature check condition. The issue affected building with the software and OpenGL only backends.

issue: #3356
This commit is contained in:
Jinny You 2025-03-27 15:28:12 +09:00 committed by Hermet Park
parent 93cb33fb8e
commit 588bcf5264

View file

@ -191,7 +191,9 @@ struct TvgWgEngine : TvgEngineMethod
void resize(Canvas* canvas, int w, int h) override
{
#ifdef THORVG_WG_RASTER_SUPPORT
if (canvas) static_cast<WgCanvas*>(canvas)->target(device, instance, surface, w, h, ColorSpace::ABGR8888S);
#endif
}
};