1 /* 2 * Copyright 2016 Google Inc. 3 * 4 * Use of this source code is governed by a BSD-style license that can be 5 * found in the LICENSE file. 6 */ 7 8 #ifndef SkImageGeneratorWIC_DEFINED 9 #define SkImageGeneratorWIC_DEFINED 10 11 #include "include/private/base/SkFeatures.h" 12 13 #if defined(SK_BUILD_FOR_WIN) 14 15 #include "include/core/SkData.h" 16 #include "include/core/SkImageGenerator.h" 17 #include "include/core/SkRefCnt.h" 18 #include "include/private/base/SkAPI.h" 19 20 #include <memory> 21 22 /* 23 * Any Windows program that uses COM must initialize the COM library by calling 24 * the CoInitializeEx function. In addition, each thread that uses a COM 25 * interface must make a separate call to this function. 26 * 27 * For every successful call to CoInitializeEx, the thread must call 28 * CoUninitialize before it exits. 29 * 30 * SkImageGeneratorWIC requires the COM library and leaves it to the client to 31 * initialize COM for their application. 32 * 33 * For more information on initializing COM, please see: 34 * https://msdn.microsoft.com/en-us/library/windows/desktop/ff485844.aspx 35 */ 36 namespace SkImageGeneratorWIC { 37 SK_API std::unique_ptr<SkImageGenerator> MakeFromEncodedWIC(sk_sp<SkData>); 38 } 39 40 #endif // SK_BUILD_FOR_WIN 41 #endif // SkImageGeneratorWIC_DEFINED 42