fix: pragma once

This commit is contained in:
Marc Rousavy 2023-07-31 11:41:47 +02:00
parent 7c721ccb81
commit 127656b44c

View File

@ -6,8 +6,7 @@
// Copyright © 2022 mrousavy. All rights reserved. // Copyright © 2022 mrousavy. All rights reserved.
// //
#ifndef SkImageHelpers_h #pragma once
#define SkImageHelpers_h
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
#import <AVFoundation/AVFoundation.h> #import <AVFoundation/AVFoundation.h>
@ -22,7 +21,7 @@
class SkImageHelpers { class SkImageHelpers {
public: public:
SkImageHelpers() = delete; SkImageHelpers() = delete;
public: public:
/** /**
Convert a CMSampleBuffer to an SkImage. Format has to be RGB. Convert a CMSampleBuffer to an SkImage. Format has to be RGB.
@ -37,9 +36,7 @@ public:
The return value should be passed as a sourceRect to a canvas->draw...Rect(..) function, destinationRect should stay the same. The return value should be passed as a sourceRect to a canvas->draw...Rect(..) function, destinationRect should stay the same.
*/ */
static SkRect createCenterCropRect(SkRect source, SkRect destination); static SkRect createCenterCropRect(SkRect source, SkRect destination);
private: private:
static SkRect inscribe(SkSize size, SkRect rect); static SkRect inscribe(SkSize size, SkRect rect);
}; };
#endif /* SkImageHelpers_h */