mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-20 00:51:42 +00:00
Fix mac builds. (#88)
Warnings for unused functions, and the same skips as Windows.
This commit is contained in:
committed by
Peter Johnson
parent
55111ac35f
commit
7ef56de3f2
@@ -177,6 +177,7 @@ static inline bool CheckStatus(JNIEnv *env, CS_Status status) {
|
||||
return status == CS_OK;
|
||||
}
|
||||
|
||||
#ifdef __linux__
|
||||
static jobject MakeJObject(JNIEnv *env, const cs::UsbCameraInfo &info) {
|
||||
static jmethodID constructor = env->GetMethodID(
|
||||
usbCameraInfoCls, "<init>", "(ILjava/lang/String;Ljava/lang/String;)V");
|
||||
@@ -185,6 +186,7 @@ static jobject MakeJObject(JNIEnv *env, const cs::UsbCameraInfo &info) {
|
||||
return env->NewObject(usbCameraInfoCls, constructor,
|
||||
static_cast<jint>(info.dev), path.obj(), name.obj());
|
||||
}
|
||||
#endif
|
||||
|
||||
static jobject MakeJObject(JNIEnv *env, const cs::VideoMode &videoMode) {
|
||||
static jmethodID constructor =
|
||||
@@ -386,7 +388,7 @@ JNIEXPORT jobjectArray JNICALL Java_edu_wpi_cscore_CameraServerJNI_getEnumProper
|
||||
JNIEXPORT jint JNICALL Java_edu_wpi_cscore_CameraServerJNI_createUsbCameraDev
|
||||
(JNIEnv *env, jclass, jstring name, jint dev)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
#ifndef __linux__
|
||||
unsupportedEx.Throw(env, "USB is not supported yet");
|
||||
return 0;
|
||||
#else
|
||||
@@ -409,7 +411,7 @@ JNIEXPORT jint JNICALL Java_edu_wpi_cscore_CameraServerJNI_createUsbCameraDev
|
||||
JNIEXPORT jint JNICALL Java_edu_wpi_cscore_CameraServerJNI_createUsbCameraPath
|
||||
(JNIEnv *env, jclass, jstring name, jstring path)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
#ifndef __linux__
|
||||
unsupportedEx.Throw(env, "USB is not supported yet");
|
||||
return 0;
|
||||
#else
|
||||
@@ -870,7 +872,7 @@ JNIEXPORT void JNICALL Java_edu_wpi_cscore_CameraServerJNI_setCameraExposureManu
|
||||
JNIEXPORT jstring JNICALL Java_edu_wpi_cscore_CameraServerJNI_getUsbCameraPath
|
||||
(JNIEnv *env, jclass, jint source)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
#ifndef __linux__
|
||||
unsupportedEx.Throw(env, "USB is not supported yet");
|
||||
return 0;
|
||||
#else
|
||||
@@ -1379,7 +1381,7 @@ JNIEXPORT void JNICALL Java_edu_wpi_cscore_CameraServerJNI_removeListener
|
||||
JNIEXPORT jobjectArray JNICALL Java_edu_wpi_cscore_CameraServerJNI_enumerateUsbCameras
|
||||
(JNIEnv *env, jclass)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
#ifndef __linux__
|
||||
unsupportedEx.Throw(env, "USB is not supported yet");
|
||||
return 0;
|
||||
#else
|
||||
|
||||
Reference in New Issue
Block a user