當前位置: 首頁>>代碼示例>>Java>>正文


Java GdxTest類代碼示例

本文整理匯總了Java中com.badlogic.gdx.tests.utils.GdxTest的典型用法代碼示例。如果您正苦於以下問題:Java GdxTest類的具體用法?Java GdxTest怎麽用?Java GdxTest使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


GdxTest類屬於com.badlogic.gdx.tests.utils包,在下文中一共展示了GdxTest類的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: main

import com.badlogic.gdx.tests.utils.GdxTest; //導入依賴的package包/類
public static void main (String[] argv) {
		// this is only here for me to debug native code faster
//		new SharedLibraryLoader("../../extensions/gdx-audio/libs/gdx-audio-natives.jar").load("gdx-audio");
//		new SharedLibraryLoader("../../extensions/gdx-image/libs/gdx-image-natives.jar").load("gdx-image");
//		new SharedLibraryLoader("../../extensions/gdx-freetype/libs/gdx-freetype-natives.jar").load("gdx-freetype");
//		new SharedLibraryLoader("../../extensions/gdx-controllers/gdx-controllers-desktop/libs/gdx-controllers-desktop-natives.jar").load("gdx-controllers-desktop");
//		new SharedLibraryLoader("../../gdx/libs/gdx-natives.jar").load("gdx");

		GdxTest test = new JsonReaderTest();		
		LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
		config.r = config.g = config.b = config.a = 8;
//		config.width = 320;
//		config.height = 241;
		config.width = 960;
		config.height = 600;
		new LwjglApplication(test, config);
	}
 
開發者ID:basherone,項目名稱:libgdxcn,代碼行數:18,代碼來源:LwjglDebugStarter.java

示例2: runTest

import com.badlogic.gdx.tests.utils.GdxTest; //導入依賴的package包/類
/**
 * Runs the {@link GdxTest} with the given name.
 * 
 * @param testName the name of a test class
 * @return {@code true} if the test was found and run, {@code false} otherwise
 */
public static boolean runTest (String testName) {
	GdxTest test = GdxTests.newTest(testName);
	if (test == null) {
		return false;
	}
	LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
	config.width = 640;
	config.height = 480;
	config.title = testName;
	config.forceExit = false;
	new LwjglApplication(test, config);
	return true;
}
 
開發者ID:basherone,項目名稱:libgdxcn,代碼行數:20,代碼來源:LwjglTestStarter.java

示例3: onCreate

import com.badlogic.gdx.tests.utils.GdxTest; //導入依賴的package包/類
public void onCreate (Bundle bundle) {
	super.onCreate(bundle);

	// obtain the test info
	Bundle extras = getIntent().getExtras();
	String testName = (String)extras.get("test");
	GdxTest test = GdxTests.newTest(testName);
	
	// and run the application...
	AndroidApplicationConfiguration config = new AndroidApplicationConfiguration();
	config.useImmersiveMode = true;
	initialize(test, config);
}
 
開發者ID:basherone,項目名稱:libgdxcn,代碼行數:14,代碼來源:GdxTestActivity.java

示例4: runTest

import com.badlogic.gdx.tests.utils.GdxTest; //導入依賴的package包/類
/** Runs the {@link GdxTest} with the given name.
 * @param testName the name of a test class
 * @return {@code true} if the test was found and run, {@code false} otherwise */
public static JglfwApplication runTest (String testName) {
	final GdxTest test = GdxTests.newTest(testName);
	if (test == null) throw new GdxRuntimeException("Test not found: " + testName);

	final JglfwApplicationConfiguration config = new JglfwApplicationConfiguration();
	config.width = 640;
	config.height = 480;
	config.title = testName;
	config.forceExit = false;
	return new JglfwApplication(test, config);
}
 
開發者ID:basherone,項目名稱:libgdxcn,代碼行數:15,代碼來源:JglfwTestStarter.java

示例5: main

import com.badlogic.gdx.tests.utils.GdxTest; //導入依賴的package包/類
public static void main (String[] argv) {
	// this is only here for me to debug native code faster
	new SharedLibraryLoader("../../extensions/gdx-audio/libs/gdx-audio-natives.jar").load("gdx-audio");
	new SharedLibraryLoader("../../extensions/gdx-image/libs/gdx-image-natives.jar").load("gdx-image");
	new SharedLibraryLoader("../../extensions/gdx-freetype/libs/gdx-freetype-natives.jar").load("gdx-freetype");
	new SharedLibraryLoader("../../extensions/gdx-controllers/gdx-controllers-desktop/libs/gdx-controllers-desktop-natives.jar")
		.load("gdx-controllers-desktop");
	new SharedLibraryLoader("../../gdx/libs/gdx-natives.jar").load("gdx");

	GdxTest test = new SuperKoalio();
	JglfwApplicationConfiguration config = new JglfwApplicationConfiguration();
	config.vSync = true;
	new JglfwApplication(test, config);
}
 
開發者ID:basherone,項目名稱:libgdxcn,代碼行數:15,代碼來源:JglfwDebugStarter.java

示例6: instance

import com.badlogic.gdx.tests.utils.GdxTest; //導入依賴的package包/類
public GdxTest instance () {
	return new AccelerometerTest();
}
 
開發者ID:basherone,項目名稱:libgdxcn,代碼行數:4,代碼來源:GwtTestWrapper.java


注:本文中的com.badlogic.gdx.tests.utils.GdxTest類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。