Home
last modified time | relevance | path

Searched refs:grContext (Results 1 – 25 of 35) sorted by relevance

12

/ohos5.0/foundation/graphic/graphic_2d/rosen/modules/render_service/core/pipeline/
H A Drs_uni_render_thread.cpp159 auto grContext = renderContext->GetDrGPUContext(); in InitGrContext() local
160 if (!grContext) { in InitGrContext()
807 if (UNLIKELY(!grContext)) { in PostClearMemoryTask()
814 grContext->Flush(); in PostClearMemoryTask()
828 grContext->FlushAndSubmit(true); in PostClearMemoryTask()
830 MemoryManager::VmaDefragment(grContext); in PostClearMemoryTask()
910 if (!grContext) { in PurgeCacheBetweenFrames()
930 auto grContext = renderContext->GetDrGPUContext(); in FlushGpuMemoryInWaitQueueBetweenFrames() local
931 if (!grContext) { in FlushGpuMemoryInWaitQueueBetweenFrames()
934 MemoryManager::FlushGpuMemoryInWaitQueue(grContext); in FlushGpuMemoryInWaitQueueBetweenFrames()
[all …]
H A Drs_ui_capture_task_parallel.cpp169 auto grContext = renderContext != nullptr ? renderContext->GetDrGPUContext() : nullptr; in Run() local
171 RSTagTracker tagTracker(grContext, nodeId_, RSTagTracker::TAGTYPE::TAG_CAPTURE, nodeName); in Run()
216 … RSUniRenderUtil::OptimizedFlushAndSubmit(surface, grContext, !RSSystemProperties::IsPcType()); in Run()
340 auto grContext = RSBackgroundThread::Instance().GetShareGPUContext(); in CreateSurfaceSyncCopyTask() local
341 if (!grContext) { in CreateSurfaceSyncCopyTask()
352 surface = dmaMem.GetSurfaceFromSurfaceBuffer(surfaceBuffer, grContext); in CreateSurfaceSyncCopyTask()
367 tmpImg->BuildFromTexture(*grContext, backendTexture.GetTextureInfo(), in CreateSurfaceSyncCopyTask()
/ohos5.0/foundation/graphic/graphic_2d/rosen/modules/2d_graphics/src/drawing/engine_adapter/skia_adapter/
H A Dskia_surface.cpp113 auto grContext = skiaImageImpl->GetGrContext(); in Bind() local
114 if (skImage == nullptr || grContext == nullptr) { in Bind()
120 skImage = skImage->makeTextureImage(grContext.get()); in Bind()
185 sk_sp<GrDirectContext> grContext = nullptr; in MakeFromBackendRenderTarget() local
189 grContext = skiaGpuContext->GetGrContext(); in MakeFromBackendRenderTarget()
206 SkSurface::MakeFromBackendRenderTarget(grContext.get(), in MakeFromBackendRenderTarget()
223 sk_sp<GrDirectContext> grContext = nullptr; in MakeFromBackendTexture() local
227 grContext = skiaGpuContext->GetGrContext(); in MakeFromBackendTexture()
245 skSurface = SkSurface::MakeFromBackendTexture(grContext.get(), in MakeFromBackendTexture()
272 sk_sp<GrDirectContext> grContext = nullptr; in MakeRenderTarget() local
[all …]
H A Dskia_gpu_context.cpp346 void SkiaGPUContext::SetGrContext(const sk_sp<GrDirectContext>& grContext) in SetGrContext() argument
348 grContext_ = grContext; in SetGrContext()
444 …d(const std::function<void()>& task)> SkiaGPUContext::GetPostFunc(sk_sp<GrDirectContext> grContext) in GetPostFunc() argument
447 if (grContext != nullptr && contextPostMap_.count(uintptr_t(grContext.get())) > 0) { in GetPostFunc()
448 return contextPostMap_[uintptr_t(grContext.get())]; in GetPostFunc()
H A Dskia_runtime_shader_builder.cpp54 std::shared_ptr<Image> SkiaRuntimeShaderBuilder::MakeImage(GPUContext* grContext, const Matrix* loc… in MakeImage() argument
57 if (!skRuntimeShaderBuilder_ || !grContext) { in MakeImage()
61 grContext->GetImpl<SkiaGPUContext>()->GetGrContext().get(), in MakeImage()
H A Dskia_gpu_context.h108 void SetGrContext(const sk_sp<GrDirectContext>& grContext);
115 …d::function<void(const std::function<void()>& task)> GetPostFunc(sk_sp<GrDirectContext> grContext);
H A Dskia_runtime_shader_builder.h45 std::shared_ptr<Image> MakeImage(GPUContext* grContext, const Matrix* localMatrix,
/ohos5.0/foundation/graphic/graphic_2d/rosen/samples/2d_graphics/drawing_engine/
H A Dgles_render_backend.cpp68 sk_sp<GrDirectContext> grContext(GrDirectContext::MakeGL(std::move(glInterface), options)); in SetUpGrContext() local
69 if (grContext == nullptr) { in SetUpGrContext()
74 sk_sp<GrContext> grContext(GrContext::MakeGL(std::move(glInterface), options)); in SetUpGrContext() local
75 if (grContext == nullptr) { in SetUpGrContext()
80 grContext_ = std::move(grContext); in SetUpGrContext()
/ohos5.0/foundation/graphic/graphic_2d/rosen/modules/render_service/core/pipeline/parallel_render/resource/
H A Drs_resource_helper_skia.cpp35 auto grContext = instance.GetShareGrContext().get(); in UploadTextureWithSkia() local
36 if (grContext && image && pixelMap && instance.TaskIsValid(count)) { in UploadTextureWithSkia()
38 SkImage_pinAsTexture(image.get(), grContext); in UploadTextureWithSkia()
H A Drs_resource_helper_drawing.cpp33 auto grContext = instance.GetShareGrContext(); in UploadTextureWithDrawing() local
34 if (grContext && image && pixelMap && instance.TaskIsValid(count)) { in UploadTextureWithDrawing()
/ohos5.0/foundation/graphic/graphic_2d/rosen/modules/render_service/core/memory/
H A Drs_memory_manager.h33 static void DumpDrawingGpuMemory(DfxString& log, const Drawing::GPUContext* grContext,
47 …static void ReleaseUnlockGpuResource(Drawing::GPUContext* grContext, bool scratchResourcesOnly = t…
48 static void ReleaseUnlockAndSafeCacheGpuResource(Drawing::GPUContext* grContext);
68 static void DumpAllGpuInfo(DfxString& log, const Drawing::GPUContext* grContext,
H A Drs_memory_manager.cpp160 void MemoryManager::ReleaseUnlockGpuResource(Drawing::GPUContext* grContext, NodeId surfaceNodeId) in ReleaseUnlockGpuResource() argument
164 ReleaseUnlockGpuResource(grContext, tag); in ReleaseUnlockGpuResource()
168 void MemoryManager::ReleaseUnlockGpuResource(Drawing::GPUContext* grContext, pid_t pid) in ReleaseUnlockGpuResource() argument
172 ReleaseUnlockGpuResource(grContext, tag); // clear gpu resource by pid in ReleaseUnlockGpuResource()
/ohos5.0/foundation/graphic/graphic_2d/rosen/modules/render_service_base/src/offscreen_render/
H A Drs_offscreen_render_thread.cpp110 auto grContext = renderContext_->GetDrGPUContext(); in CleanGrResource() local
111 if (grContext == nullptr) { in CleanGrResource()
115 grContext->FreeGpuResources(); in CleanGrResource()
/ohos5.0/foundation/graphic/graphic_2d/rosen/modules/render_service/core/drawable/
H A Drs_canvas_drawing_render_node_drawable.cpp406 Drawing::Bitmap RSCanvasDrawingRenderNodeDrawable::GetBitmap(Drawing::GPUContext* grContext) in GetBitmap() argument
415 if (!grContext) { in GetBitmap()
423 …bool ret = image->BuildFromTexture(*grContext, backendTexture_.GetTextureInfo(), origin, info, nul… in GetBitmap()
461 std::shared_ptr<Drawing::GPUContext> grContext; in GetPixelmap() local
462 if (!GetCurrentContextAndImage(grContext, image, tid)) { in GetPixelmap()
484 if (grContext == nullptr) { in GetPixelmap()
492 surface = Drawing::Surface::MakeRenderTarget(grContext.get(), false, newInfo); in GetPixelmap()
712 grContext = canvas_->GetGPUContext(); in GetCurrentContextAndImage()
723 grContext = RSSubThreadManager::Instance()->GetGrContextFromSubThread(realTid); in GetCurrentContextAndImage()
726 if (!grContext || !backendTexture_.IsValid()) { in GetCurrentContextAndImage()
[all …]
H A Drs_canvas_drawing_render_node_drawable.h47 Drawing::Bitmap GetBitmap(Drawing::GPUContext* grContext);
84 bool GetCurrentContextAndImage(std::shared_ptr<Drawing::GPUContext>& grContext,
H A Drs_surface_render_node_drawable.h86 RenderContext* renderContext, std::shared_ptr<Drawing::GPUContext> grContext);
119 void InitCacheSurface(Drawing::GPUContext* grContext, ClearCacheSurfaceFunc func = nullptr,
/ohos5.0/foundation/graphic/graphic_2d/rosen/modules/render_service_base/src/render_backend/
H A Ddrawing_context.cpp92 GrDirectContext* grContext = GetDrawingContext(); in AcquireSurfaceInGLES() local
94 GrContext* grContext = GetDrawingContext(); in AcquireSurfaceInGLES()
116 RSTagTracker tagTracker(grContext, RSTagTracker::TAGTYPE::TAG_ACQUIRE_SURFACE); in AcquireSurfaceInGLES()
118 grContext, backendRenderTarget, kBottomLeft_GrSurfaceOrigin, colorType, in AcquireSurfaceInGLES()
/ohos5.0/foundation/graphic/graphic_2d/rosen/modules/create_pixelmap_surface/src/
H A Dpixel_map_from_surface.cpp213 std::unique_ptr<OHOS::Media::PixelMap> CreatePixelMapForGL(sk_sp<GrDirectContext> grContext,
280 sk_sp<GrDirectContext> grContext, const OHOS::Media::Rect &srcRect) in CreatePixelMapForGL() argument
299 auto skSurface = dmaMem.GetSkSurfaceFromSurfaceBuffer(grContext.get(), surfaceBuffer); in CreatePixelMapForGL()
304 if (!DrawImage(grContext.get(), srcRect, skSurface)) { in CreatePixelMapForGL()
328 sk_sp<GrDirectContext> grContext = nullptr; in CreateForGL() local
331 grContext = skiaGpuContext->GetGrContext(); in CreateForGL()
333 if (!grContext) { in CreateForGL()
340 return CreatePixelMapForGL(grContext, srcRect); in CreateForGL()
/ohos5.0/foundation/graphic/graphic_2d/rosen/modules/render_service_base/src/platform/darwin/
H A Drs_surface_darwin.cpp171 auto grContext = std::make_shared<Drawing::GPUContext>(); in SetupGrContext() local
173 if (!grContext->BuildFromGL(options)) { in SetupGrContext()
177 grContext_ = grContext; in SetupGrContext()
/ohos5.0/foundation/graphic/graphic_2d/rosen/modules/render_service_base/src/platform/windows/
H A Drs_surface_windows.cpp173 auto grContext = std::make_shared<Drawing::GPUContext>(); in SetupGrContext() local
175 if (!grContext->BuildFromGL(options)) { in SetupGrContext()
179 grContext_ = grContext; in SetupGrContext()
/ohos5.0/foundation/graphic/graphic_2d/rosen/modules/effect/skia_effectChain/src/
H A Dsk_image_chain.cpp130 sk_sp<GrDirectContext> grContext(GrDirectContext::MakeGL(std::move(glInterface))); in CreateGPUCanvas() local
132 sk_sp<GrContext> grContext(GrContext::MakeGL(std::move(glInterface))); in CreateGPUCanvas() local
134 gpuSurface_ = SkSurface::MakeRenderTarget(grContext.get(), SkBudgeted::kNo, imageInfo_); in CreateGPUCanvas()
/ohos5.0/foundation/graphic/graphic_2d/rosen/test/2d_graphics/unittest/render_context/
H A Drender_context_test.cpp92 bool grContext = renderContext.SetUpGpuContext(); variable
93 EXPECT_EQ(grContext, false);
/ohos5.0/foundation/graphic/graphic_2d/rosen/test/render_service/render_service/unittest/drawable/
H A Drs_canvas_drawing_render_node_drawable_test.cpp368 Drawing::GPUContext* grContext = nullptr; variable
369 drawable->GetBitmap(grContext);
373 drawable->GetBitmap(grContext);
542 std::shared_ptr<Drawing::GPUContext> grContext; variable
549 bool res = drawable->GetCurrentContextAndImage(grContext, image, tid);
553 res = drawable->GetCurrentContextAndImage(grContext, image, tid);
/ohos5.0/foundation/graphic/graphic_2d/rosen/test/render_service/render_service/unittest/pipeline/parallel_render/
H A Drs_sub_thread_test.cpp182 auto grContext = std::make_shared<Drawing::GPUContext>(); variable
183 curThread->grContext_ = grContext;
185 if (grContext) {
/ohos5.0/foundation/graphic/graphic_2d/rosen/test/render_service/render_service/unittest/pipeline/
H A Drs_base_render_engine_test.cpp202 [[maybe_unused]] auto grContext = canvas->GetGPUContext();
203 grContext = nullptr;

12