├── gexEdit
├── .gitignore
├── libs
│ ├── gdx.jar
│ ├── gdx-sources.jar
│ ├── bodyeditor-loader.jar
│ ├── tween-engine-api.jar
│ ├── bodyeditor-loader-sources.jar
│ └── tween-engine-api-sources.jar
├── src
│ ├── net
│ │ └── chozabu
│ │ │ └── gexEdit
│ │ │ ├── BodyGroup.java
│ │ │ ├── InputTool.java
│ │ │ ├── Log.java
│ │ │ ├── CamControl.java
│ │ │ ├── DrawingControl.java
│ │ │ ├── BoxAddingControl.java
│ │ │ ├── PaintingControl.java
│ │ │ ├── InputModule.java
│ │ │ ├── LiveResizeControl.java
│ │ │ ├── PhysObject.java
│ │ │ ├── DragControl.java
│ │ │ ├── MyGdxGame.java
│ │ │ ├── SoftBody.java
│ │ │ └── DeformableMesh.java
│ └── MyGdxGame.gwt.xml
├── .project
├── .settings
│ └── org.eclipse.jdt.core.prefs
└── .classpath
├── gexEdit-desktop
├── .gitignore
├── libs
│ ├── gdx-natives.jar
│ ├── gdx-backend-lwjgl.jar
│ ├── gdx-backend-lwjgl-natives.jar
│ └── gdx-backend-lwjgl-sources.jar
├── src
│ └── net
│ │ └── chozabu
│ │ └── gexEdit
│ │ └── Main.java
├── .classpath
├── .settings
│ └── org.eclipse.jdt.core.prefs
├── .project
└── hs_err_pid15299.log
├── gexEdit-android
├── .gitignore
├── assets
│ └── data
│ │ ├── ball.png
│ │ └── libgdx.png
├── libs
│ ├── armeabi
│ │ ├── libgdx.so
│ │ └── libandroidgl20.so
│ ├── armeabi-v7a
│ │ ├── libgdx.so
│ │ └── libandroidgl20.so
│ ├── gdx-backend-android.jar
│ └── gdx-backend-android-sources.jar
├── res
│ ├── drawable-hdpi
│ │ └── ic_launcher.png
│ ├── drawable-ldpi
│ │ └── ic_launcher.png
│ ├── drawable-mdpi
│ │ └── ic_launcher.png
│ ├── values
│ │ └── strings.xml
│ └── layout
│ │ └── main.xml
├── gen
│ └── net
│ │ └── chozabu
│ │ └── gexEdit
│ │ ├── BuildConfig.java
│ │ └── R.java
├── .settings
│ └── org.eclipse.jdt.core.prefs
├── project.properties
├── src
│ └── net
│ │ └── chozabu
│ │ └── gexEdit
│ │ └── MainActivity.java
├── .project
├── AndroidManifest.xml
├── .classpath
└── proguard.cfg
└── gexEdit-html
├── war
├── net.chozabu.gexEdit.GwtDefinition
│ ├── soundmanager2-setup.js
│ ├── clear.cache.gif
│ ├── soundmanager2_debug.swf
│ ├── gwt
│ │ └── chrome
│ │ │ ├── images
│ │ │ ├── corner.png
│ │ │ ├── hborder.png
│ │ │ ├── vborder.png
│ │ │ ├── corner_ie6.png
│ │ │ ├── hborder_ie6.png
│ │ │ ├── vborder_ie6.png
│ │ │ ├── splitPanelThumb.png
│ │ │ └── ie6
│ │ │ │ ├── hborder_blue_shadow.png
│ │ │ │ ├── hborder_gray_shadow.png
│ │ │ │ ├── vborder_blue_shadow.png
│ │ │ │ ├── vborder_gray_shadow.png
│ │ │ │ ├── corner_dialog_topleft.png
│ │ │ │ └── corner_dialog_topright.png
│ │ │ ├── chrome.css
│ │ │ └── chrome_rtl.css
│ ├── soundmanager2_flash9_debug.swf
│ ├── net.chozabu.gexEdit.GwtDefinition.nocache.js
│ └── hosted.html
├── assets
│ ├── data
│ │ ├── ball.png
│ │ └── libgdx.png
│ └── assets.txt
├── WEB-INF
│ ├── lib
│ │ ├── gdx-backend-gwt.jar
│ │ └── gdx-backend-gwt-sources.jar
│ ├── deploy
│ │ └── net.chozabu.gexEdit.GwtDefinition
│ │ │ └── rpcPolicyManifest
│ │ │ └── manifest.txt
│ ├── classes
│ │ └── net
│ │ │ └── chozabu
│ │ │ └── gexEdit
│ │ │ ├── client
│ │ │ └── GwtLauncher.class
│ │ │ └── GwtDefinition.gwt.xml
│ └── web.xml
└── index.html
├── .settings
└── com.google.gwt.eclipse.core.prefs
├── src
└── net
│ └── chozabu
│ └── gexEdit
│ ├── GwtDefinition.gwt.xml
│ └── client
│ └── GwtLauncher.java
├── .classpath
└── .project
/gexEdit/.gitignore:
--------------------------------------------------------------------------------
1 | bin
2 | .metadata
--------------------------------------------------------------------------------
/gexEdit-desktop/.gitignore:
--------------------------------------------------------------------------------
1 | bin
2 | .metadata
--------------------------------------------------------------------------------
/gexEdit-android/.gitignore:
--------------------------------------------------------------------------------
1 | bin
2 | .metadata
3 |
--------------------------------------------------------------------------------
/gexEdit/libs/gdx.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit/libs/gdx.jar
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/soundmanager2-setup.js:
--------------------------------------------------------------------------------
1 | window.SM2_DEFER = true;
--------------------------------------------------------------------------------
/gexEdit/libs/gdx-sources.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit/libs/gdx-sources.jar
--------------------------------------------------------------------------------
/gexEdit/libs/bodyeditor-loader.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit/libs/bodyeditor-loader.jar
--------------------------------------------------------------------------------
/gexEdit/libs/tween-engine-api.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit/libs/tween-engine-api.jar
--------------------------------------------------------------------------------
/gexEdit-android/assets/data/ball.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-android/assets/data/ball.png
--------------------------------------------------------------------------------
/gexEdit-desktop/libs/gdx-natives.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-desktop/libs/gdx-natives.jar
--------------------------------------------------------------------------------
/gexEdit-html/war/assets/data/ball.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/assets/data/ball.png
--------------------------------------------------------------------------------
/gexEdit-android/assets/data/libgdx.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-android/assets/data/libgdx.png
--------------------------------------------------------------------------------
/gexEdit-android/libs/armeabi/libgdx.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-android/libs/armeabi/libgdx.so
--------------------------------------------------------------------------------
/gexEdit-html/war/assets/data/libgdx.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/assets/data/libgdx.png
--------------------------------------------------------------------------------
/gexEdit-android/libs/armeabi-v7a/libgdx.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-android/libs/armeabi-v7a/libgdx.so
--------------------------------------------------------------------------------
/gexEdit-desktop/libs/gdx-backend-lwjgl.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-desktop/libs/gdx-backend-lwjgl.jar
--------------------------------------------------------------------------------
/gexEdit-html/.settings/com.google.gwt.eclipse.core.prefs:
--------------------------------------------------------------------------------
1 | eclipse.preferences.version=1
2 | filesCopiedToWebInfLib=gwt-servlet.jar
3 |
--------------------------------------------------------------------------------
/gexEdit-html/war/assets/assets.txt:
--------------------------------------------------------------------------------
1 | d:
2 | d:data
3 | i:data/wheel.png
4 | i:data/wall.png
5 | i:data/libgdx.png
6 | i:data/ball.png
7 |
--------------------------------------------------------------------------------
/gexEdit/libs/bodyeditor-loader-sources.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit/libs/bodyeditor-loader-sources.jar
--------------------------------------------------------------------------------
/gexEdit/libs/tween-engine-api-sources.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit/libs/tween-engine-api-sources.jar
--------------------------------------------------------------------------------
/gexEdit-android/libs/gdx-backend-android.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-android/libs/gdx-backend-android.jar
--------------------------------------------------------------------------------
/gexEdit-android/libs/armeabi/libandroidgl20.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-android/libs/armeabi/libandroidgl20.so
--------------------------------------------------------------------------------
/gexEdit-android/libs/armeabi-v7a/libandroidgl20.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-android/libs/armeabi-v7a/libandroidgl20.so
--------------------------------------------------------------------------------
/gexEdit-android/res/drawable-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-android/res/drawable-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/gexEdit-android/res/drawable-ldpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-android/res/drawable-ldpi/ic_launcher.png
--------------------------------------------------------------------------------
/gexEdit-android/res/drawable-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-android/res/drawable-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/gexEdit-desktop/libs/gdx-backend-lwjgl-natives.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-desktop/libs/gdx-backend-lwjgl-natives.jar
--------------------------------------------------------------------------------
/gexEdit-desktop/libs/gdx-backend-lwjgl-sources.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-desktop/libs/gdx-backend-lwjgl-sources.jar
--------------------------------------------------------------------------------
/gexEdit-html/war/WEB-INF/lib/gdx-backend-gwt.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/WEB-INF/lib/gdx-backend-gwt.jar
--------------------------------------------------------------------------------
/gexEdit-android/libs/gdx-backend-android-sources.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-android/libs/gdx-backend-android-sources.jar
--------------------------------------------------------------------------------
/gexEdit-android/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | My LibGDX Game
4 |
--------------------------------------------------------------------------------
/gexEdit-html/war/WEB-INF/lib/gdx-backend-gwt-sources.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/WEB-INF/lib/gdx-backend-gwt-sources.jar
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/clear.cache.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/clear.cache.gif
--------------------------------------------------------------------------------
/gexEdit-html/war/WEB-INF/deploy/net.chozabu.gexEdit.GwtDefinition/rpcPolicyManifest/manifest.txt:
--------------------------------------------------------------------------------
1 | # Module net.chozabu.gexEdit.GwtDefinition
2 | # RPC service class, partial path of RPC policy file
3 |
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/soundmanager2_debug.swf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/soundmanager2_debug.swf
--------------------------------------------------------------------------------
/gexEdit/src/net/chozabu/gexEdit/BodyGroup.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit;
2 |
3 | public interface BodyGroup {
4 |
5 | public abstract void draw();//looks more like drawable than bodygroup
6 | }
7 |
--------------------------------------------------------------------------------
/gexEdit-html/war/WEB-INF/classes/net/chozabu/gexEdit/client/GwtLauncher.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/WEB-INF/classes/net/chozabu/gexEdit/client/GwtLauncher.class
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/corner.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/corner.png
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/hborder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/hborder.png
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/vborder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/vborder.png
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/soundmanager2_flash9_debug.swf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/soundmanager2_flash9_debug.swf
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/corner_ie6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/corner_ie6.png
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/hborder_ie6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/hborder_ie6.png
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/vborder_ie6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/vborder_ie6.png
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/splitPanelThumb.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/splitPanelThumb.png
--------------------------------------------------------------------------------
/gexEdit-android/gen/net/chozabu/gexEdit/BuildConfig.java:
--------------------------------------------------------------------------------
1 | /** Automatically generated file. DO NOT MODIFY */
2 | package net.chozabu.gexEdit;
3 |
4 | public final class BuildConfig {
5 | public final static boolean DEBUG = true;
6 | }
--------------------------------------------------------------------------------
/gexEdit-android/.settings/org.eclipse.jdt.core.prefs:
--------------------------------------------------------------------------------
1 | eclipse.preferences.version=1
2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
3 | org.eclipse.jdt.core.compiler.compliance=1.6
4 | org.eclipse.jdt.core.compiler.source=1.6
5 |
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/hborder_blue_shadow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/hborder_blue_shadow.png
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/hborder_gray_shadow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/hborder_gray_shadow.png
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/vborder_blue_shadow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/vborder_blue_shadow.png
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/vborder_gray_shadow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/vborder_gray_shadow.png
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/corner_dialog_topleft.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/corner_dialog_topleft.png
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/corner_dialog_topright.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chozabu/gexEdit/master/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/gwt/chrome/images/ie6/corner_dialog_topright.png
--------------------------------------------------------------------------------
/gexEdit/src/net/chozabu/gexEdit/InputTool.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit;
2 |
3 | import com.badlogic.gdx.InputProcessor;
4 |
5 | public interface InputTool extends InputProcessor {
6 | public abstract void update();
7 |
8 |
9 | }
10 |
--------------------------------------------------------------------------------
/gexEdit-android/res/layout/main.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
--------------------------------------------------------------------------------
/gexEdit/src/MyGdxGame.gwt.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/gexEdit-android/project.properties:
--------------------------------------------------------------------------------
1 | # This file is automatically generated by Android Tools.
2 | # Do not modify this file -- YOUR CHANGES WILL BE ERASED!
3 | #
4 | # This file must be checked in Version Control Systems.
5 | #
6 | # To customize properties used by the Ant build system use,
7 | # "ant.properties", and override values to adapt the script to your
8 | # project structure.
9 |
10 | # Project target.
11 | target=android-15
12 |
--------------------------------------------------------------------------------
/gexEdit/src/net/chozabu/gexEdit/Log.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit;
2 |
3 | public class Log {
4 | /** Get the current line number.
5 | * @return int - Current line number.
6 | */
7 |
8 |
9 | public static void o(String in){
10 | System.out.println(in);//+" "+getLineNumber());
11 | }
12 |
13 | public static int getLineNumber() {
14 | return Thread.currentThread().getStackTrace()[2].getLineNumber();
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/gexEdit/.project:
--------------------------------------------------------------------------------
1 |
2 |
3 | gexEdit
4 |
5 |
6 |
7 |
8 |
9 | org.eclipse.jdt.core.javabuilder
10 |
11 |
12 |
13 |
14 |
15 | org.eclipse.jdt.core.javanature
16 |
17 |
18 |
--------------------------------------------------------------------------------
/gexEdit-html/src/net/chozabu/gexEdit/GwtDefinition.gwt.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/gexEdit-desktop/src/net/chozabu/gexEdit/Main.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit;
2 |
3 | import com.badlogic.gdx.backends.lwjgl.LwjglApplication;
4 | import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration;
5 |
6 | public class Main {
7 | public static void main(String[] args) {
8 | LwjglApplicationConfiguration cfg = new LwjglApplicationConfiguration();
9 | cfg.title = "GexEdit";
10 | cfg.useGL20 = false;
11 | cfg.width = 640;
12 | cfg.height = 480;
13 |
14 | new LwjglApplication(new MyGdxGame(), cfg);
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/gexEdit-html/war/WEB-INF/classes/net/chozabu/gexEdit/GwtDefinition.gwt.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/gexEdit-html/war/WEB-INF/web.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/gexEdit-desktop/.classpath:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/gexEdit-android/src/net/chozabu/gexEdit/MainActivity.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit;
2 |
3 | import android.os.Bundle;
4 |
5 | import com.badlogic.gdx.backends.android.AndroidApplication;
6 | import com.badlogic.gdx.backends.android.AndroidApplicationConfiguration;
7 |
8 | public class MainActivity extends AndroidApplication {
9 | @Override
10 | public void onCreate(Bundle savedInstanceState) {
11 | super.onCreate(savedInstanceState);
12 |
13 | AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration();
14 | cfg.useGL20 = false;
15 |
16 | initialize(new MyGdxGame(), cfg);
17 | }
18 | }
--------------------------------------------------------------------------------
/gexEdit/.settings/org.eclipse.jdt.core.prefs:
--------------------------------------------------------------------------------
1 | eclipse.preferences.version=1
2 | org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
3 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
4 | org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
5 | org.eclipse.jdt.core.compiler.compliance=1.6
6 | org.eclipse.jdt.core.compiler.debug.lineNumber=generate
7 | org.eclipse.jdt.core.compiler.debug.localVariable=generate
8 | org.eclipse.jdt.core.compiler.debug.sourceFile=generate
9 | org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
10 | org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
11 | org.eclipse.jdt.core.compiler.source=1.6
12 |
--------------------------------------------------------------------------------
/gexEdit-desktop/.settings/org.eclipse.jdt.core.prefs:
--------------------------------------------------------------------------------
1 | eclipse.preferences.version=1
2 | org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
3 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
4 | org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
5 | org.eclipse.jdt.core.compiler.compliance=1.6
6 | org.eclipse.jdt.core.compiler.debug.lineNumber=generate
7 | org.eclipse.jdt.core.compiler.debug.localVariable=generate
8 | org.eclipse.jdt.core.compiler.debug.sourceFile=generate
9 | org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
10 | org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
11 | org.eclipse.jdt.core.compiler.source=1.6
12 |
--------------------------------------------------------------------------------
/gexEdit-desktop/.project:
--------------------------------------------------------------------------------
1 |
2 |
3 | gexEdit-desktop
4 |
5 |
6 |
7 |
8 |
9 | org.eclipse.jdt.core.javabuilder
10 |
11 |
12 |
13 |
14 |
15 | org.eclipse.jdt.core.javanature
16 |
17 |
18 |
19 | assets
20 | 2
21 | PARENT-1-PROJECT_LOC/gexEdit-android/assets
22 |
23 |
24 |
25 |
--------------------------------------------------------------------------------
/gexEdit-html/src/net/chozabu/gexEdit/client/GwtLauncher.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit.client;
2 |
3 | import net.chozabu.gexEdit.MyGdxGame;
4 | import com.badlogic.gdx.ApplicationListener;
5 | import com.badlogic.gdx.backends.gwt.GwtApplication;
6 | import com.badlogic.gdx.backends.gwt.GwtApplicationConfiguration;
7 |
8 | public class GwtLauncher extends GwtApplication {
9 | @Override
10 | public GwtApplicationConfiguration getConfig () {
11 | GwtApplicationConfiguration cfg = new GwtApplicationConfiguration(480, 320);
12 | return cfg;
13 | }
14 |
15 | @Override
16 | public ApplicationListener getApplicationListener () {
17 | return new MyGdxGame();
18 | }
19 | }
--------------------------------------------------------------------------------
/gexEdit/.classpath:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/gexEdit-android/gen/net/chozabu/gexEdit/R.java:
--------------------------------------------------------------------------------
1 | /* AUTO-GENERATED FILE. DO NOT MODIFY.
2 | *
3 | * This class was automatically generated by the
4 | * aapt tool from the resource data it found. It
5 | * should not be modified by hand.
6 | */
7 |
8 | package net.chozabu.gexEdit;
9 |
10 | public final class R {
11 | public static final class attr {
12 | }
13 | public static final class drawable {
14 | public static final int ic_launcher=0x7f020000;
15 | }
16 | public static final class layout {
17 | public static final int main=0x7f030000;
18 | }
19 | public static final class string {
20 | public static final int app_name=0x7f040000;
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/gexEdit-html/.classpath:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/gexEdit-html/.project:
--------------------------------------------------------------------------------
1 |
2 |
3 | gexEdit-html
4 |
5 |
6 |
7 |
8 |
9 | org.eclipse.jdt.core.javabuilder
10 |
11 |
12 |
13 |
14 | com.google.gdt.eclipse.core.webAppProjectValidator
15 |
16 |
17 |
18 |
19 | com.google.gwt.eclipse.core.gwtProjectValidator
20 |
21 |
22 |
23 |
24 |
25 | org.eclipse.jdt.core.javanature
26 | com.google.gwt.eclipse.core.gwtNature
27 |
28 |
29 |
--------------------------------------------------------------------------------
/gexEdit-android/.project:
--------------------------------------------------------------------------------
1 |
2 |
3 | gexEdit-android
4 |
5 |
6 |
7 |
8 |
9 | com.android.ide.eclipse.adt.ResourceManagerBuilder
10 |
11 |
12 |
13 |
14 | com.android.ide.eclipse.adt.PreCompilerBuilder
15 |
16 |
17 |
18 |
19 | org.eclipse.jdt.core.javabuilder
20 |
21 |
22 |
23 |
24 | com.android.ide.eclipse.adt.ApkBuilder
25 |
26 |
27 |
28 |
29 |
30 | com.android.ide.eclipse.adt.AndroidNature
31 | org.eclipse.jdt.core.javanature
32 |
33 |
34 |
--------------------------------------------------------------------------------
/gexEdit-android/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
9 |
12 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/gexEdit-android/.classpath:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/gexEdit-html/war/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | gexEdit
5 |
6 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
35 |
36 |
--------------------------------------------------------------------------------
/gexEdit-android/proguard.cfg:
--------------------------------------------------------------------------------
1 | -optimizationpasses 5
2 | -dontusemixedcaseclassnames
3 | -dontskipnonpubliclibraryclasses
4 | -dontpreverify
5 | -verbose
6 | -optimizations !code/simplification/arithmetic,!field/*,!class/merging/*
7 |
8 | -keep public class * extends android.app.Activity
9 | -keep public class * extends android.app.Application
10 | -keep public class * extends android.app.Service
11 | -keep public class * extends android.content.BroadcastReceiver
12 | -keep public class * extends android.content.ContentProvider
13 | -keep public class * extends android.app.backup.BackupAgentHelper
14 | -keep public class * extends android.preference.Preference
15 | -keep public class com.android.vending.licensing.ILicensingService
16 |
17 | -keepclasseswithmembernames class * {
18 | native ;
19 | }
20 |
21 | -keepclasseswithmembers class * {
22 | public (android.content.Context, android.util.AttributeSet);
23 | }
24 |
25 | -keepclasseswithmembers class * {
26 | public (android.content.Context, android.util.AttributeSet, int);
27 | }
28 |
29 | -keepclassmembers class * extends android.app.Activity {
30 | public void *(android.view.View);
31 | }
32 |
33 | -keepclassmembers enum * {
34 | public static **[] values();
35 | public static ** valueOf(java.lang.String);
36 | }
37 |
38 | -keep class * implements android.os.Parcelable {
39 | public static final android.os.Parcelable$Creator *;
40 | }
41 |
--------------------------------------------------------------------------------
/gexEdit/src/net/chozabu/gexEdit/CamControl.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit;
2 |
3 |
4 | public class CamControl implements InputTool {
5 | public MyGdxGame root;
6 | float lastX, lastY;
7 |
8 | public CamControl (MyGdxGame rootIn){
9 | root=rootIn;
10 | }
11 |
12 | public boolean keyDown(int keycode) {
13 | // TODO Auto-generated method stub
14 | return false;
15 | }
16 |
17 | public boolean keyUp(int keycode) {
18 | // TODO Auto-generated method stub
19 | return false;
20 | }
21 |
22 | public boolean keyTyped(char character) {
23 | // TODO Auto-generated method stub
24 | return false;
25 | }
26 |
27 | public boolean touchDown(int screenX, int screenY, int pointer, int button) {
28 | //float xP =(screenX-root.pixWidth/2)/root.PPM-root.camera.position.x;
29 | //float yP =(-screenY+root.pixHeight/2)/root.PPM-root.camera.position.y;
30 | lastX =(screenX-root.pixWidth/2)/root.PPM*root.camera.zoom;
31 | lastY =(-screenY+root.pixHeight/2)/root.PPM*root.camera.zoom;
32 | // TODO Auto-generated method stub
33 | return false;
34 | }
35 |
36 | public boolean touchUp(int screenX, int screenY, int pointer, int button) {
37 | //float xP =(screenX-root.pixWidth/2)/root.PPM-root.camera.position.x;
38 | //float yP =(-screenY+root.pixHeight/2)/root.PPM-root.camera.position.y;
39 | // TODO Auto-generated method stub
40 | return false;
41 | }
42 |
43 | public boolean touchDragged(int screenX, int screenY, int pointer) {
44 | float xP =(screenX-root.pixWidth/2)/root.PPM*root.camera.zoom;
45 | float yP =(-screenY+root.pixHeight/2)/root.PPM*root.camera.zoom;
46 | float nx = xP-lastX;
47 | float ny = yP-lastY;
48 | root.camera.translate(-nx,-ny);
49 | root.camera.update();
50 | lastX=xP;
51 | lastY=yP;
52 | return false;
53 | }
54 |
55 | public boolean mouseMoved(int screenX, int screenY) {
56 | // TODO Auto-generated method stub
57 | return false;
58 | }
59 |
60 | public boolean scrolled(int amount) {
61 | float am = amount*0.1f;
62 | root.camera.zoom += am;
63 | root.camera.update();
64 | return false;
65 | }
66 |
67 | @Override
68 | public void update() {
69 | // TODO Auto-generated method stub
70 |
71 | }
72 |
73 | }
74 |
--------------------------------------------------------------------------------
/gexEdit/src/net/chozabu/gexEdit/DrawingControl.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit;
2 |
3 | import com.badlogic.gdx.math.Vector3;
4 |
5 | public class DrawingControl implements InputTool{
6 | public MyGdxGame root;
7 | //public float PPM;
8 | private SoftBody creationObject;
9 |
10 | float lastX, lastY;
11 | float firstX, firstY;
12 | public DrawingControl (MyGdxGame rootIn){
13 | root=rootIn;
14 | }
15 |
16 | @Override
17 | public void update(){
18 |
19 | }
20 |
21 | @Override
22 | public boolean touchDown(int xI, int yI, int pointer, int button) {
23 | Vector3 testPoint = new Vector3(xI,yI,0);
24 | root.camera.unproject(testPoint);
25 | float xP=testPoint.x;
26 | float yP=testPoint.y;
27 | lastX = xP;
28 | lastY = yP;
29 | firstX = xP;
30 | firstY = yP;
31 | //root.quickAddObj(xP,yP);
32 | creationObject = root.quickNewSoft();
33 | creationObject.queCircle(1, xP, yP);
34 | return false;
35 | }
36 |
37 | @Override
38 | public boolean touchUp(int xI, int yI, int pointer, int button) {
39 | /*Vector3 testPoint = new Vector3(xI,yI,0);
40 | root.camera.unproject(testPoint);
41 | float xP=testPoint.x;
42 | float yP=testPoint.y;*/
43 | if(creationObject != null){
44 | creationObject.createFromDef();
45 | }
46 | return false;
47 | }
48 |
49 | @Override
50 | public boolean touchDragged(int xI, int yI, int pointer) {
51 | Vector3 testPoint = new Vector3(xI,yI,0);
52 | root.camera.unproject(testPoint);
53 | float xP=testPoint.x;
54 | float yP=testPoint.y;
55 | if (creationObject == null) return false;
56 | creationObject.condAddAt(xP,yP);
57 | float xd=xP-firstX;
58 | float yd=yP-firstY;
59 | if (xd*xd+yd*yd<2 && creationObject.physObject.size()>2 ){
60 | creationObject.makeLoop();
61 | creationObject.createFromDef();
62 | creationObject = null;
63 | lastX = xP;
64 | lastY = yP;
65 | }
66 | return false;
67 | }
68 | @Override
69 | public boolean keyDown(int keycode) {
70 | // TODO Auto-generated method stub
71 | return false;
72 | }
73 |
74 | @Override
75 | public boolean keyUp(int keycode) {
76 | // TODO Auto-generated method stub
77 | return false;
78 | }
79 |
80 | @Override
81 | public boolean keyTyped(char character) {
82 | // TODO Auto-generated method stub
83 | return false;
84 | }
85 |
86 | @Override
87 | public boolean mouseMoved(int screenX, int screenY) {
88 | // TODO Auto-generated method stub
89 | return false;
90 | }
91 |
92 | @Override
93 | public boolean scrolled(int amount) {
94 | // TODO Auto-generated method stub
95 | return false;
96 | }
97 |
98 | }
99 |
--------------------------------------------------------------------------------
/gexEdit/src/net/chozabu/gexEdit/BoxAddingControl.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit;
2 |
3 | import com.badlogic.gdx.Input.Keys;
4 | import com.badlogic.gdx.math.Vector3;
5 |
6 | public class BoxAddingControl implements InputTool {
7 | MyGdxGame root;
8 |
9 | public enum Modes {
10 | Circle,Box,TestPoly
11 | };
12 | Modes mode = Modes.Circle;
13 | public BoxAddingControl(MyGdxGame rootIn){
14 | root = rootIn;
15 | }
16 |
17 | @Override
18 | public boolean keyDown(int keycode) {
19 | if (keycode == Keys.NUM_1)
20 | mode = Modes.Circle;
21 | if (keycode == Keys.NUM_2)
22 | mode = Modes.Box;
23 | if (keycode == Keys.NUM_3)
24 | mode = Modes.TestPoly;
25 | return false;
26 | }
27 |
28 | @Override
29 | public boolean keyUp(int keycode) {
30 | // TODO Auto-generated method stub
31 | return false;
32 | }
33 |
34 | @Override
35 | public boolean keyTyped(char character) {
36 | // TODO Auto-generated method stub
37 | return false;
38 | }
39 | PhysObject pObj;
40 | Vector3 touchStart;
41 | @Override
42 | public boolean touchDown(int screenX, int screenY, int pointer, int button) {
43 | Vector3 worldPos = new Vector3(screenX, screenY,0);
44 | root.camera.unproject(worldPos);
45 | touchStart = worldPos.cpy();
46 | pObj = new PhysObject();
47 | if (mode == Modes.Box)
48 | pObj.setDefBox( worldPos.x,worldPos.y,2,2, root.regionBox,root.bType);
49 | else if (mode == Modes.Circle)
50 | pObj.setDefCircle(2, worldPos.x,worldPos.y, root.region,root.bType);
51 | else
52 | pObj.setDefCircle(2, worldPos.x,worldPos.y, root.regionBox,root.bType);
53 | root.physObject.add(pObj);
54 | return false;
55 | }
56 |
57 | @Override
58 | public boolean touchUp(int screenX, int screenY, int pointer, int button) {
59 | pObj.createFromDef(root.getWorld());
60 | return false;
61 | }
62 | float minObjSize = 1;
63 | @Override
64 | public boolean touchDragged(int screenX, int screenY, int pointer) {
65 | Vector3 worldPos = new Vector3(screenX, screenY,0);
66 | root.camera.unproject(worldPos);
67 | Vector3 diff = worldPos.cpy().sub(touchStart);
68 | float dist = diff.len();
69 | if (dist > minObjSize){
70 | pObj.setDefSize(dist);
71 |
72 | pObj.setDefAngle((float)Math.atan2(diff.y, diff.x));
73 | //pObj.setDefAngle((float)Math.atan2(diff.y, diff.x));
74 | }
75 | return false;
76 | }
77 |
78 | @Override
79 | public boolean mouseMoved(int screenX, int screenY) {
80 | // TODO Auto-generated method stub
81 | return false;
82 | }
83 |
84 | @Override
85 | public boolean scrolled(int amount) {
86 | // TODO Auto-generated method stub
87 | return false;
88 | }
89 |
90 | @Override
91 | public void update() {
92 | // TODO Auto-generated method stub
93 |
94 | }
95 |
96 | }
97 |
--------------------------------------------------------------------------------
/gexEdit-desktop/hs_err_pid15299.log:
--------------------------------------------------------------------------------
1 | #
2 | # A fatal error has been detected by the Java Runtime Environment:
3 | #
4 | # SIGBUS (0x7) at pc=0x00007f945292dbd7, pid=15299, tid=140275019187968
5 | #
6 | # JRE version: 6.0_24-b24
7 | # Java VM: OpenJDK 64-Bit Server VM (20.0-b12 mixed mode linux-amd64 compressed oops)
8 | # Derivative: IcedTea6 1.11.5
9 | # Distribution: Ubuntu 12.10, package 6b24-1.11.5-0ubuntu1~12.10.1
10 | # Problematic frame:
11 | # C [ld-linux-x86-64.so.2+0x9bd7] _dl_rtld_di_serinfo+0xca7
12 | #
13 | # If you would like to submit a bug report, please include
14 | # instructions how to reproduce the bug and visit:
15 | # https://bugs.launchpad.net/ubuntu/+source/openjdk-6/
16 | # The crash happened outside the Java Virtual Machine in native code.
17 | # See problematic frame for where to report the bug.
18 | #
19 |
20 | --------------- T H R E A D ---------------
21 |
22 | Current thread (0x00007f944c008000): JavaThread "main" [_thread_in_native, id=15305, stack(0x00007f9452a08000,0x00007f9452b09000)]
23 |
24 | siginfo:si_signo=SIGBUS: si_errno=0, si_code=2 (BUS_ADRERR), si_addr=0x00007f9446733c68
25 |
26 | Registers:
27 | RAX=0x0000000000000209, RBX=0x0000000000000000, RCX=0x0000000000000000, RDX=0x00007f9446733c60
28 | RSP=0x00007f9452b06a80, RBP=0x0000000000000006, RSI=0x00007f944c12e370, RDI=0x00007f944c2e8d30
29 | R8 =0x0000000000000027, R9 =0x00000000ffffffff, R10=0x0000000000000000, R11=0x00007f9452b06c50
30 | R12=0x00007f944c12e218, R13=0x0000000053caff27, R14=0x0000000000000000, R15=0x00000000014f2bfc
31 | RIP=0x00007f945292dbd7, EFLAGS=0x0000000000010206, CSGSFS=0x0000000000000033, ERR=0x0000000000000004
32 | TRAPNO=0x000000000000000e
33 |
34 | Top of Stack: (sp=0x00007f9452b06a80)
35 | 0x00007f9452b06a80: 00007f9452b073b0 00007f94517af848
36 | 0x00007f9452b06a90: 00007f9452b07360 00007f94517af6de
37 | 0x00007f9452b06aa0: 0000000000000001 00007f9452b073b0
38 | 0x00007f9452b06ab0: 00007f9452b06c20 00007f944c005630
39 | 0x00007f9452b06ac0: 00007f944c008be8 00007f944c008c20
40 | 0x00007f9452b06ad0: 0000000000000000 0000000000000000
41 | 0x00007f9452b06ae0: 00007f944c12e370 00007f944c2e8d30
42 | 0x00007f9452b06af0: 00007f9452b073b0 0000000000000000
43 | 0x00007f9452b06b00: 0000000200000000 000000004c008000
44 | 0x00007f9452b06b10: 0000000000000000 00007f944c12e6f8
45 | 0x00007f9452b06b20: 00007f9452b06c90 0000000053caff27
46 | 0x00007f9452b06b30: 0000000000000000 00007f9452b06d40
47 | 0x00007f9452b06b40: 00007f944c12e370 00007f945292e533
48 | 0x00007f9452b06b50: 0000000000000000 0000000000000000
49 | 0x00007f9452b06b60: 00007f9400000002 0000000000000000
50 | 0x00007f9452b06b70: 0000000700000000 00007f944c12e370
51 | 0x00007f9452b06b80: 00007f9452b07570 0000000000000000
52 | 0x00007f9452b06b90: 00007f944c0081d0 00007f9418064c90
53 | 0x00007f9452b06ba0: 0000000000000416 0000000000000000
54 | 0x00007f9452b06bb0: 0000000000000000 00007f944c12e6f8
55 | 0x00007f9452b06bc0: 000000004c008f30 00007f9451815959
56 | 0x00007f9452b06bd0: 00007f944c008f30 00007f944c2e8d30
57 | 0x00007f9452b06be0: 00007f9452b06f50 00007f9451824f99
58 | 0x00007f9452b06bf0: 0000000000000000 0000000000000000
59 | 0x00007f9452b06c00: 0000000000000001 0000000000000000
60 | 0x00007f9452b06c10: 00007f9418064e60 00007f944c005630
61 | 0x00007f9452b06c20: 0000000000000000 0000000000000000
62 | 0x00007f9452b06c30: 00007f9418064e50 0000000000000001
63 | 0x00007f9452b06c40: 00007f944c004c50 00007f9418064c80
64 | 0x00007f9452b06c50: 00000000ffffffff 0000000000000000
65 | 0x00007f9452b06c60: 00007f9452b06c80 00000000015b75f0
66 | 0x00007f9452b06c70: 00007f944c12e370 00007f9452b46bc0
67 |
68 | Instructions: (pc=0x00007f945292dbd7)
69 | 0x00007f945292dbb7: 00 f6 05 01 90 21 00 08 0f 85 4e 05 00 00 8b 86
70 | 0x00007f945292dbc7: ec 02 00 00 85 c0 0f 84 bd 00 00 00 48 8b 56 70
71 | 0x00007f945292dbd7: 48 8b 52 08 48 89 54 24 28 48 8b 56 68 48 8b 52
72 | 0x00007f945292dbe7: 08 48 89 54 24 70 48 8b 96 f8 02 00 00 48 85 d2
73 |
74 | Register to memory mapping:
75 |
76 | RAX=0x0000000000000209 is an unknown value
77 | RBX=0x0000000000000000 is an unknown value
78 | RCX=0x0000000000000000 is an unknown value
79 | RDX=
--------------------------------------------------------------------------------
/gexEdit/src/net/chozabu/gexEdit/PaintingControl.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit;
2 |
3 | import java.util.ArrayList;
4 | import java.util.List;
5 |
6 | import com.badlogic.gdx.graphics.g2d.Sprite;
7 | import com.badlogic.gdx.graphics.g2d.TextureRegion;
8 | import com.badlogic.gdx.math.Vector2;
9 | import com.badlogic.gdx.math.MathUtils;
10 | import com.badlogic.gdx.math.Vector3;
11 |
12 | public class PaintingControl implements InputTool{
13 |
14 | public MyGdxGame root;
15 | public DeformableMesh deformableMesh;
16 | //public float PPM;
17 | //private SoftBody creationObject;
18 |
19 |
20 | private Sprite sprite;
21 |
22 | public void setupSprite(float w,float h, TextureRegion region){ //sprite = pSprite;
23 | }
24 |
25 | public PaintingControl (MyGdxGame rootIn){
26 | root=rootIn;
27 | deformableMesh = new DeformableMesh();
28 | setupSprite(0.4f, 0.4f, root.region);
29 | }
30 |
31 | public List tcAT(float x, float y){
32 | List testCircle = new ArrayList();
33 | float sAngle = 0;//MathUtils.random()*MathUtils.PI*2;
34 | float radius = 2f;//1.f+MathUtils.random();
35 | for(float angle=sAngle;angle2 ){
99 | creationObject.makeLoop();
100 | creationObject.createFromDef();
101 | creationObject = null;
102 | lastX = xP;
103 | lastY = yP;
104 | }*/
105 | return false;
106 | }
107 | @Override
108 | public boolean keyDown(int keycode) {
109 | // TODO Auto-generated method stub
110 | return false;
111 | }
112 |
113 | @Override
114 | public boolean keyUp(int keycode) {
115 | // TODO Auto-generated method stub
116 | return false;
117 | }
118 |
119 | @Override
120 | public boolean keyTyped(char character) {
121 | // TODO Auto-generated method stub
122 | return false;
123 | }
124 |
125 | @Override
126 | public boolean mouseMoved(int screenX, int screenY) {
127 | // TODO Auto-generated method stub
128 | return false;
129 | }
130 |
131 | @Override
132 | public boolean scrolled(int amount) {
133 | // TODO Auto-generated method stub
134 | return false;
135 | }
136 |
137 | }
138 |
--------------------------------------------------------------------------------
/gexEdit/src/net/chozabu/gexEdit/InputModule.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit;
2 |
3 | import java.util.List;
4 |
5 | import com.badlogic.gdx.Input.Keys;
6 | import com.badlogic.gdx.physics.box2d.BodyDef.BodyType;
7 |
8 | public class InputModule implements InputTool {
9 | public MyGdxGame root;
10 | DrawingControl drawingControl;
11 | PaintingControl paintingControl;
12 | CamControl camControl;
13 | BoxAddingControl boxAddingControl;
14 | DragControl dragControl;
15 | LiveResizeControl liveResizeControl;
16 | List tools;
17 | InputTool cTool;
18 |
19 | boolean button1Down = false;
20 |
21 |
22 | public void setInfo (MyGdxGame rootIn){
23 | root=rootIn;
24 | //mode = Modes.Interact;
25 | drawingControl = new DrawingControl(root);
26 | paintingControl = new PaintingControl(root);
27 | camControl = new CamControl(root);
28 | boxAddingControl = new BoxAddingControl(root);
29 | dragControl = new DragControl(root);
30 | liveResizeControl = new LiveResizeControl(root);
31 | //cTool = paintingControl;
32 | cTool = drawingControl;
33 | }
34 |
35 | @Override
36 | public boolean keyDown(int keycode) {
37 |
38 |
39 | if (cTool == boxAddingControl)
40 | boxAddingControl.keyDown(keycode);
41 | if (cTool == dragControl)
42 | dragControl.keyDown(keycode);
43 |
44 | if (keycode == Keys.R){
45 | root.resetAll();
46 | root.frozen = true;
47 | }
48 |
49 | if (keycode == Keys.TAB){
50 | if (root.frozen)
51 | root.frozen = false;
52 | else
53 | root.runStep = !root.runStep;
54 | //root.resetAll();
55 | //root.render();
56 | //root.delPBs();
57 | }
58 |
59 |
60 | if (keycode == Keys.S)
61 | root.bType = BodyType.StaticBody;
62 | if (keycode == Keys.D)
63 | root.bType = BodyType.DynamicBody;
64 |
65 |
66 | //set mode (drawing tool)//TODO make "tool" interface to set currentTool
67 | if (keycode == Keys.Z){
68 | cTool = dragControl;
69 | //mode = Modes.Interact;//running, transform when static?
70 | }
71 | if (keycode == Keys.X){
72 | cTool = paintingControl;
73 | //mode = Modes.Painting;
74 | }
75 | //mode = Modes.Select;
76 | if (keycode == Keys.C){
77 | cTool = camControl;
78 | //mode = Modes.Camera;//either
79 | }
80 | if (keycode == Keys.V){
81 | cTool = drawingControl;
82 | //mode = Modes.Drawing;//static, mostly
83 | }
84 | if (keycode == Keys.B){
85 | cTool = boxAddingControl;
86 | //mode = Modes.Box;//static, mostly
87 | }
88 | if (keycode == Keys.N){
89 | cTool = liveResizeControl;
90 | //mode = Modes.Resize;
91 | }
92 | return false;
93 | }
94 |
95 | @Override
96 | public boolean keyUp(int keycode) {
97 | // TODO Auto-generated method stub
98 | return false;
99 | }
100 |
101 | @Override
102 | public boolean keyTyped(char character) {
103 | // TODO Auto-generated method stub
104 | return false;
105 | }
106 |
107 | @Override
108 | public boolean touchDown(int screenX, int screenY, int pointer, int button) {
109 | if (button == 1){
110 | camControl.touchDown(screenX,screenY,pointer,button);
111 | button1Down = true;
112 | }
113 | else
114 | cTool.touchDown(screenX,screenY,pointer,button);
115 | return false;
116 | }
117 |
118 | @Override
119 | public boolean touchUp(int screenX, int screenY, int pointer, int button) {
120 | if (button == 1){
121 | camControl.touchUp(screenX,screenY,pointer,button);
122 | button1Down = false;
123 | }
124 | else
125 | cTool.touchUp(screenX,screenY,pointer, button);
126 | return false;
127 | }
128 |
129 | @Override
130 | public boolean touchDragged(int screenX, int screenY, int pointer) {
131 | if (button1Down)
132 | camControl.touchDragged(screenX,screenY,pointer);
133 | else
134 | cTool.touchDragged(screenX,screenY,pointer);
135 | return false;
136 | }
137 |
138 | @Override
139 | public boolean mouseMoved(int screenX, int screenY) {
140 | // TODO Auto-generated method stub
141 | return false;
142 | }
143 |
144 | @Override
145 | public boolean scrolled(int amount) {
146 | camControl.scrolled(amount);
147 | return false;
148 | }
149 |
150 | @Override
151 | public void update() {
152 | cTool.update();
153 | }
154 |
155 | }
156 |
--------------------------------------------------------------------------------
/gexEdit/src/net/chozabu/gexEdit/LiveResizeControl.java:
--------------------------------------------------------------------------------
1 | package net.chozabu.gexEdit;
2 |
3 | import com.badlogic.gdx.math.Vector2;
4 | import com.badlogic.gdx.math.Vector3;
5 | import com.badlogic.gdx.physics.box2d.Body;
6 | import com.badlogic.gdx.physics.box2d.BodyDef.BodyType;
7 | import com.badlogic.gdx.physics.box2d.Fixture;
8 | import com.badlogic.gdx.physics.box2d.QueryCallback;
9 |
10 | public class LiveResizeControl implements InputTool {
11 | MyGdxGame root;
12 |
13 | float lastX, lastY;
14 |
15 | /** a hit body **/
16 | protected Body hitBody = null;
17 |
18 | @Override
19 | public void update(){
20 |
21 | }
22 |
23 | public LiveResizeControl(MyGdxGame rootIn){
24 | root = rootIn;
25 | //BodyDef bodyDef = new BodyDef();
26 | //groundBody = root.getWorld().createBody(bodyDef);
27 | }
28 |
29 | @Override
30 | public boolean keyDown(int keycode) {
31 | // TODO Auto-generated method stub
32 | return false;
33 | }
34 |
35 | @Override
36 | public boolean keyUp(int keycode) {
37 | // TODO Auto-generated method stub
38 | return false;
39 | }
40 |
41 | @Override
42 | public boolean keyTyped(char character) {
43 | // TODO Auto-generated method stub
44 | return false;
45 | }
46 | Vector3 testPoint = new Vector3();
47 | QueryCallback callback = new QueryCallback() {
48 | @Override public boolean reportFixture (Fixture fixture) {
49 | // if the hit point is inside the fixture of the body
50 | // we report it
51 | if (fixture.testPoint(testPoint.x, testPoint.y)) {
52 | hitBody = fixture.getBody();
53 | return false;
54 | } else
55 | return true;
56 | }
57 | };
58 | PhysObject resMe;
59 | @Override public boolean touchDown (int x, int y, int pointer, int button) {
60 | // translate the mouse coordinates to world coordinates
61 | root.camera.unproject(testPoint.set(x, y, 0));
62 | // ask the world which bodies are within the given
63 | // bounding box around the mouse pointer
64 | hitBody = null;
65 |
66 | root.getWorld().QueryAABB(callback, testPoint.x - 0.0001f, testPoint.y - 0.0001f, testPoint.x + 0.0001f, testPoint.y + 0.0001f);
67 | System.out.println(hitBody);
68 | //if (hitBody == groundBody) hitBody = null;
69 |
70 | // ignore kinematic bodies, they don't work with the mouse joint
71 | if (hitBody != null && hitBody.getType() == BodyType.KinematicBody) return false;
72 |
73 | // if we hit something we create a new mouse joint
74 | // and attach it to the hit body.
75 | if (hitBody != null) {
76 | /*MouseJointDef def = new MouseJointDef();
77 | def.bodyA = groundBody;
78 | def.bodyB = hitBody;
79 | def.collideConnected = true;
80 | def.target.set(testPoint.x, testPoint.y);
81 | def.maxForce = 1000.0f * hitBody.getMass();
82 |
83 | mouseJoint = (MouseJoint)root.getWorld().createJoint(def);*/
84 | hitBody.setAwake(true);
85 | resMe = (PhysObject)hitBody.getUserData();
86 | }
87 |
88 | return false;
89 | }
90 |
91 | /** another temporary vector **/
92 | Vector2 target = new Vector2();
93 | float minObjSize = 1;
94 | @Override public boolean touchDragged (int x, int y, int pointer) {
95 | if (resMe == null)return false;
96 | // if a mouse joint exists we simply update
97 | // the target of the joint based on the new
98 | // mouse coordinates
99 | /*if (mouseJoint != null) {
100 | root.camera.unproject(testPoint.set(x, y, 0));
101 | mouseJoint.setTarget(target.set(testPoint.x, testPoint.y));
102 | }*/
103 | Vector3 worldPos = new Vector3(x, y,0);
104 | root.camera.unproject(worldPos);
105 | Vector3 diff = worldPos.cpy().sub(testPoint);
106 | float dist = diff.len();
107 | if (dist > minObjSize){
108 | resMe.setLiveSize(dist);
109 | //hitBody.setDefSize(dist);
110 |
111 | //pObj.setDefAngle((float)Math.atan2(diff.y, diff.x));
112 | //pObj.setDefAngle((float)Math.atan2(diff.y, diff.x));
113 | }
114 | return false;
115 | }
116 |
117 | @Override public boolean touchUp (int x, int y, int pointer, int button) {
118 | if(root.frozen)
119 | resMe.defFromScale();
120 |
121 | // if a mouse joint exists we simply destroy it
122 | /*if (mouseJoint != null) {
123 | root.getWorld().destroyJoint(mouseJoint);
124 | mouseJoint = null;
125 | }*/
126 | return false;
127 | }
128 |
129 | @Override
130 | public boolean mouseMoved(int screenX, int screenY) {
131 | // TODO Auto-generated method stub
132 | return false;
133 | }
134 |
135 | @Override
136 | public boolean scrolled(int amount) {
137 | // TODO Auto-generated method stub
138 | return false;
139 | }
140 |
141 | }
142 |
--------------------------------------------------------------------------------
/gexEdit-html/war/net.chozabu.gexEdit.GwtDefinition/net.chozabu.gexEdit.GwtDefinition.nocache.js:
--------------------------------------------------------------------------------
1 | function net_chozabu_gexEdit_GwtDefinition(){var O='',wb='" for "gwt:onLoadErrorFn"',ub='" for "gwt:onPropertyErrorFn"',hb='"><\/script>',Y='#',Rb='.cache.html',$='/',kb='//',Qb=':',ob='::',cc='
325 |
326 | This html file is for Development Mode support.
327 |