Very little LWJGL 3 port

This commit is contained in:
khanhduytran0 2020-04-10 20:00:14 +07:00
parent 0d04a1ab1b
commit 7d93ae9b8f
12 changed files with 54 additions and 3 deletions

View File

@ -28,6 +28,7 @@ android {
}
dependencies {
compile 'javax.annotation:javax.annotation-api:1.3.2'
compile 'commons-codec:commons-codec:1.14'
compile 'com.wu-man:android-bsf-api:3.1.3'
compile 'com.android.support:support-v4:24.0.0'

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,9 @@
{
"profiles": {
"(Default)": {
"name": "(Default)",
"lastVersionId": "Unknown"
}
},
"selectedProfile": "(Default)"
}

View File

@ -5,6 +5,7 @@ public class CancelException extends RuntimeException
@Override
public CancelException() {
super();
// org.lwjgl.c
}
@Override

View File

@ -388,6 +388,7 @@ public class MainActivity extends Activity implements OnTouchListener, OnClickLi
}
});
// System.loadLibrary("gl04es");
System.loadLibrary("gl04es");
Bitmap awtGraphics = Bitmap.createBitmap(10, 10, Bitmap.Config.ARGB_8888);

View File

@ -16,14 +16,14 @@ public class LauncherProfiles
} else {
mainProfileJson = new MinecraftLauncherProfiles();
}
insertMissing();
// insertMissing();
return mainProfileJson;
} catch (Throwable th) {
throw new RuntimeException(th);
}
}
public static String insert
/*
public static String insert;
private static void insertMissing() {
if (mainProfileJson.authenticationDatabase == null) {
@ -31,4 +31,5 @@ public class LauncherProfiles
mainProfileJson.authenticationDatabase = mad;
}
}
*/
}

View File

@ -0,0 +1,38 @@
/*
* Copyright LWJGL. All rights reserved.
* License terms: https://www.lwjgl.org/license
*/
package org.lwjgl.system;
/**
* Simple index checks.
*
* <p>On Java 9 these checks are replaced with the corresponding {@link java.util.Objects} methods, which perform better.</p>
*/
public final class CheckIntrinsics {
private CheckIntrinsics() {
}
public static int checkIndex(int index, int length) {
if (index < 0 || length <= index) {
throw new IndexOutOfBoundsException();
}
return index;
}
public static int checkFromToIndex(int fromIndex, int toIndex, int length) {
if (fromIndex < 0 || toIndex < fromIndex || length < toIndex) {
throw new IndexOutOfBoundsException();
}
return fromIndex;
}
public static int checkFromIndexSize(int fromIndex, int size, int length) {
if ((length | fromIndex | size) < 0 || length - fromIndex < size) {
throw new IndexOutOfBoundsException();
}
return fromIndex;
}
}