mirror of
https://github.com/GLEGram/GLEGram-iOS.git
synced 2026-05-08 18:45:20 +02:00
4647310322
Based on Swiftgram 12.5 (Telegram iOS 12.5). All GLEGram features ported and organized in GLEGram/ folder. Features: Ghost Mode, Saved Deleted Messages, Content Protection Bypass, Font Replacement, Fake Profile, Chat Export, Plugin System, and more. See CHANGELOG_12.5.md for full details.
27 lines
808 B
Plaintext
27 lines
808 B
Plaintext
#include <LottieCpp/VectorsCocoa.h>
|
|
|
|
#import <QuartzCore/QuartzCore.h>
|
|
|
|
namespace lottie {
|
|
|
|
::CATransform3D nativeTransform(Transform2D const &value) {
|
|
CGAffineTransform at = CGAffineTransformMake(
|
|
value.rows().columns[0][0], value.rows().columns[0][1],
|
|
value.rows().columns[1][0], value.rows().columns[1][1],
|
|
value.rows().columns[2][0], value.rows().columns[2][1]
|
|
);
|
|
return CATransform3DMakeAffineTransform(at);
|
|
}
|
|
|
|
Transform2D fromNativeTransform(::CATransform3D const &value) {
|
|
CGAffineTransform at = CATransform3DGetAffineTransform(value);
|
|
return Transform2D(
|
|
LottieFloat3x3({
|
|
lottieSimdMakeFloat3(at.a, at.b, 0.0),
|
|
lottieSimdMakeFloat3(at.c, at.d, 0.0),
|
|
lottieSimdMakeFloat3(at.tx, at.ty, 1.0)
|
|
})
|
|
);
|
|
}
|
|
|
|
} |