// Copyright 2013 The Flutter Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #pragma once #include #include #include #include "flutter/fml/macros.h" #include "flutter/fml/mapping.h" #include "impeller/blobcat/blob_types.h" namespace impeller { class BlobWriter { public: BlobWriter(); ~BlobWriter(); [[nodiscard]] bool AddBlobAtPath(const std::string& path); [[nodiscard]] bool AddBlob(BlobShaderType type, std::string name, std::shared_ptr mapping); std::shared_ptr CreateMapping() const; private: struct BlobDescription { BlobShaderType type; std::string name; std::shared_ptr mapping; }; std::vector blob_descriptions_; FML_DISALLOW_COPY_AND_ASSIGN(BlobWriter); }; } // namespace impeller