#include <surface.h>
Public Types | |
| using | CallbackHandler = void(uint32_t, void *, SkwasmObject) |
Public Member Functions | |
| Surface () | |
| EMSCRIPTEN_WEBGL_CONTEXT_HANDLE | GetGlContext () |
| void | SetCallbackHandler (CallbackHandler *callback_handler) |
| void | Dispose () |
| uint32_t | SetCanvas (SkwasmObject canvas) |
| void | OnInitialized (uint32_t callback_id) |
| void | ReceiveCanvasOnWorker (SkwasmObject canvas, uint32_t callback_id) |
| uint32_t | SetSize (int width, int height) |
| void | OnResizeComplete (uint32_t callback_id) |
| void | ResizeOnWorker (int width, int height, uint32_t callback_id) |
| uint32_t | RenderPictures (flutter::DisplayList **picture, int count) |
| void | OnRenderComplete (uint32_t callback_id, SkwasmObject image_bitmap) |
| void | RenderPicturesOnWorker (sk_sp< flutter::DisplayList > *picture, int picture_count, uint32_t callback_id, double raster_start) |
| uint32_t | RasterizeImage (flutter::DlImage *image, ImageByteFormat format) |
| void | OnRasterizeComplete (uint32_t callback_id, SkData *data) |
| void | RasterizeImageOnWorker (flutter::DlImage *image, ImageByteFormat format, uint32_t callback_id) |
| uint32_t | TriggerContextLoss () |
| void | OnContextLossTriggered (uint32_t callback_id) |
| void | ReportContextLost (uint32_t callback_id) |
| void | TriggerContextLossOnWorker (uint32_t callback_id) |
| void | OnContextLost () |
| void | SetResourceCacheLimit (int bytes) |
| std::unique_ptr< TextureSourceWrapper > | CreateTextureSourceWrapper (SkwasmObject textureSource) |
| using Skwasm::Surface::CallbackHandler = void(uint32_t, void*, SkwasmObject) |
| Skwasm::Surface::Surface | ( | ) |
Definition at line 64 of file surface.cc.
References Skwasm::GetRasterThread().
| std::unique_ptr< Skwasm::TextureSourceWrapper > Skwasm::Surface::CreateTextureSourceWrapper | ( | SkwasmObject | textureSource | ) |
Definition at line 296 of file surface.cc.
| void Skwasm::Surface::Dispose | ( | ) |
Definition at line 78 of file surface.cc.
References skwasm_destroyContext().
|
inline |
| void Skwasm::Surface::OnContextLossTriggered | ( | uint32_t | callback_id | ) |
Definition at line 265 of file surface.cc.
| void Skwasm::Surface::OnContextLost | ( | ) |
Definition at line 281 of file surface.cc.
References skwasm_reportContextLost().
| void Skwasm::Surface::OnInitialized | ( | uint32_t | callback_id | ) |
Definition at line 93 of file surface.cc.
| void Skwasm::Surface::OnRasterizeComplete | ( | uint32_t | callback_id, |
| SkData * | data | ||
| ) |
Definition at line 225 of file surface.cc.
| void Skwasm::Surface::OnRenderComplete | ( | uint32_t | callback_id, |
| SkwasmObject | image_bitmap | ||
| ) |
Definition at line 187 of file surface.cc.
| void Skwasm::Surface::OnResizeComplete | ( | uint32_t | callback_id | ) |
Definition at line 148 of file surface.cc.
| uint32_t Skwasm::Surface::RasterizeImage | ( | flutter::DlImage * | image, |
| Skwasm::ImageByteFormat | format | ||
| ) |
Definition at line 214 of file surface.cc.
References format, Skwasm::GetRasterThread(), image, and skwasm_dispatchRasterizeImage().
| void Skwasm::Surface::RasterizeImageOnWorker | ( | flutter::DlImage * | image, |
| Skwasm::ImageByteFormat | format, | ||
| uint32_t | callback_id | ||
| ) |
Definition at line 230 of file surface.cc.
References alpha_type, format, image, Skwasm::makeCurrent(), Skwasm::png, Skwasm::rawStraightRgba, and skwasm_postRasterizeResult().
| void Skwasm::Surface::ReceiveCanvasOnWorker | ( | SkwasmObject | canvas, |
| uint32_t | callback_id | ||
| ) |
Definition at line 100 of file surface.cc.
References Skwasm::RenderContext::Make(), Skwasm::makeCurrent(), skwasm_getGlContextForCanvas(), skwasm_isWimp(), and skwasm_reportInitialized().
| uint32_t Skwasm::Surface::RenderPictures | ( | flutter::DisplayList ** | picture, |
| int | count | ||
| ) |
Definition at line 170 of file surface.cc.
References Skwasm::GetRasterThread(), i, and skwasm_dispatchRenderPictures().
| void Skwasm::Surface::RenderPicturesOnWorker | ( | sk_sp< flutter::DisplayList > * | picture, |
| int | picture_count, | ||
| uint32_t | callback_id, | ||
| double | raster_start | ||
| ) |
Definition at line 193 of file surface.cc.
References i, Skwasm::makeCurrent(), skwasm_captureImageBitmap(), and skwasm_resolveAndPostImages().
| void Skwasm::Surface::ReportContextLost | ( | uint32_t | callback_id | ) |
Definition at line 270 of file surface.cc.
| void Skwasm::Surface::ResizeOnWorker | ( | int | width, |
| int | height, | ||
| uint32_t | callback_id | ||
| ) |
Definition at line 153 of file surface.cc.
References height, skwasm_reportResizeComplete(), and width.
| void Skwasm::Surface::SetCallbackHandler | ( | CallbackHandler * | callback_handler | ) |
Definition at line 73 of file surface.cc.
References callback_handler.
| uint32_t Skwasm::Surface::SetCanvas | ( | SkwasmObject | canvas | ) |
Definition at line 86 of file surface.cc.
References Skwasm::GetRasterThread(), and skwasm_dispatchTransferCanvas().
| void Skwasm::Surface::SetResourceCacheLimit | ( | int | bytes | ) |
Definition at line 291 of file surface.cc.
| uint32_t Skwasm::Surface::SetSize | ( | int | width, |
| int | height | ||
| ) |
Definition at line 139 of file surface.cc.
References Skwasm::GetRasterThread(), height, skwasm_dispatchResizeSurface(), and width.
| uint32_t Skwasm::Surface::TriggerContextLoss | ( | ) |
Definition at line 258 of file surface.cc.
References Skwasm::GetRasterThread(), and skwasm_dispatchTriggerContextLoss().
| void Skwasm::Surface::TriggerContextLossOnWorker | ( | uint32_t | callback_id | ) |
Definition at line 275 of file surface.cc.
References Skwasm::makeCurrent(), skwasm_reportContextLossTriggered(), and skwasm_triggerContextLossOnCanvas().