本文整理汇总了Java中playn.java.JavaPlatform.Config方法的典型用法代码示例。如果您正苦于以下问题:Java JavaPlatform.Config方法的具体用法?Java JavaPlatform.Config怎么用?Java JavaPlatform.Config使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类playn.java.JavaPlatform
的用法示例。
在下文中一共展示了JavaPlatform.Config方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: main
import playn.java.JavaPlatform; //导入方法依赖的package包/类
public static void main (String[] args)
{
JavaPlatform.Config config = new JavaPlatform.Config();
config.width = 1280;
config.height = 1024;
JavaPlatform.register(config);
JavaPlatform platform = new JavaPlatform(config);
platform.setPropagateEvents(true);
platform.setTitle("Flumpview");
PlayN.setPlatform(platform);
PlayN.run(new FlumpView());
}
示例2: run
import playn.java.JavaPlatform; //导入方法依赖的package包/类
public final void run ()
{
JavaPlatform.Config config = new JavaPlatform.Config();
config.headless = true;
JavaPlatform.register(config);
JavaPlatform platform = new JavaPlatform(config) {
@Override
public void invokeLater (Runnable runnable) {
// Just do it NOW
runnable.run();
}
@Override
public JavaAssets assets () {
return _assets;
}
protected JavaAssets _assets = new FileAssets(this);
};
PlayN.setPlatform(platform);
try {
execute();
} catch (IllegalArgumentException e) {
System.err.println(e.getMessage());
System.exit(-1);
}
}
示例3: main
import playn.java.JavaPlatform; //导入方法依赖的package包/类
public static void main (String[] args) {
JavaPlatform.Config config = new JavaPlatform.Config();
config.width = 1024;
config.height = 768;
JavaPlatform pf = JavaPlatform.register(config);
pf.setTitle("PlayN Performance Tests");
PlayN.run(new PerfTest());
}
示例4: initializePlatform
import playn.java.JavaPlatform; //导入方法依赖的package包/类
@BeforeClass public static void initializePlatform() {
JavaPlatform.Config config = new JavaPlatform.Config();
plat = new JavaPlatform.Headless(config);
}
示例5: makeLWJGLConfig
import playn.java.JavaPlatform; //导入方法依赖的package包/类
private static JavaPlatform.Config makeLWJGLConfig() {
LWJGLPlatform.Config config = new LWJGLPlatform.Config();
config.width = size.width();
config.height = size.height();
return config;
}
示例6: main
import playn.java.JavaPlatform; //导入方法依赖的package包/类
public static void main(String[] args) {
JavaPlatform.Config config = new JavaPlatform.Config();
// use config to customize the Java platform, if needed
JavaPlatform.register(config);
PlayN.run(new TutorialApp());
}