Flutter Impeller
blit_pass_vk.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 #pragma once
6 
7 #include "flutter/fml/macros.h"
11 
12 namespace impeller {
13 
14 class CommandEncoderVK;
15 class CommandBufferVK;
16 
17 class BlitPassVK final : public BlitPass {
18  public:
19  // |BlitPass|
20  ~BlitPassVK() override;
21 
22  private:
23  friend class CommandBufferVK;
24 
25  std::weak_ptr<CommandBufferVK> command_buffer_;
26  std::vector<std::unique_ptr<BlitEncodeVK>> commands_;
27  std::string label_;
28 
29  BlitPassVK(std::weak_ptr<CommandBufferVK> command_buffer);
30 
31  // |BlitPass|
32  bool IsValid() const override;
33 
34  // |BlitPass|
35  void OnSetLabel(std::string label) override;
36 
37  // |BlitPass|
38  bool EncodeCommands(
39  const std::shared_ptr<Allocator>& transients_allocator) const override;
40 
41  // |BlitPass|
42  bool OnCopyTextureToTextureCommand(std::shared_ptr<Texture> source,
43  std::shared_ptr<Texture> destination,
44  IRect source_region,
45  IPoint destination_origin,
46  std::string label) override;
47 
48  // |BlitPass|
49  bool OnCopyTextureToBufferCommand(std::shared_ptr<Texture> source,
50  std::shared_ptr<DeviceBuffer> destination,
51  IRect source_region,
52  size_t destination_offset,
53  std::string label) override;
54 
55  // |BlitPass|
56  bool OnCopyBufferToTextureCommand(BufferView source,
57  std::shared_ptr<Texture> destination,
58  IPoint destination_origin,
59  std::string label) override;
60  // |BlitPass|
61  bool OnGenerateMipmapCommand(std::shared_ptr<Texture> texture,
62  std::string label) override;
63 
64  FML_DISALLOW_COPY_AND_ASSIGN(BlitPassVK);
65 };
66 
67 } // namespace impeller
impeller::BlitPass
Blit passes encode blit into the underlying command buffer.
Definition: blit_pass.h:27
blit_command_vk.h
blit_pass.h
impeller::BlitPassVK::~BlitPassVK
~BlitPassVK() override
impeller::CommandBufferVK
Definition: command_buffer_vk.h:18
impeller::BufferView
Definition: buffer_view.h:13
impeller::BlitPassVK
Definition: blit_pass_vk.h:17
impeller::TPoint< int64_t >
config.h
impeller
Definition: aiks_context.cc:10
impeller::TRect< int64_t >