Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
image_encoding_skia.h
Go to the documentation of this file.
1// Copyright 2013 The Flutter Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef FLUTTER_LIB_UI_PAINTING_IMAGE_ENCODING_SKIA_H_
6#define FLUTTER_LIB_UI_PAINTING_IMAGE_ENCODING_SKIA_H_
7
8#include "flutter/common/task_runners.h"
9#include "flutter/display_list/image/dl_image.h"
10#include "flutter/fml/synchronization/sync_switch.h"
11#include "flutter/lib/ui/snapshot_delegate.h"
12
13namespace flutter {
14
16 const sk_sp<DlImage>& dl_image,
17 std::function<void(sk_sp<SkImage>)> encode_task,
18 const fml::RefPtr<fml::TaskRunner>& raster_task_runner,
19 const fml::RefPtr<fml::TaskRunner>& io_task_runner,
20 const fml::WeakPtr<GrDirectContext>& resource_context,
22 const std::shared_ptr<const fml::SyncSwitch>& is_gpu_disabled_sync_switch);
23
24} // namespace flutter
25
26#endif // FLUTTER_LIB_UI_PAINTING_IMAGE_ENCODING_SKIA_H_
void ConvertImageToRasterSkia(const sk_sp< DlImage > &dl_image, std::function< void(sk_sp< SkImage >)> encode_task, const fml::RefPtr< fml::TaskRunner > &raster_task_runner, const fml::RefPtr< fml::TaskRunner > &io_task_runner, const fml::WeakPtr< GrDirectContext > &resource_context, const fml::TaskRunnerAffineWeakPtr< SnapshotDelegate > &snapshot_delegate, const std::shared_ptr< const fml::SyncSwitch > &is_gpu_disabled_sync_switch)