diff options
Diffstat (limited to 'src/compute/skc/surface.c')
-rw-r--r-- | src/compute/skc/surface.c | 54 |
1 files changed, 20 insertions, 34 deletions
diff --git a/src/compute/skc/surface.c b/src/compute/skc/surface.c index 61bfac3ee6..3d96bb65ac 100644 --- a/src/compute/skc/surface.c +++ b/src/compute/skc/surface.c @@ -34,39 +34,18 @@ skc_surface_release(skc_surface_t surface) return SKC_ERR_SUCCESS; } -skc_err -skc_surface_clear(skc_surface_t surface, - float const rgba[4], - uint32_t const rect[4], - void * fb) -{ - surface->clear(surface->impl,rgba,rect,fb); - - return SKC_ERR_SUCCESS; -} - -skc_err -skc_surface_blit(skc_surface_t surface, - uint32_t const rect[4], - int32_t const txty[2]) -{ - surface->blit(surface->impl,rect,txty); - - return SKC_ERR_SUCCESS; -} - // // // skc_err -skc_surface_render(skc_surface_t surface, - uint32_t const clip[4], - skc_styling_t styling, - skc_composition_t composition, - skc_surface_render_pfn_notify notify, - void * data, - void * fb) +skc_surface_render(skc_surface_t surface, + skc_styling_t styling, + skc_composition_t composition, + skc_framebuffer_t fb, + uint32_t const clip[4], + skc_surface_render_notify notify, + void * data) { skc_err err; @@ -74,17 +53,24 @@ skc_surface_render(skc_surface_t surface, if ((err = skc_styling_seal(styling)) != SKC_ERR_SUCCESS) return err; - // seal composition -- force started + // seal composition -- force starts any dependent paths or rasters if ((err = skc_composition_seal(composition)) != SKC_ERR_SUCCESS) return err; // - // FIXME -- at some point, we will want non-overlapping clips to be - // rendered simultaneously. There is plenty of compute for nominal - // size render tasks so it might not make much a performance - // improvement. + // NOTE: there is purposefully no guard against any of the following + // use cases: + // + // - Simultaneous renders to different frambuffers. + // + // - Simultaneous renders with potentially overlapping clips to + // the same framebuffer. + // + // NOTE: we may want to support concurrent rendering of + // non-overlapping clips. This is fairly easy but at this point + // doesn't seem like a common use case. // - surface->render(surface->impl,clip,styling,composition,notify,data,fb); + surface->render(surface->impl,styling,composition,fb,clip,notify,data); return SKC_ERR_SUCCESS; } |