Permalink
Show file tree
Hide file tree
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Merge pull request #9728 from JosJuice/android-get-shader-list
Android: Use JNI for getting post-processsing shaders
- Loading branch information
Showing
9 changed files
with
67 additions
and
87 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| package org.dolphinemu.dolphinemu.features.settings.model; | ||
|
|
||
| import androidx.annotation.NonNull; | ||
|
|
||
| public class PostProcessing | ||
| { | ||
| @NonNull | ||
| public static native String[] getShaderList(); | ||
|
|
||
| @NonNull | ||
| public static native String[] getAnaglyphShaderList(); | ||
|
|
||
| @NonNull | ||
| public static native String[] getPassiveShaderList(); | ||
| } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| // Copyright 2021 Dolphin Emulator Project | ||
| // Licensed under GPLv2+ | ||
| // Refer to the license.txt file included. | ||
|
|
||
| #include <string> | ||
| #include <vector> | ||
|
|
||
| #include <jni.h> | ||
|
|
||
| #include "VideoCommon/PostProcessing.cpp" | ||
| #include "jni/AndroidCommon/AndroidCommon.h" | ||
|
|
||
| extern "C" { | ||
|
|
||
| JNIEXPORT jobjectArray JNICALL | ||
| Java_org_dolphinemu_dolphinemu_features_settings_model_PostProcessing_getShaderList(JNIEnv* env, | ||
| jclass) | ||
| { | ||
| return VectorToJStringArray(env, VideoCommon::PostProcessing::GetShaderList()); | ||
| } | ||
|
|
||
| JNIEXPORT jobjectArray JNICALL | ||
| Java_org_dolphinemu_dolphinemu_features_settings_model_PostProcessing_getAnaglyphShaderList( | ||
| JNIEnv* env, jclass) | ||
| { | ||
| return VectorToJStringArray(env, VideoCommon::PostProcessing::GetAnaglyphShaderList()); | ||
| } | ||
|
|
||
| JNIEXPORT jobjectArray JNICALL | ||
| Java_org_dolphinemu_dolphinemu_features_settings_model_PostProcessing_getPassiveShaderList( | ||
| JNIEnv* env, jclass) | ||
| { | ||
| return VectorToJStringArray(env, VideoCommon::PostProcessing::GetPassiveShaderList()); | ||
| } | ||
| } |