// Copyright 2021 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef CC_PAINT_SKOTTIE_MRU_RESOURCE_PROVIDER_H_ #define CC_PAINT_SKOTTIE_MRU_RESOURCE_PROVIDER_H_ #include <string> #include <string_view> #include "base/containers/flat_map.h" #include "base/sequence_checker.h" #include "cc/paint/paint_export.h" #include "cc/paint/skottie_resource_metadata.h" #include "cc/paint/skottie_wrapper.h" #include "third_party/skia/modules/skresources/include/SkResources.h" #include "ui/gfx/geometry/size.h" namespace cc { // Provides Skottie the most recent SkImage that was returned by a // SkottieWrapper::FrameDataCallback for each ImageAsset. Note this is a // "multi-frame" ResourceProvider, so the caller is capable of supporting // animations where the image assets do/don't change between frames. // // Not thread-safe. All public methods must be called from the sequence that // SkottieMRUResourceProvider is constructed on. class CC_PAINT_EXPORT SkottieMRUResourceProvider : public skresources::ResourceProvider { … }; } // namespace cc #endif // CC_PAINT_SKOTTIE_MRU_RESOURCE_PROVIDER_H_