-
Notifications
You must be signed in to change notification settings - Fork 37
Expand file tree
/
Copy pathJImage.cpp
More file actions
33 lines (25 loc) · 711 Bytes
/
JImage.cpp
File metadata and controls
33 lines (25 loc) · 711 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
//
// Created by Marc Rousavy on 25.01.24.
//
#include "JImage.h"
#include <fbjni/fbjni.h>
#include <jni.h>
namespace resizeconvert {
using namespace facebook;
using namespace jni;
int JImage::getWidth() const {
auto method = getClass()->getMethod<jint()>("getWidth");
auto result = method(self());
return result;
}
int JImage::getHeight() const {
auto method = getClass()->getMethod<jint()>("getHeight");
auto result = method(self());
return result;
}
jni::local_ref<jni::JArrayClass<JImagePlane>> JImage::getPlanes() const {
auto method = getClass()->getMethod<jni::JArrayClass<JImagePlane>()>("getPlanes");
auto result = method(self());
return result;
}
} // namespace resizeconvert