skia2/tools/Resources.h
Mike Reed 463c848f3b helper to convert CGImage -> SkImage
BUG=skia:

Change-Id: I07e0b8fe510d34ab541de7572cb6775478527624
Reviewed-on: https://skia-review.googlesource.com/6386
Commit-Queue: Mike Reed <reed@google.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
2016-12-21 17:38:18 +00:00

30 lines
745 B
C++

/*
* Copyright 2014 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#ifndef Resources_DEFINED
#define Resources_DEFINED
#include "SkRefCnt.h"
#include "SkString.h"
class SkBitmap;
class SkData;
class SkImage;
class SkStreamAsset;
class SkTypeface;
SkString GetResourcePath(const char* resource = "");
void SetResourcePath(const char* );
bool GetResourceAsBitmap(const char* resource, SkBitmap* dst);
sk_sp<SkImage> GetResourceAsImage(const char* resource);
SkStreamAsset* GetResourceAsStream(const char* resource);
sk_sp<SkData> GetResourceAsData(const char* resource);
sk_sp<SkTypeface> MakeResourceAsTypeface(const char* resource);
#endif // Resources_DEFINED