commit
e530fa644b
@ -0,0 +1,29 @@ |
|||||||
|
// |
||||||
|
// This file is to be applied to some subproject. |
||||||
|
// |
||||||
|
|
||||||
|
apply plugin: 'com.jfrog.bintray' |
||||||
|
|
||||||
|
bintray { |
||||||
|
user = bintray_user |
||||||
|
key = bintray_api_key |
||||||
|
configurations = ['archives'] |
||||||
|
dryRun = false |
||||||
|
pkg { |
||||||
|
repo = 'org.jmonkeyengine' |
||||||
|
userOrg = 'jmonkeyengine' |
||||||
|
name = project.name |
||||||
|
desc = POM_DESCRIPTION |
||||||
|
websiteUrl = POM_URL |
||||||
|
licenses = ['BSD New'] |
||||||
|
vcsUrl = POM_SCM_URL |
||||||
|
labels = ['jmonkeyengine'] |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
bintrayUpload.dependsOn(writeFullPom) |
||||||
|
|
||||||
|
bintrayUpload.onlyIf { |
||||||
|
(bintray_api_key.length() > 0) && |
||||||
|
!(version ==~ /.*SNAPSHOT/) |
||||||
|
} |
@ -0,0 +1,97 @@ |
|||||||
|
/* |
||||||
|
* To change this license header, choose License Headers in Project Properties. |
||||||
|
* To change this template file, choose Tools | Templates |
||||||
|
* and open the template in the editor. |
||||||
|
*/ |
||||||
|
package com.jme3.util.mikktspace; |
||||||
|
|
||||||
|
/** |
||||||
|
* |
||||||
|
* @author Nehon |
||||||
|
*/ |
||||||
|
public interface MikkTSpaceContext { |
||||||
|
|
||||||
|
/** |
||||||
|
* Returns the number of faces (triangles/quads) on the mesh to be |
||||||
|
* processed. |
||||||
|
* |
||||||
|
* @return |
||||||
|
*/ |
||||||
|
public int getNumFaces(); |
||||||
|
|
||||||
|
/** |
||||||
|
* Returns the number of vertices on face number iFace iFace is a number in |
||||||
|
* the range {0, 1, ..., getNumFaces()-1} |
||||||
|
* |
||||||
|
* @param face |
||||||
|
* @return |
||||||
|
*/ |
||||||
|
public int getNumVerticesOfFace(int face); |
||||||
|
|
||||||
|
/** |
||||||
|
* returns the position/normal/texcoord of the referenced face of vertex |
||||||
|
* number iVert. iVert is in the range {0,1,2} for triangles and {0,1,2,3} |
||||||
|
* for quads. |
||||||
|
* |
||||||
|
* @param posOut |
||||||
|
* @param face |
||||||
|
* @param vert |
||||||
|
*/ |
||||||
|
public void getPosition(float posOut[], int face, int vert); |
||||||
|
|
||||||
|
public void getNormal(float normOut[], int face, int vert); |
||||||
|
|
||||||
|
public void getTexCoord(float texOut[], int face, int vert); |
||||||
|
|
||||||
|
/** |
||||||
|
* The call-backsetTSpaceBasic() is sufficient for basic normal mapping. |
||||||
|
* This function is used to return the tangent and sign to the application. |
||||||
|
* tangent is a unit length vector. For normal maps it is sufficient to use |
||||||
|
* the following simplified version of the bitangent which is generated at |
||||||
|
* pixel/vertex level. |
||||||
|
* |
||||||
|
* bitangent = fSign * cross(vN, tangent); |
||||||
|
* |
||||||
|
* Note that the results are returned unindexed. It is possible to generate |
||||||
|
* a new index list But averaging/overwriting tangent spaces by using an |
||||||
|
* already existing index list WILL produce INCRORRECT results. DO NOT! use |
||||||
|
* an already existing index list. |
||||||
|
* |
||||||
|
* @param tangent |
||||||
|
* @param sign |
||||||
|
* @param face |
||||||
|
* @param vert |
||||||
|
*/ |
||||||
|
public void setTSpaceBasic(float tangent[], float sign, int face, int vert); |
||||||
|
|
||||||
|
/** |
||||||
|
* This function is used to return tangent space results to the application. |
||||||
|
* tangent and biTangent are unit length vectors and fMagS and fMagT are |
||||||
|
* their true magnitudes which can be used for relief mapping effects. |
||||||
|
* |
||||||
|
* biTangent is the "real" bitangent and thus may not be perpendicular to |
||||||
|
* tangent. However, both are perpendicular to the vertex normal. For normal |
||||||
|
* maps it is sufficient to use the following simplified version of the |
||||||
|
* bitangent which is generated at pixel/vertex level. |
||||||
|
* |
||||||
|
* <pre> |
||||||
|
* fSign = bIsOrientationPreserving ? 1.0f : (-1.0f); |
||||||
|
* bitangent = fSign * cross(vN, tangent); |
||||||
|
* </pre> |
||||||
|
* |
||||||
|
* Note that the results are returned unindexed. It is possible to generate |
||||||
|
* a new index list. But averaging/overwriting tangent spaces by using an |
||||||
|
* already existing index list WILL produce INCRORRECT results. DO NOT! use |
||||||
|
* an already existing index list. |
||||||
|
* |
||||||
|
* @param tangent |
||||||
|
* @param biTangent |
||||||
|
* @param magS |
||||||
|
* @param magT |
||||||
|
* @param isOrientationPreserving |
||||||
|
* @param face |
||||||
|
* @param vert |
||||||
|
*/ |
||||||
|
void setTSpace(float tangent[], float biTangent[], float magS, float magT, |
||||||
|
boolean isOrientationPreserving, int face, int vert); |
||||||
|
} |
@ -0,0 +1,100 @@ |
|||||||
|
/* |
||||||
|
* To change this license header, choose License Headers in Project Properties. |
||||||
|
* To change this template file, choose Tools | Templates |
||||||
|
* and open the template in the editor. |
||||||
|
*/ |
||||||
|
package com.jme3.util.mikktspace; |
||||||
|
|
||||||
|
import com.jme3.scene.Mesh; |
||||||
|
import com.jme3.scene.VertexBuffer; |
||||||
|
import com.jme3.scene.mesh.IndexBuffer; |
||||||
|
import com.jme3.util.BufferUtils; |
||||||
|
import java.nio.FloatBuffer; |
||||||
|
|
||||||
|
/** |
||||||
|
* |
||||||
|
* @author Nehon |
||||||
|
*/ |
||||||
|
public class MikkTSpaceImpl implements MikkTSpaceContext { |
||||||
|
|
||||||
|
Mesh mesh; |
||||||
|
|
||||||
|
public MikkTSpaceImpl(Mesh mesh) { |
||||||
|
this.mesh = mesh; |
||||||
|
VertexBuffer tangentBuffer = mesh.getBuffer(VertexBuffer.Type.Tangent); |
||||||
|
if(tangentBuffer == null){ |
||||||
|
FloatBuffer fb = BufferUtils.createFloatBuffer(mesh.getVertexCount() * 4); |
||||||
|
mesh.setBuffer(VertexBuffer.Type.Tangent, 4, fb); |
||||||
|
} |
||||||
|
|
||||||
|
//TODO ensure the Tangent buffer exists, else create one.
|
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public int getNumFaces() { |
||||||
|
return mesh.getTriangleCount(); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public int getNumVerticesOfFace(int face) { |
||||||
|
return 3; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void getPosition(float[] posOut, int face, int vert) { |
||||||
|
int vertIndex = getIndex(face, vert); |
||||||
|
VertexBuffer position = mesh.getBuffer(VertexBuffer.Type.Position); |
||||||
|
FloatBuffer pos = (FloatBuffer) position.getData(); |
||||||
|
pos.position(vertIndex * 3); |
||||||
|
posOut[0] = pos.get(); |
||||||
|
posOut[1] = pos.get(); |
||||||
|
posOut[2] = pos.get(); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void getNormal(float[] normOut, int face, int vert) { |
||||||
|
int vertIndex = getIndex(face, vert); |
||||||
|
VertexBuffer normal = mesh.getBuffer(VertexBuffer.Type.Normal); |
||||||
|
FloatBuffer norm = (FloatBuffer) normal.getData(); |
||||||
|
norm.position(vertIndex * 3); |
||||||
|
normOut[0] = norm.get(); |
||||||
|
normOut[1] = norm.get(); |
||||||
|
normOut[2] = norm.get(); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void getTexCoord(float[] texOut, int face, int vert) { |
||||||
|
int vertIndex = getIndex(face, vert); |
||||||
|
VertexBuffer texCoord = mesh.getBuffer(VertexBuffer.Type.TexCoord); |
||||||
|
FloatBuffer tex = (FloatBuffer) texCoord.getData(); |
||||||
|
tex.position(vertIndex * 2); |
||||||
|
texOut[0] = tex.get(); |
||||||
|
texOut[1] = tex.get(); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void setTSpaceBasic(float[] tangent, float sign, int face, int vert) { |
||||||
|
int vertIndex = getIndex(face, vert); |
||||||
|
VertexBuffer tangentBuffer = mesh.getBuffer(VertexBuffer.Type.Tangent); |
||||||
|
FloatBuffer tan = (FloatBuffer) tangentBuffer.getData(); |
||||||
|
|
||||||
|
tan.position(vertIndex * 4); |
||||||
|
tan.put(tangent); |
||||||
|
tan.put(sign); |
||||||
|
|
||||||
|
tan.rewind(); |
||||||
|
tangentBuffer.setUpdateNeeded(); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void setTSpace(float[] tangent, float[] biTangent, float magS, float magT, boolean isOrientationPreserving, int face, int vert) { |
||||||
|
//Do nothing
|
||||||
|
} |
||||||
|
|
||||||
|
private int getIndex(int face, int vert) { |
||||||
|
IndexBuffer index = mesh.getIndexBuffer(); |
||||||
|
int vertIndex = index.get(face * 3 + vert); |
||||||
|
return vertIndex; |
||||||
|
} |
||||||
|
|
||||||
|
} |
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,72 @@ |
|||||||
|
package jme3test.app; |
||||||
|
|
||||||
|
import com.jme3.app.SimpleApplication; |
||||||
|
import com.jme3.material.Material; |
||||||
|
import com.jme3.math.ColorRGBA; |
||||||
|
import com.jme3.scene.Geometry; |
||||||
|
import com.jme3.scene.shape.Box; |
||||||
|
|
||||||
|
/** |
||||||
|
* @author john01dav |
||||||
|
*/ |
||||||
|
public class TestEnqueueRunnable extends SimpleApplication{ |
||||||
|
private ExampleAsyncTask exampleAsyncTask; |
||||||
|
|
||||||
|
public static void main(String[] args){ |
||||||
|
new TestEnqueueRunnable().start(); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void simpleInitApp(){ |
||||||
|
Geometry geom = new Geometry("Box", new Box(1, 1, 1)); |
||||||
|
Material material = new Material(getAssetManager(), "/Common/MatDefs/Misc/Unshaded.j3md"); |
||||||
|
material.setColor("Color", ColorRGBA.Blue); //a color is needed to start with
|
||||||
|
geom.setMaterial(material); |
||||||
|
getRootNode().attachChild(geom); |
||||||
|
|
||||||
|
exampleAsyncTask = new ExampleAsyncTask(material); |
||||||
|
exampleAsyncTask.getThread().start(); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void destroy(){ |
||||||
|
exampleAsyncTask.endTask(); |
||||||
|
super.destroy(); |
||||||
|
} |
||||||
|
|
||||||
|
private class ExampleAsyncTask implements Runnable{ |
||||||
|
private final Thread thread; |
||||||
|
private final Material material; |
||||||
|
private volatile boolean running = true; |
||||||
|
|
||||||
|
public ExampleAsyncTask(Material material){ |
||||||
|
this.thread = new Thread(this); |
||||||
|
this.material = material; |
||||||
|
} |
||||||
|
|
||||||
|
public Thread getThread(){ |
||||||
|
return thread; |
||||||
|
} |
||||||
|
|
||||||
|
public void run(){ |
||||||
|
while(running){ |
||||||
|
enqueue(new Runnable(){ //primary usage of this in real applications would use lambda expressions which are unavailable at java 6
|
||||||
|
public void run(){ |
||||||
|
material.setColor("Color", ColorRGBA.randomColor()); |
||||||
|
} |
||||||
|
}); |
||||||
|
|
||||||
|
try{ |
||||||
|
Thread.sleep(1000); |
||||||
|
}catch(InterruptedException e){} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public void endTask(){ |
||||||
|
running = false; |
||||||
|
thread.interrupt(); |
||||||
|
} |
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
} |
Binary file not shown.
Binary file not shown.
@ -0,0 +1,171 @@ |
|||||||
|
/* |
||||||
|
* Copyright (c) 2009-2015 jMonkeyEngine |
||||||
|
* All rights reserved. |
||||||
|
* |
||||||
|
* Redistribution and use in source and binary forms, with or without |
||||||
|
* modification, are permitted provided that the following conditions are |
||||||
|
* met: |
||||||
|
* |
||||||
|
* * Redistributions of source code must retain the above copyright |
||||||
|
* notice, this list of conditions and the following disclaimer. |
||||||
|
* |
||||||
|
* * Redistributions in binary form must reproduce the above copyright |
||||||
|
* notice, this list of conditions and the following disclaimer in the |
||||||
|
* documentation and/or other materials provided with the distribution. |
||||||
|
* |
||||||
|
* * Neither the name of 'jMonkeyEngine' nor the names of its contributors |
||||||
|
* may be used to endorse or promote products derived from this software |
||||||
|
* without specific prior written permission. |
||||||
|
* |
||||||
|
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS |
||||||
|
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED |
||||||
|
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR |
||||||
|
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR |
||||||
|
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, |
||||||
|
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, |
||||||
|
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR |
||||||
|
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF |
||||||
|
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING |
||||||
|
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
||||||
|
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
||||||
|
*/ |
||||||
|
package com.jme3.input.lwjgl; |
||||||
|
|
||||||
|
import static org.lwjgl.glfw.GLFW.*; |
||||||
|
import static com.jme3.input.KeyInput.*; |
||||||
|
|
||||||
|
public class GlfwKeyMap { |
||||||
|
|
||||||
|
private static final int[] glfwToJmeKeyMap = new int[GLFW_KEY_LAST + 1]; |
||||||
|
|
||||||
|
private static void reg(int jmeKey, int glfwKey) { |
||||||
|
glfwToJmeKeyMap[glfwKey] = jmeKey; |
||||||
|
} |
||||||
|
|
||||||
|
static { |
||||||
|
reg(KEY_ESCAPE, GLFW_KEY_ESCAPE); |
||||||
|
reg(KEY_1, GLFW_KEY_1); |
||||||
|
reg(KEY_2, GLFW_KEY_2); |
||||||
|
reg(KEY_3, GLFW_KEY_3); |
||||||
|
reg(KEY_4, GLFW_KEY_4); |
||||||
|
reg(KEY_5, GLFW_KEY_5); |
||||||
|
reg(KEY_6, GLFW_KEY_6); |
||||||
|
reg(KEY_7, GLFW_KEY_7); |
||||||
|
reg(KEY_8, GLFW_KEY_8); |
||||||
|
reg(KEY_9, GLFW_KEY_9); |
||||||
|
reg(KEY_0, GLFW_KEY_0); |
||||||
|
reg(KEY_MINUS, GLFW_KEY_MINUS); |
||||||
|
reg(KEY_EQUALS, GLFW_KEY_EQUAL); |
||||||
|
reg(KEY_BACK, GLFW_KEY_BACKSPACE); |
||||||
|
reg(KEY_TAB, GLFW_KEY_TAB); |
||||||
|
reg(KEY_Q, GLFW_KEY_Q); |
||||||
|
reg(KEY_W, GLFW_KEY_W); |
||||||
|
reg(KEY_E, GLFW_KEY_E); |
||||||
|
reg(KEY_R, GLFW_KEY_R); |
||||||
|
reg(KEY_T, GLFW_KEY_T); |
||||||
|
reg(KEY_Y, GLFW_KEY_Y); |
||||||
|
reg(KEY_U, GLFW_KEY_U); |
||||||
|
reg(KEY_I, GLFW_KEY_I); |
||||||
|
reg(KEY_O, GLFW_KEY_O); |
||||||
|
reg(KEY_P, GLFW_KEY_P); |
||||||
|
reg(KEY_LBRACKET, GLFW_KEY_LEFT_BRACKET); |
||||||
|
reg(KEY_RBRACKET, GLFW_KEY_RIGHT_BRACKET); |
||||||
|
reg(KEY_RETURN, GLFW_KEY_ENTER); |
||||||
|
reg(KEY_LCONTROL, GLFW_KEY_LEFT_CONTROL); |
||||||
|
reg(KEY_A, GLFW_KEY_A); |
||||||
|
reg(KEY_S, GLFW_KEY_S); |
||||||
|
reg(KEY_D, GLFW_KEY_D); |
||||||
|
reg(KEY_F, GLFW_KEY_F); |
||||||
|
reg(KEY_G, GLFW_KEY_G); |
||||||
|
reg(KEY_H, GLFW_KEY_H); |
||||||
|
reg(KEY_J, GLFW_KEY_J); |
||||||
|
reg(KEY_K, GLFW_KEY_K); |
||||||
|
reg(KEY_L, GLFW_KEY_L); |
||||||
|
reg(KEY_SEMICOLON, GLFW_KEY_SEMICOLON); |
||||||
|
reg(KEY_APOSTROPHE, GLFW_KEY_APOSTROPHE); |
||||||
|
reg(KEY_GRAVE, GLFW_KEY_GRAVE_ACCENT); |
||||||
|
reg(KEY_LSHIFT, GLFW_KEY_LEFT_SHIFT); |
||||||
|
reg(KEY_BACKSLASH, GLFW_KEY_BACKSLASH); |
||||||
|
reg(KEY_Z, GLFW_KEY_Z); |
||||||
|
reg(KEY_X, GLFW_KEY_X); |
||||||
|
reg(KEY_C, GLFW_KEY_C); |
||||||
|
reg(KEY_V, GLFW_KEY_V); |
||||||
|
reg(KEY_B, GLFW_KEY_B); |
||||||
|
reg(KEY_N, GLFW_KEY_N); |
||||||
|
reg(KEY_M, GLFW_KEY_M); |
||||||
|
reg(KEY_COMMA, GLFW_KEY_COMMA); |
||||||
|
reg(KEY_PERIOD, GLFW_KEY_PERIOD); |
||||||
|
reg(KEY_SLASH, GLFW_KEY_SLASH); |
||||||
|
reg(KEY_RSHIFT, GLFW_KEY_RIGHT_SHIFT); |
||||||
|
reg(KEY_MULTIPLY, GLFW_KEY_KP_MULTIPLY); |
||||||
|
reg(KEY_LMENU, GLFW_KEY_LEFT_ALT); |
||||||
|
reg(KEY_SPACE, GLFW_KEY_SPACE); |
||||||
|
reg(KEY_CAPITAL, GLFW_KEY_CAPS_LOCK); |
||||||
|
reg(KEY_F1, GLFW_KEY_F1); |
||||||
|
reg(KEY_F2, GLFW_KEY_F2); |
||||||
|
reg(KEY_F3, GLFW_KEY_F3); |
||||||
|
reg(KEY_F4, GLFW_KEY_F4); |
||||||
|
reg(KEY_F5, GLFW_KEY_F5); |
||||||
|
reg(KEY_F6, GLFW_KEY_F6); |
||||||
|
reg(KEY_F7, GLFW_KEY_F7); |
||||||
|
reg(KEY_F8, GLFW_KEY_F8); |
||||||
|
reg(KEY_F9, GLFW_KEY_F9); |
||||||
|
reg(KEY_F10, GLFW_KEY_F10); |
||||||
|
reg(KEY_NUMLOCK, GLFW_KEY_NUM_LOCK); |
||||||
|
reg(KEY_SCROLL, GLFW_KEY_SCROLL_LOCK); |
||||||
|
reg(KEY_NUMPAD7, GLFW_KEY_KP_7); |
||||||
|
reg(KEY_NUMPAD8, GLFW_KEY_KP_8); |
||||||
|
reg(KEY_NUMPAD9, GLFW_KEY_KP_9); |
||||||
|
reg(KEY_SUBTRACT, GLFW_KEY_KP_SUBTRACT); |
||||||
|
reg(KEY_NUMPAD4, GLFW_KEY_KP_4); |
||||||
|
reg(KEY_NUMPAD5, GLFW_KEY_KP_5); |
||||||
|
reg(KEY_NUMPAD6, GLFW_KEY_KP_6); |
||||||
|
reg(KEY_ADD, GLFW_KEY_KP_ADD); |
||||||
|
reg(KEY_NUMPAD1, GLFW_KEY_KP_1); |
||||||
|
reg(KEY_NUMPAD2, GLFW_KEY_KP_2); |
||||||
|
reg(KEY_NUMPAD3, GLFW_KEY_KP_3); |
||||||
|
reg(KEY_NUMPAD0, GLFW_KEY_KP_0); |
||||||
|
reg(KEY_DECIMAL, GLFW_KEY_KP_DECIMAL); |
||||||
|
reg(KEY_F11, GLFW_KEY_F11); |
||||||
|
reg(KEY_F12, GLFW_KEY_F12); |
||||||
|
reg(KEY_F13, GLFW_KEY_F13); |
||||||
|
reg(KEY_F14, GLFW_KEY_F14); |
||||||
|
reg(KEY_F15, GLFW_KEY_F15); |
||||||
|
//reg(KEY_KANA, GLFW_KEY_);
|
||||||
|
//reg(KEY_CONVERT, GLFW_KEY_);
|
||||||
|
//reg(KEY_NOCONVERT, GLFW_KEY_);
|
||||||
|
//reg(KEY_YEN, GLFW_KEY_);
|
||||||
|
//reg(KEY_NUMPADEQUALS, GLFW_KEY_);
|
||||||
|
//reg(KEY_CIRCUMFLEX, GLFW_KEY_);
|
||||||
|
//reg(KEY_AT, GLFW_KEY_);
|
||||||
|
//reg(KEY_COLON, GLFW_KEY_);
|
||||||
|
//reg(KEY_UNDERLINE, GLFW_KEY_);
|
||||||
|
//reg(KEY_KANJI, GLFW_KEY_);
|
||||||
|
//reg(KEY_STOP, GLFW_KEY_);
|
||||||
|
//reg(KEY_AX, GLFW_KEY_);
|
||||||
|
//reg(KEY_UNLABELED, GLFW_KEY_);
|
||||||
|
reg(KEY_NUMPADENTER, GLFW_KEY_KP_ENTER); |
||||||
|
reg(KEY_RCONTROL, GLFW_KEY_RIGHT_CONTROL); |
||||||
|
//reg(KEY_NUMPADCOMMA, GLFW_KEY_);
|
||||||
|
reg(KEY_DIVIDE, GLFW_KEY_KP_DIVIDE); |
||||||
|
reg(KEY_SYSRQ, GLFW_KEY_PRINT_SCREEN); |
||||||
|
reg(KEY_RMENU, GLFW_KEY_RIGHT_ALT); |
||||||
|
reg(KEY_PAUSE, GLFW_KEY_PAUSE); |
||||||
|
reg(KEY_HOME, GLFW_KEY_HOME); |
||||||
|
reg(KEY_UP, GLFW_KEY_UP); |
||||||
|
reg(KEY_PRIOR, GLFW_KEY_PAGE_UP); |
||||||
|
reg(KEY_LEFT, GLFW_KEY_LEFT); |
||||||
|
reg(KEY_RIGHT, GLFW_KEY_RIGHT); |
||||||
|
reg(KEY_END, GLFW_KEY_END); |
||||||
|
reg(KEY_DOWN, GLFW_KEY_DOWN); |
||||||
|
reg(KEY_NEXT, GLFW_KEY_PAGE_DOWN); |
||||||
|
reg(KEY_INSERT, GLFW_KEY_INSERT); |
||||||
|
reg(KEY_DELETE, GLFW_KEY_DELETE); |
||||||
|
reg(KEY_LMETA, GLFW_KEY_LEFT_SUPER); |
||||||
|
reg(KEY_RMETA, GLFW_KEY_RIGHT_SUPER); |
||||||
|
} |
||||||
|
|
||||||
|
public static int toJmeKeyCode(int glfwKey) { |
||||||
|
return glfwToJmeKeyMap[glfwKey]; |
||||||
|
} |
||||||
|
} |
@ -1 +0,0 @@ |
|||||||
X-Comment: Created with jMonkeyPlatform |
|
@ -1,76 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<!-- You may freely edit this file. See commented blocks below for --> |
|
||||||
<!-- some examples of how to customize the build. --> |
|
||||||
<!-- (If you delete it and reopen the project it will be recreated.) --> |
|
||||||
<!-- By default, only the Clean and Build commands use this build script. --> |
|
||||||
<!-- Commands such as Run, Debug, and Test only use this build script if --> |
|
||||||
<!-- the Compile on Save feature is turned off for the project. --> |
|
||||||
<!-- You can turn off the Compile on Save (or Deploy on Save) setting --> |
|
||||||
<!-- in the project's Project Properties dialog box.--> |
|
||||||
<project name="BasicGameTemplate" default="default" basedir="."> |
|
||||||
<description>Builds, tests, and runs the project BasicGameTemplate.</description> |
|
||||||
<import file="nbproject/build-impl.xml"/> |
|
||||||
|
|
||||||
<!-- |
|
||||||
|
|
||||||
There exist several targets which are by default empty and which can be |
|
||||||
used for execution of your tasks. These targets are usually executed |
|
||||||
before and after some main targets. They are: |
|
||||||
|
|
||||||
-pre-init: called before initialization of project properties |
|
||||||
-post-init: called after initialization of project properties |
|
||||||
-pre-compile: called before javac compilation |
|
||||||
-post-compile: called after javac compilation |
|
||||||
-pre-compile-single: called before javac compilation of single file |
|
||||||
-post-compile-single: called after javac compilation of single file |
|
||||||
-pre-compile-test: called before javac compilation of JUnit tests |
|
||||||
-post-compile-test: called after javac compilation of JUnit tests |
|
||||||
-pre-compile-test-single: called before javac compilation of single JUnit test |
|
||||||
-post-compile-test-single: called after javac compilation of single JUunit test |
|
||||||
-pre-jar: called before JAR building |
|
||||||
-post-jar: called after JAR building |
|
||||||
-post-clean: called after cleaning build products |
|
||||||
|
|
||||||
(Targets beginning with '-' are not intended to be called on their own.) |
|
||||||
|
|
||||||
Example of inserting an obfuscator after compilation could look like this: |
|
||||||
|
|
||||||
<target name="-post-compile"> |
|
||||||
<obfuscate> |
|
||||||
<fileset dir="${build.classes.dir}"/> |
|
||||||
</obfuscate> |
|
||||||
</target> |
|
||||||
|
|
||||||
For list of available properties check the imported |
|
||||||
nbproject/build-impl.xml file. |
|
||||||
|
|
||||||
|
|
||||||
Another way to customize the build is by overriding existing main targets. |
|
||||||
The targets of interest are: |
|
||||||
|
|
||||||
-init-macrodef-javac: defines macro for javac compilation |
|
||||||
-init-macrodef-junit: defines macro for junit execution |
|
||||||
-init-macrodef-debug: defines macro for class debugging |
|
||||||
-init-macrodef-java: defines macro for class execution |
|
||||||
-do-jar-with-manifest: JAR building (if you are using a manifest) |
|
||||||
-do-jar-without-manifest: JAR building (if you are not using a manifest) |
|
||||||
run: execution of project |
|
||||||
-javadoc-build: Javadoc generation |
|
||||||
test-report: JUnit report generation |
|
||||||
|
|
||||||
An example of overriding the target for project execution could look like this: |
|
||||||
|
|
||||||
<target name="run" depends="BasicGameTemplate-impl.jar"> |
|
||||||
<exec dir="bin" executable="launcher.exe"> |
|
||||||
<arg file="${dist.jar}"/> |
|
||||||
</exec> |
|
||||||
</target> |
|
||||||
|
|
||||||
Notice that the overridden target depends on the jar target and not only on |
|
||||||
the compile target as the regular run target does. Again, for a list of available |
|
||||||
properties which you can use, check the target you are overriding in the |
|
||||||
nbproject/build-impl.xml file. |
|
||||||
|
|
||||||
--> |
|
||||||
|
|
||||||
</project> |
|
@ -1,22 +0,0 @@ |
|||||||
<jnlp spec="1.0+" codebase="${jnlp.codebase}" href="launch.jnlp"> |
|
||||||
<information> |
|
||||||
<title>${APPLICATION.TITLE}</title> |
|
||||||
<vendor>${APPLICATION.VENDOR}</vendor> |
|
||||||
<homepage href="${APPLICATION.HOMEPAGE}"/> |
|
||||||
<description>${APPLICATION.DESC}</description> |
|
||||||
<description kind="short">${APPLICATION.DESC.SHORT}</description> |
|
||||||
<!--${JNLP.ICONS}--> |
|
||||||
<!--${JNLP.OFFLINE.ALLOWED}--> |
|
||||||
</information> |
|
||||||
<!--${JNLP.SECURITY}--> |
|
||||||
<resources> |
|
||||||
<!--${JNLP.RESOURCES.RUNTIME}--> |
|
||||||
<!--${JNLP.RESOURCES.MAIN.JAR}--> |
|
||||||
<!--${JNLP.RESOURCES.JARS}--> |
|
||||||
<jar href='lib/assets.jar'/> |
|
||||||
<!--${JNLP.RESOURCES.EXTENSIONS}--> |
|
||||||
</resources> |
|
||||||
<application-desc main-class="${jnlp.main.class}"> |
|
||||||
<!--${JNLP.APPLICATION.ARGS}--> |
|
||||||
</application-desc> |
|
||||||
</jnlp> |
|
@ -1,8 +0,0 @@ |
|||||||
build.xml.data.CRC32=94bf7c61 |
|
||||||
build.xml.script.CRC32=79a29eb7 |
|
||||||
build.xml.stylesheet.CRC32=958a1d3e@1.32.1.45 |
|
||||||
# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml. |
|
||||||
# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you. |
|
||||||
nbproject/build-impl.xml.data.CRC32=1ac6e2f9 |
|
||||||
nbproject/build-impl.xml.script.CRC32=28b1a2c2 |
|
||||||
nbproject/build-impl.xml.stylesheet.CRC32=876e7a8f@1.74.1.48 |
|
@ -1,92 +0,0 @@ |
|||||||
annotation.processing.enabled=true |
|
||||||
annotation.processing.enabled.in.editor=false |
|
||||||
annotation.processing.processors.list= |
|
||||||
annotation.processing.run.all.processors=true |
|
||||||
application.title=MyGame |
|
||||||
application.vendor=MyCompany |
|
||||||
assets.jar.name=assets.jar |
|
||||||
assets.excludes=**/*.j3odata,**/*.mesh,**/*.skeleton,**/*.mesh\.xml,**/*.skeleton\.xml,**/*.scene,**/*.material,**/*.obj,**/*.mtl,**/*.3ds,**/*.dae,**/*.blend,**/*.blend*[0-9] |
|
||||||
assets.folder.name=assets |
|
||||||
assets.compress=true |
|
||||||
build.classes.dir=${build.dir}/classes |
|
||||||
build.classes.excludes=**/*.java,**/*.form |
|
||||||
# This directory is removed when the project is cleaned: |
|
||||||
build.dir=build |
|
||||||
build.generated.dir=${build.dir}/generated |
|
||||||
build.generated.sources.dir=${build.dir}/generated-sources |
|
||||||
# Only compile against the classpath explicitly listed here: |
|
||||||
build.sysclasspath=ignore |
|
||||||
build.test.classes.dir=${build.dir}/test/classes |
|
||||||
build.test.results.dir=${build.dir}/test/results |
|
||||||
compile.on.save=true |
|
||||||
# Uncomment to specify the preferred debugger connection transport: |
|
||||||
#debug.transport=dt_socket |
|
||||||
debug.classpath=\ |
|
||||||
${run.classpath} |
|
||||||
debug.test.classpath=\ |
|
||||||
${run.test.classpath} |
|
||||||
# This directory is removed when the project is cleaned: |
|
||||||
dist.dir=dist |
|
||||||
dist.jar=${dist.dir}/${application.title}.jar |
|
||||||
dist.javadoc.dir=${dist.dir}/javadoc |
|
||||||
endorsed.classpath= |
|
||||||
excludes= |
|
||||||
includes=** |
|
||||||
jar.compress=false |
|
||||||
javac.classpath=\ |
|
||||||
${libs.jme3-jogg.classpath}:\ |
|
||||||
${libs.jme3-blender.classpath}:\ |
|
||||||
${libs.jme3-networking.classpath}:\ |
|
||||||
${libs.jme3-plugins.classpath}:\ |
|
||||||
${libs.jme3-core.classpath}:\ |
|
||||||
${libs.jme3-desktop.classpath}:\ |
|
||||||
${libs.jme3-lwjgl.classpath}:\ |
|
||||||
${libs.jme3-niftygui.classpath}:\ |
|
||||||
${libs.jme3-effects.classpath}:\ |
|
||||||
${libs.jme3-terrain.classpath}:\ |
|
||||||
${libs.jme3-jbullet.classpath} |
|
||||||
# Space-separated list of extra javac options |
|
||||||
javac.compilerargs= |
|
||||||
javac.deprecation=false |
|
||||||
javac.processorpath=\ |
|
||||||
${javac.classpath} |
|
||||||
javac.source=1.6 |
|
||||||
javac.target=1.6 |
|
||||||
javac.test.classpath=\ |
|
||||||
${javac.classpath}:\ |
|
||||||
${build.classes.dir} |
|
||||||
javadoc.additionalparam= |
|
||||||
javadoc.author=false |
|
||||||
javadoc.encoding=${source.encoding} |
|
||||||
javadoc.noindex=false |
|
||||||
javadoc.nonavbar=false |
|
||||||
javadoc.notree=false |
|
||||||
javadoc.private=false |
|
||||||
javadoc.splitindex=true |
|
||||||
javadoc.use=true |
|
||||||
javadoc.version=false |
|
||||||
javadoc.windowtitle= |
|
||||||
jaxbwiz.endorsed.dirs="${netbeans.home}/../ide12/modules/ext/jaxb/api" |
|
||||||
jnlp.codebase.type=local |
|
||||||
jnlp.descriptor=application |
|
||||||
jnlp.enabled=false |
|
||||||
jnlp.offline-allowed=false |
|
||||||
jnlp.signed=false |
|
||||||
main.class=mygame.Main |
|
||||||
meta.inf.dir=${src.dir}/META-INF |
|
||||||
manifest.file=MANIFEST.MF |
|
||||||
mkdist.disabled=false |
|
||||||
platform.active=default_platform |
|
||||||
run.classpath=\ |
|
||||||
${javac.classpath}:\ |
|
||||||
${build.classes.dir}:\ |
|
||||||
${assets.folder.name} |
|
||||||
# Space-separated list of JVM arguments used when running the project |
|
||||||
# (you may also define separate properties like run-sys-prop.name=value instead of -Dname=value |
|
||||||
# or test-sys-prop.name=value to set system properties for unit tests): |
|
||||||
run.jvmargs= |
|
||||||
run.test.classpath=\ |
|
||||||
${javac.test.classpath}:\ |
|
||||||
${build.test.classes.dir} |
|
||||||
source.encoding=UTF-8 |
|
||||||
src.dir=src |
|
@ -1,18 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<project xmlns="http://www.netbeans.org/ns/project/1"> |
|
||||||
<type>org.netbeans.modules.java.j2seproject</type> |
|
||||||
<configuration> |
|
||||||
<buildExtensions xmlns="http://www.netbeans.org/ns/ant-build-extender/1"> |
|
||||||
<extension file="assets-impl.xml" id="assets"> |
|
||||||
<dependency dependsOn="-init-assets" target="-do-init"/> |
|
||||||
</extension> |
|
||||||
</buildExtensions> |
|
||||||
<data xmlns="http://www.netbeans.org/ns/j2se-project/3"> |
|
||||||
<name>BasicGameTemplate</name> |
|
||||||
<source-roots> |
|
||||||
<root id="src.dir"/> |
|
||||||
</source-roots> |
|
||||||
<test-roots/> |
|
||||||
</data> |
|
||||||
</configuration> |
|
||||||
</project> |
|
@ -1,43 +0,0 @@ |
|||||||
package mygame; |
|
||||||
|
|
||||||
import com.jme3.app.SimpleApplication; |
|
||||||
import com.jme3.material.Material; |
|
||||||
import com.jme3.math.ColorRGBA; |
|
||||||
import com.jme3.math.Vector3f; |
|
||||||
import com.jme3.renderer.RenderManager; |
|
||||||
import com.jme3.scene.Geometry; |
|
||||||
import com.jme3.scene.shape.Box; |
|
||||||
|
|
||||||
/** |
|
||||||
* test |
|
||||||
* @author normenhansen |
|
||||||
*/ |
|
||||||
public class Main extends SimpleApplication { |
|
||||||
|
|
||||||
public static void main(String[] args) { |
|
||||||
Main app = new Main(); |
|
||||||
app.start(); |
|
||||||
} |
|
||||||
|
|
||||||
@Override |
|
||||||
public void simpleInitApp() { |
|
||||||
Box b = new Box(1, 1, 1); |
|
||||||
Geometry geom = new Geometry("Box", b); |
|
||||||
|
|
||||||
Material mat = new Material(assetManager, "Common/MatDefs/Misc/Unshaded.j3md"); |
|
||||||
mat.setColor("Color", ColorRGBA.Blue); |
|
||||||
geom.setMaterial(mat); |
|
||||||
|
|
||||||
rootNode.attachChild(geom); |
|
||||||
} |
|
||||||
|
|
||||||
@Override |
|
||||||
public void simpleUpdate(float tpf) { |
|
||||||
//TODO: add update code
|
|
||||||
} |
|
||||||
|
|
||||||
@Override |
|
||||||
public void simpleRender(RenderManager rm) { |
|
||||||
//TODO: add render code
|
|
||||||
} |
|
||||||
} |
|
@ -1,73 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<!-- You may freely edit this file. See commented blocks below for --> |
|
||||||
<!-- some examples of how to customize the build. --> |
|
||||||
<!-- (If you delete it and reopen the project it will be recreated.) --> |
|
||||||
<!-- By default, only the Clean and Build commands use this build script. --> |
|
||||||
<!-- Commands such as Run, Debug, and Test only use this build script if --> |
|
||||||
<!-- the Compile on Save feature is turned off for the project. --> |
|
||||||
<!-- You can turn off the Compile on Save (or Deploy on Save) setting --> |
|
||||||
<!-- in the project's Project Properties dialog box.--> |
|
||||||
<project name="JME3TestsTemplate" default="default" basedir="."> |
|
||||||
<description>Builds, tests, and runs the project JME3TestsTemplate.</description> |
|
||||||
<import file="nbproject/build-impl.xml"/> |
|
||||||
<!-- |
|
||||||
|
|
||||||
There exist several targets which are by default empty and which can be |
|
||||||
used for execution of your tasks. These targets are usually executed |
|
||||||
before and after some main targets. They are: |
|
||||||
|
|
||||||
-pre-init: called before initialization of project properties |
|
||||||
-post-init: called after initialization of project properties |
|
||||||
-pre-compile: called before javac compilation |
|
||||||
-post-compile: called after javac compilation |
|
||||||
-pre-compile-single: called before javac compilation of single file |
|
||||||
-post-compile-single: called after javac compilation of single file |
|
||||||
-pre-compile-test: called before javac compilation of JUnit tests |
|
||||||
-post-compile-test: called after javac compilation of JUnit tests |
|
||||||
-pre-compile-test-single: called before javac compilation of single JUnit test |
|
||||||
-post-compile-test-single: called after javac compilation of single JUunit test |
|
||||||
-pre-jar: called before JAR building |
|
||||||
-post-jar: called after JAR building |
|
||||||
-post-clean: called after cleaning build products |
|
||||||
|
|
||||||
(Targets beginning with '-' are not intended to be called on their own.) |
|
||||||
|
|
||||||
Example of inserting an obfuscator after compilation could look like this: |
|
||||||
|
|
||||||
<target name="-post-compile"> |
|
||||||
<obfuscate> |
|
||||||
<fileset dir="${build.classes.dir}"/> |
|
||||||
</obfuscate> |
|
||||||
</target> |
|
||||||
|
|
||||||
For list of available properties check the imported |
|
||||||
nbproject/build-impl.xml file. |
|
||||||
|
|
||||||
|
|
||||||
Another way to customize the build is by overriding existing main targets. |
|
||||||
The targets of interest are: |
|
||||||
|
|
||||||
-init-macrodef-javac: defines macro for javac compilation |
|
||||||
-init-macrodef-junit: defines macro for junit execution |
|
||||||
-init-macrodef-debug: defines macro for class debugging |
|
||||||
-init-macrodef-java: defines macro for class execution |
|
||||||
-do-jar: JAR building |
|
||||||
run: execution of project |
|
||||||
-javadoc-build: Javadoc generation |
|
||||||
test-report: JUnit report generation |
|
||||||
|
|
||||||
An example of overriding the target for project execution could look like this: |
|
||||||
|
|
||||||
<target name="run" depends="JME3TestsTemplate-impl.jar"> |
|
||||||
<exec dir="bin" executable="launcher.exe"> |
|
||||||
<arg file="${dist.jar}"/> |
|
||||||
</exec> |
|
||||||
</target> |
|
||||||
|
|
||||||
Notice that the overridden target depends on the jar target and not only on |
|
||||||
the compile target as the regular run target does. Again, for a list of available |
|
||||||
properties which you can use, check the target you are overriding in the |
|
||||||
nbproject/build-impl.xml file. |
|
||||||
|
|
||||||
--> |
|
||||||
</project> |
|
@ -1,880 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<!-- |
|
||||||
*** GENERATED FROM project.xml - DO NOT EDIT *** |
|
||||||
*** EDIT ../build.xml INSTEAD *** |
|
||||||
|
|
||||||
For the purpose of easier reading the script |
|
||||||
is divided into following sections: |
|
||||||
|
|
||||||
- initialization |
|
||||||
- compilation |
|
||||||
- jar |
|
||||||
- execution |
|
||||||
- debugging |
|
||||||
- javadoc |
|
||||||
- junit compilation |
|
||||||
- junit execution |
|
||||||
- junit debugging |
|
||||||
- applet |
|
||||||
- cleanup |
|
||||||
|
|
||||||
--> |
|
||||||
<project xmlns:j2seproject1="http://www.netbeans.org/ns/j2se-project/1" xmlns:j2seproject3="http://www.netbeans.org/ns/j2se-project/3" xmlns:jaxrpc="http://www.netbeans.org/ns/j2se-project/jax-rpc" basedir=".." default="default" name="JME3TestsTemplate-impl"> |
|
||||||
<fail message="Please build using Ant 1.7.1 or higher."> |
|
||||||
<condition> |
|
||||||
<not> |
|
||||||
<antversion atleast="1.7.1"/> |
|
||||||
</not> |
|
||||||
</condition> |
|
||||||
</fail> |
|
||||||
<target depends="test,jar,javadoc" description="Build and test whole project." name="default"/> |
|
||||||
<!-- |
|
||||||
====================== |
|
||||||
INITIALIZATION SECTION |
|
||||||
====================== |
|
||||||
--> |
|
||||||
<target name="-pre-init"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target depends="-pre-init" name="-init-private"> |
|
||||||
<property file="nbproject/private/config.properties"/> |
|
||||||
<property file="nbproject/private/configs/${config}.properties"/> |
|
||||||
<property file="nbproject/private/private.properties"/> |
|
||||||
</target> |
|
||||||
<target depends="-pre-init,-init-private" name="-init-user"> |
|
||||||
<property file="${user.properties.file}"/> |
|
||||||
<!-- The two properties below are usually overridden --> |
|
||||||
<!-- by the active platform. Just a fallback. --> |
|
||||||
<property name="default.javac.source" value="1.4"/> |
|
||||||
<property name="default.javac.target" value="1.4"/> |
|
||||||
</target> |
|
||||||
<target depends="-pre-init,-init-private,-init-user" name="-init-project"> |
|
||||||
<property file="nbproject/configs/${config}.properties"/> |
|
||||||
<property file="nbproject/project.properties"/> |
|
||||||
</target> |
|
||||||
<target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" name="-do-init"> |
|
||||||
<available file="${manifest.file}" property="manifest.available"/> |
|
||||||
<available file="${application.splash}" property="splashscreen.available"/> |
|
||||||
<condition property="main.class.available"> |
|
||||||
<and> |
|
||||||
<isset property="main.class"/> |
|
||||||
<not> |
|
||||||
<equals arg1="${main.class}" arg2="" trim="true"/> |
|
||||||
</not> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<condition property="manifest.available+main.class"> |
|
||||||
<and> |
|
||||||
<isset property="manifest.available"/> |
|
||||||
<isset property="main.class.available"/> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<condition property="do.mkdist"> |
|
||||||
<and> |
|
||||||
<isset property="libs.CopyLibs.classpath"/> |
|
||||||
<not> |
|
||||||
<istrue value="${mkdist.disabled}"/> |
|
||||||
</not> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<condition property="manifest.available+main.class+mkdist.available"> |
|
||||||
<and> |
|
||||||
<istrue value="${manifest.available+main.class}"/> |
|
||||||
<isset property="do.mkdist"/> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<condition property="manifest.available+main.class+mkdist.available+splashscreen.available"> |
|
||||||
<and> |
|
||||||
<istrue value="${manifest.available+main.class+mkdist.available}"/> |
|
||||||
<istrue value="${splashscreen.available}"/> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<condition property="do.archive"> |
|
||||||
<not> |
|
||||||
<istrue value="${jar.archive.disabled}"/> |
|
||||||
</not> |
|
||||||
</condition> |
|
||||||
<condition property="do.archive+manifest.available"> |
|
||||||
<and> |
|
||||||
<isset property="manifest.available"/> |
|
||||||
<istrue value="${do.archive}"/> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<condition property="do.archive+manifest.available+main.class"> |
|
||||||
<and> |
|
||||||
<istrue value="${manifest.available+main.class}"/> |
|
||||||
<istrue value="${do.archive}"/> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<condition property="do.archive+manifest.available+main.class+mkdist.available"> |
|
||||||
<and> |
|
||||||
<istrue value="${manifest.available+main.class+mkdist.available}"/> |
|
||||||
<istrue value="${do.archive}"/> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<condition property="do.archive+manifest.available+main.class+mkdist.available+splashscreen.available"> |
|
||||||
<and> |
|
||||||
<istrue value="${manifest.available+main.class+mkdist.available+splashscreen.available}"/> |
|
||||||
<istrue value="${do.archive}"/> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<condition property="have.tests"> |
|
||||||
<or/> |
|
||||||
</condition> |
|
||||||
<condition property="have.sources"> |
|
||||||
<or> |
|
||||||
<available file="${src.dir}"/> |
|
||||||
</or> |
|
||||||
</condition> |
|
||||||
<condition property="netbeans.home+have.tests"> |
|
||||||
<and> |
|
||||||
<isset property="netbeans.home"/> |
|
||||||
<isset property="have.tests"/> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<condition property="no.javadoc.preview"> |
|
||||||
<and> |
|
||||||
<isset property="javadoc.preview"/> |
|
||||||
<isfalse value="${javadoc.preview}"/> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<property name="run.jvmargs" value=""/> |
|
||||||
<property name="javac.compilerargs" value=""/> |
|
||||||
<property name="work.dir" value="${basedir}"/> |
|
||||||
<condition property="no.deps"> |
|
||||||
<and> |
|
||||||
<istrue value="${no.dependencies}"/> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<property name="javac.debug" value="true"/> |
|
||||||
<property name="javadoc.preview" value="true"/> |
|
||||||
<property name="application.args" value=""/> |
|
||||||
<property name="source.encoding" value="${file.encoding}"/> |
|
||||||
<property name="runtime.encoding" value="${source.encoding}"/> |
|
||||||
<condition property="javadoc.encoding.used" value="${javadoc.encoding}"> |
|
||||||
<and> |
|
||||||
<isset property="javadoc.encoding"/> |
|
||||||
<not> |
|
||||||
<equals arg1="${javadoc.encoding}" arg2=""/> |
|
||||||
</not> |
|
||||||
</and> |
|
||||||
</condition> |
|
||||||
<property name="javadoc.encoding.used" value="${source.encoding}"/> |
|
||||||
<property name="includes" value="**"/> |
|
||||||
<property name="excludes" value=""/> |
|
||||||
<property name="do.depend" value="false"/> |
|
||||||
<condition property="do.depend.true"> |
|
||||||
<istrue value="${do.depend}"/> |
|
||||||
</condition> |
|
||||||
<path id="endorsed.classpath.path" path="${endorsed.classpath}"/> |
|
||||||
<condition else="" property="endorsed.classpath.cmd.line.arg" value="-Xbootclasspath/p:'${toString:endorsed.classpath.path}'"> |
|
||||||
<length length="0" string="${endorsed.classpath}" when="greater"/> |
|
||||||
</condition> |
|
||||||
<property name="javac.fork" value="false"/> |
|
||||||
<property name="jar.index" value="false"/> |
|
||||||
<available file="${meta.inf.dir}/persistence.xml" property="has.persistence.xml"/> |
|
||||||
</target> |
|
||||||
<target name="-post-init"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target depends="-pre-init,-init-private,-init-user,-init-project,-do-init" name="-init-check"> |
|
||||||
<fail unless="src.dir">Must set src.dir</fail> |
|
||||||
<fail unless="build.dir">Must set build.dir</fail> |
|
||||||
<fail unless="dist.dir">Must set dist.dir</fail> |
|
||||||
<fail unless="build.classes.dir">Must set build.classes.dir</fail> |
|
||||||
<fail unless="dist.javadoc.dir">Must set dist.javadoc.dir</fail> |
|
||||||
<fail unless="build.test.classes.dir">Must set build.test.classes.dir</fail> |
|
||||||
<fail unless="build.test.results.dir">Must set build.test.results.dir</fail> |
|
||||||
<fail unless="build.classes.excludes">Must set build.classes.excludes</fail> |
|
||||||
<fail unless="dist.jar">Must set dist.jar</fail> |
|
||||||
</target> |
|
||||||
<target name="-init-macrodef-property"> |
|
||||||
<macrodef name="property" uri="http://www.netbeans.org/ns/j2se-project/1"> |
|
||||||
<attribute name="name"/> |
|
||||||
<attribute name="value"/> |
|
||||||
<sequential> |
|
||||||
<property name="@{name}" value="${@{value}}"/> |
|
||||||
</sequential> |
|
||||||
</macrodef> |
|
||||||
</target> |
|
||||||
<target depends="-init-ap-cmdline-properties" if="ap.supported.internal" name="-init-macrodef-javac-with-processors"> |
|
||||||
<macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3"> |
|
||||||
<attribute default="${src.dir}" name="srcdir"/> |
|
||||||
<attribute default="${build.classes.dir}" name="destdir"/> |
|
||||||
<attribute default="${javac.classpath}" name="classpath"/> |
|
||||||
<attribute default="${javac.processorpath}" name="processorpath"/> |
|
||||||
<attribute default="${build.generated.sources.dir}/ap-source-output" name="apgeneratedsrcdir"/> |
|
||||||
<attribute default="${includes}" name="includes"/> |
|
||||||
<attribute default="${excludes}" name="excludes"/> |
|
||||||
<attribute default="${javac.debug}" name="debug"/> |
|
||||||
<attribute default="${empty.dir}" name="sourcepath"/> |
|
||||||
<attribute default="${empty.dir}" name="gensrcdir"/> |
|
||||||
<element name="customize" optional="true"/> |
|
||||||
<sequential> |
|
||||||
<property location="${build.dir}/empty" name="empty.dir"/> |
|
||||||
<mkdir dir="${empty.dir}"/> |
|
||||||
<mkdir dir="@{apgeneratedsrcdir}"/> |
|
||||||
<javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" fork="${javac.fork}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}"> |
|
||||||
<src> |
|
||||||
<dirset dir="@{gensrcdir}" erroronmissingdir="false"> |
|
||||||
<include name="*"/> |
|
||||||
</dirset> |
|
||||||
</src> |
|
||||||
<classpath> |
|
||||||
<path path="@{classpath}"/> |
|
||||||
</classpath> |
|
||||||
<compilerarg line="${endorsed.classpath.cmd.line.arg}"/> |
|
||||||
<compilerarg line="${javac.compilerargs}"/> |
|
||||||
<compilerarg value="-processorpath"/> |
|
||||||
<compilerarg path="@{processorpath}:${empty.dir}"/> |
|
||||||
<compilerarg line="${ap.processors.internal}"/> |
|
||||||
<compilerarg line="${annotation.processing.processor.options}"/> |
|
||||||
<compilerarg value="-s"/> |
|
||||||
<compilerarg path="@{apgeneratedsrcdir}"/> |
|
||||||
<compilerarg line="${ap.proc.none.internal}"/> |
|
||||||
<customize/> |
|
||||||
</javac> |
|
||||||
</sequential> |
|
||||||
</macrodef> |
|
||||||
</target> |
|
||||||
<target depends="-init-ap-cmdline-properties" name="-init-macrodef-javac-without-processors" unless="ap.supported.internal"> |
|
||||||
<macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3"> |
|
||||||
<attribute default="${src.dir}" name="srcdir"/> |
|
||||||
<attribute default="${build.classes.dir}" name="destdir"/> |
|
||||||
<attribute default="${javac.classpath}" name="classpath"/> |
|
||||||
<attribute default="${javac.processorpath}" name="processorpath"/> |
|
||||||
<attribute default="${build.generated.sources.dir}/ap-source-output" name="apgeneratedsrcdir"/> |
|
||||||
<attribute default="${includes}" name="includes"/> |
|
||||||
<attribute default="${excludes}" name="excludes"/> |
|
||||||
<attribute default="${javac.debug}" name="debug"/> |
|
||||||
<attribute default="${empty.dir}" name="sourcepath"/> |
|
||||||
<attribute default="${empty.dir}" name="gensrcdir"/> |
|
||||||
<element name="customize" optional="true"/> |
|
||||||
<sequential> |
|
||||||
<property location="${build.dir}/empty" name="empty.dir"/> |
|
||||||
<mkdir dir="${empty.dir}"/> |
|
||||||
<javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" fork="${javac.fork}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}"> |
|
||||||
<src> |
|
||||||
<dirset dir="@{gensrcdir}" erroronmissingdir="false"> |
|
||||||
<include name="*"/> |
|
||||||
</dirset> |
|
||||||
</src> |
|
||||||
<classpath> |
|
||||||
<path path="@{classpath}"/> |
|
||||||
</classpath> |
|
||||||
<compilerarg line="${endorsed.classpath.cmd.line.arg}"/> |
|
||||||
<compilerarg line="${javac.compilerargs}"/> |
|
||||||
<customize/> |
|
||||||
</javac> |
|
||||||
</sequential> |
|
||||||
</macrodef> |
|
||||||
</target> |
|
||||||
<target depends="-init-macrodef-javac-with-processors,-init-macrodef-javac-without-processors" name="-init-macrodef-javac"> |
|
||||||
<macrodef name="depend" uri="http://www.netbeans.org/ns/j2se-project/3"> |
|
||||||
<attribute default="${src.dir}" name="srcdir"/> |
|
||||||
<attribute default="${build.classes.dir}" name="destdir"/> |
|
||||||
<attribute default="${javac.classpath}" name="classpath"/> |
|
||||||
<sequential> |
|
||||||
<depend cache="${build.dir}/depcache" destdir="@{destdir}" excludes="${excludes}" includes="${includes}" srcdir="@{srcdir}"> |
|
||||||
<classpath> |
|
||||||
<path path="@{classpath}"/> |
|
||||||
</classpath> |
|
||||||
</depend> |
|
||||||
</sequential> |
|
||||||
</macrodef> |
|
||||||
<macrodef name="force-recompile" uri="http://www.netbeans.org/ns/j2se-project/3"> |
|
||||||
<attribute default="${build.classes.dir}" name="destdir"/> |
|
||||||
<sequential> |
|
||||||
<fail unless="javac.includes">Must set javac.includes</fail> |
|
||||||
<pathconvert pathsep="," property="javac.includes.binary"> |
|
||||||
<path> |
|
||||||
<filelist dir="@{destdir}" files="${javac.includes}"/> |
|
||||||
</path> |
|
||||||
<globmapper from="*.java" to="*.class"/> |
|
||||||
</pathconvert> |
|
||||||
<delete> |
|
||||||
<files includes="${javac.includes.binary}"/> |
|
||||||
</delete> |
|
||||||
</sequential> |
|
||||||
</macrodef> |
|
||||||
</target> |
|
||||||
<target name="-init-macrodef-junit"> |
|
||||||
<macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3"> |
|
||||||
<attribute default="${includes}" name="includes"/> |
|
||||||
<attribute default="${excludes}" name="excludes"/> |
|
||||||
<attribute default="**" name="testincludes"/> |
|
||||||
<sequential> |
|
||||||
<junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true" tempdir="${build.dir}"> |
|
||||||
<batchtest todir="${build.test.results.dir}"/> |
|
||||||
<classpath> |
|
||||||
<path path="${run.test.classpath}"/> |
|
||||||
</classpath> |
|
||||||
<syspropertyset> |
|
||||||
<propertyref prefix="test-sys-prop."/> |
|
||||||
<mapper from="test-sys-prop.*" to="*" type="glob"/> |
|
||||||
</syspropertyset> |
|
||||||
<formatter type="brief" usefile="false"/> |
|
||||||
<formatter type="xml"/> |
|
||||||
<jvmarg line="${endorsed.classpath.cmd.line.arg}"/> |
|
||||||
<jvmarg line="${run.jvmargs}"/> |
|
||||||
</junit> |
|
||||||
</sequential> |
|
||||||
</macrodef> |
|
||||||
</target> |
|
||||||
<target depends="-init-debug-args" name="-init-macrodef-nbjpda"> |
|
||||||
<macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/j2se-project/1"> |
|
||||||
<attribute default="${main.class}" name="name"/> |
|
||||||
<attribute default="${debug.classpath}" name="classpath"/> |
|
||||||
<attribute default="" name="stopclassname"/> |
|
||||||
<sequential> |
|
||||||
<nbjpdastart addressproperty="jpda.address" name="@{name}" stopclassname="@{stopclassname}" transport="${debug-transport}"> |
|
||||||
<classpath> |
|
||||||
<path path="@{classpath}"/> |
|
||||||
</classpath> |
|
||||||
</nbjpdastart> |
|
||||||
</sequential> |
|
||||||
</macrodef> |
|
||||||
<macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/j2se-project/1"> |
|
||||||
<attribute default="${build.classes.dir}" name="dir"/> |
|
||||||
<sequential> |
|
||||||
<nbjpdareload> |
|
||||||
<fileset dir="@{dir}" includes="${fix.classes}"> |
|
||||||
<include name="${fix.includes}*.class"/> |
|
||||||
</fileset> |
|
||||||
</nbjpdareload> |
|
||||||
</sequential> |
|
||||||
</macrodef> |
|
||||||
</target> |
|
||||||
<target name="-init-debug-args"> |
|
||||||
<property name="version-output" value="java version "${ant.java.version}"/> |
|
||||||
<condition property="have-jdk-older-than-1.4"> |
|
||||||
<or> |
|
||||||
<contains string="${version-output}" substring="java version "1.0"/> |
|
||||||
<contains string="${version-output}" substring="java version "1.1"/> |
|
||||||
<contains string="${version-output}" substring="java version "1.2"/> |
|
||||||
<contains string="${version-output}" substring="java version "1.3"/> |
|
||||||
</or> |
|
||||||
</condition> |
|
||||||
<condition else="-Xdebug" property="debug-args-line" value="-Xdebug -Xnoagent -Djava.compiler=none"> |
|
||||||
<istrue value="${have-jdk-older-than-1.4}"/> |
|
||||||
</condition> |
|
||||||
<condition else="dt_socket" property="debug-transport-by-os" value="dt_shmem"> |
|
||||||
<os family="windows"/> |
|
||||||
</condition> |
|
||||||
<condition else="${debug-transport-by-os}" property="debug-transport" value="${debug.transport}"> |
|
||||||
<isset property="debug.transport"/> |
|
||||||
</condition> |
|
||||||
</target> |
|
||||||
<target depends="-init-debug-args" name="-init-macrodef-debug"> |
|
||||||
<macrodef name="debug" uri="http://www.netbeans.org/ns/j2se-project/3"> |
|
||||||
<attribute default="${main.class}" name="classname"/> |
|
||||||
<attribute default="${debug.classpath}" name="classpath"/> |
|
||||||
<element name="customize" optional="true"/> |
|
||||||
<sequential> |
|
||||||
<java classname="@{classname}" dir="${work.dir}" fork="true"> |
|
||||||
<jvmarg line="${endorsed.classpath.cmd.line.arg}"/> |
|
||||||
<jvmarg line="${debug-args-line}"/> |
|
||||||
<jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/> |
|
||||||
<jvmarg value="-Dfile.encoding=${runtime.encoding}"/> |
|
||||||
<redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/> |
|
||||||
<jvmarg line="${run.jvmargs}"/> |
|
||||||
<classpath> |
|
||||||
<path path="@{classpath}"/> |
|
||||||
</classpath> |
|
||||||
<syspropertyset> |
|
||||||
<propertyref prefix="run-sys-prop."/> |
|
||||||
<mapper from="run-sys-prop.*" to="*" type="glob"/> |
|
||||||
</syspropertyset> |
|
||||||
<customize/> |
|
||||||
</java> |
|
||||||
</sequential> |
|
||||||
</macrodef> |
|
||||||
</target> |
|
||||||
<target name="-init-macrodef-java"> |
|
||||||
<macrodef name="java" uri="http://www.netbeans.org/ns/j2se-project/1"> |
|
||||||
<attribute default="${main.class}" name="classname"/> |
|
||||||
<attribute default="${run.classpath}" name="classpath"/> |
|
||||||
<element name="customize" optional="true"/> |
|
||||||
<sequential> |
|
||||||
<java classname="@{classname}" dir="${work.dir}" fork="true"> |
|
||||||
<jvmarg line="${endorsed.classpath.cmd.line.arg}"/> |
|
||||||
<jvmarg value="-Dfile.encoding=${runtime.encoding}"/> |
|
||||||
<redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/> |
|
||||||
<jvmarg line="${run.jvmargs}"/> |
|
||||||
<classpath> |
|
||||||
<path path="@{classpath}"/> |
|
||||||
</classpath> |
|
||||||
<syspropertyset> |
|
||||||
<propertyref prefix="run-sys-prop."/> |
|
||||||
<mapper from="run-sys-prop.*" to="*" type="glob"/> |
|
||||||
</syspropertyset> |
|
||||||
<customize/> |
|
||||||
</java> |
|
||||||
</sequential> |
|
||||||
</macrodef> |
|
||||||
</target> |
|
||||||
<target name="-init-macrodef-copylibs"> |
|
||||||
<macrodef name="copylibs" uri="http://www.netbeans.org/ns/j2se-project/3"> |
|
||||||
<element name="customize" optional="true"/> |
|
||||||
<sequential> |
|
||||||
<property location="${build.classes.dir}" name="build.classes.dir.resolved"/> |
|
||||||
<pathconvert property="run.classpath.without.build.classes.dir"> |
|
||||||
<path path="${run.classpath}"/> |
|
||||||
<map from="${build.classes.dir.resolved}" to=""/> |
|
||||||
</pathconvert> |
|
||||||
<pathconvert pathsep=" " property="jar.classpath"> |
|
||||||
<path path="${run.classpath.without.build.classes.dir}"/> |
|
||||||
<chainedmapper> |
|
||||||
<flattenmapper/> |
|
||||||
<globmapper from="*" to="lib/*"/> |
|
||||||
</chainedmapper> |
|
||||||
</pathconvert> |
|
||||||
<taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/> |
|
||||||
<copylibs compress="${jar.compress}" index="${jar.index}" jarfile="${dist.jar}" manifest="${manifest.file}" runtimeclasspath="${run.classpath.without.build.classes.dir}"> |
|
||||||
<fileset dir="${build.classes.dir}"/> |
|
||||||
<manifest> |
|
||||||
<attribute name="Class-Path" value="${jar.classpath}"/> |
|
||||||
<customize/> |
|
||||||
</manifest> |
|
||||||
</copylibs> |
|
||||||
</sequential> |
|
||||||
</macrodef> |
|
||||||
</target> |
|
||||||
<target name="-init-presetdef-jar"> |
|
||||||
<presetdef name="jar" uri="http://www.netbeans.org/ns/j2se-project/1"> |
|
||||||
<jar compress="${jar.compress}" index="${jar.index}" jarfile="${dist.jar}"> |
|
||||||
<j2seproject1:fileset dir="${build.classes.dir}"/> |
|
||||||
</jar> |
|
||||||
</presetdef> |
|
||||||
</target> |
|
||||||
<target name="-init-ap-cmdline-properties"> |
|
||||||
<property name="annotation.processing.enabled" value="true"/> |
|
||||||
<property name="annotation.processing.processors.list" value=""/> |
|
||||||
<property name="annotation.processing.processor.options" value=""/> |
|
||||||
<property name="annotation.processing.run.all.processors" value="true"/> |
|
||||||
<property name="javac.processorpath" value="${javac.classpath}"/> |
|
||||||
<property name="javac.test.processorpath" value="${javac.test.classpath}"/> |
|
||||||
<condition property="ap.supported.internal" value="true"> |
|
||||||
<not> |
|
||||||
<matches pattern="1\.[0-5](\..*)?" string="${javac.source}"/> |
|
||||||
</not> |
|
||||||
</condition> |
|
||||||
</target> |
|
||||||
<target depends="-init-ap-cmdline-properties" if="ap.supported.internal" name="-init-ap-cmdline-supported"> |
|
||||||
<condition else="" property="ap.processors.internal" value="-processor ${annotation.processing.processors.list}"> |
|
||||||
<isfalse value="${annotation.processing.run.all.processors}"/> |
|
||||||
</condition> |
|
||||||
<condition else="" property="ap.proc.none.internal" value="-proc:none"> |
|
||||||
<isfalse value="${annotation.processing.enabled}"/> |
|
||||||
</condition> |
|
||||||
</target> |
|
||||||
<target depends="-init-ap-cmdline-properties,-init-ap-cmdline-supported" name="-init-ap-cmdline"> |
|
||||||
<property name="ap.cmd.line.internal" value=""/> |
|
||||||
</target> |
|
||||||
<target depends="-pre-init,-init-private,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-junit,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar,-init-ap-cmdline" name="init"/> |
|
||||||
<!-- |
|
||||||
=================== |
|
||||||
COMPILATION SECTION |
|
||||||
=================== |
|
||||||
--> |
|
||||||
<target name="-deps-jar-init" unless="built-jar.properties"> |
|
||||||
<property location="${build.dir}/built-jar.properties" name="built-jar.properties"/> |
|
||||||
<delete file="${built-jar.properties}" quiet="true"/> |
|
||||||
</target> |
|
||||||
<target if="already.built.jar.${basedir}" name="-warn-already-built-jar"> |
|
||||||
<echo level="warn" message="Cycle detected: JME3TestsTemplate was already built"/> |
|
||||||
</target> |
|
||||||
<target depends="init,-deps-jar-init" name="deps-jar" unless="no.deps"> |
|
||||||
<mkdir dir="${build.dir}"/> |
|
||||||
<touch file="${built-jar.properties}" verbose="false"/> |
|
||||||
<property file="${built-jar.properties}" prefix="already.built.jar."/> |
|
||||||
<antcall target="-warn-already-built-jar"/> |
|
||||||
<propertyfile file="${built-jar.properties}"> |
|
||||||
<entry key="${basedir}" value=""/> |
|
||||||
</propertyfile> |
|
||||||
</target> |
|
||||||
<target depends="init,-check-automatic-build,-clean-after-automatic-build" name="-verify-automatic-build"/> |
|
||||||
<target depends="init" name="-check-automatic-build"> |
|
||||||
<available file="${build.classes.dir}/.netbeans_automatic_build" property="netbeans.automatic.build"/> |
|
||||||
</target> |
|
||||||
<target depends="init" if="netbeans.automatic.build" name="-clean-after-automatic-build"> |
|
||||||
<antcall target="clean"/> |
|
||||||
</target> |
|
||||||
<target depends="init,deps-jar" name="-pre-pre-compile"> |
|
||||||
<mkdir dir="${build.classes.dir}"/> |
|
||||||
</target> |
|
||||||
<target name="-pre-compile"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target if="do.depend.true" name="-compile-depend"> |
|
||||||
<pathconvert property="build.generated.subdirs"> |
|
||||||
<dirset dir="${build.generated.sources.dir}" erroronmissingdir="false"> |
|
||||||
<include name="*"/> |
|
||||||
</dirset> |
|
||||||
</pathconvert> |
|
||||||
<j2seproject3:depend srcdir="${src.dir}:${build.generated.subdirs}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,deps-jar,-pre-pre-compile,-pre-compile, -copy-persistence-xml,-compile-depend" if="have.sources" name="-do-compile"> |
|
||||||
<j2seproject3:javac gensrcdir="${build.generated.sources.dir}"/> |
|
||||||
<copy todir="${build.classes.dir}"> |
|
||||||
<fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/> |
|
||||||
</copy> |
|
||||||
</target> |
|
||||||
<target if="has.persistence.xml" name="-copy-persistence-xml"> |
|
||||||
<mkdir dir="${build.classes.dir}/META-INF"/> |
|
||||||
<copy todir="${build.classes.dir}/META-INF"> |
|
||||||
<fileset dir="${meta.inf.dir}" includes="persistence.xml"/> |
|
||||||
</copy> |
|
||||||
</target> |
|
||||||
<target name="-post-compile"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target depends="init,deps-jar,-verify-automatic-build,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project." name="compile"/> |
|
||||||
<target name="-pre-compile-single"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single"> |
|
||||||
<fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail> |
|
||||||
<j2seproject3:force-recompile/> |
|
||||||
<j2seproject3:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}" sourcepath="${src.dir}"/> |
|
||||||
</target> |
|
||||||
<target name="-post-compile-single"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target depends="init,deps-jar,-verify-automatic-build,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single" name="compile-single"/> |
|
||||||
<!-- |
|
||||||
==================== |
|
||||||
JAR BUILDING SECTION |
|
||||||
==================== |
|
||||||
--> |
|
||||||
<target depends="init" name="-pre-pre-jar"> |
|
||||||
<dirname file="${dist.jar}" property="dist.jar.dir"/> |
|
||||||
<mkdir dir="${dist.jar.dir}"/> |
|
||||||
</target> |
|
||||||
<target name="-pre-jar"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-pre-pre-jar,-pre-jar" if="do.archive" name="-do-jar-without-manifest" unless="manifest.available"> |
|
||||||
<j2seproject1:jar/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-pre-pre-jar,-pre-jar" if="do.archive+manifest.available" name="-do-jar-with-manifest" unless="manifest.available+main.class"> |
|
||||||
<j2seproject1:jar manifest="${manifest.file}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-pre-pre-jar,-pre-jar" if="do.archive+manifest.available+main.class" name="-do-jar-with-mainclass" unless="manifest.available+main.class+mkdist.available"> |
|
||||||
<j2seproject1:jar manifest="${manifest.file}"> |
|
||||||
<j2seproject1:manifest> |
|
||||||
<j2seproject1:attribute name="Main-Class" value="${main.class}"/> |
|
||||||
</j2seproject1:manifest> |
|
||||||
</j2seproject1:jar> |
|
||||||
<echo>To run this application from the command line without Ant, try:</echo> |
|
||||||
<property location="${build.classes.dir}" name="build.classes.dir.resolved"/> |
|
||||||
<property location="${dist.jar}" name="dist.jar.resolved"/> |
|
||||||
<pathconvert property="run.classpath.with.dist.jar"> |
|
||||||
<path path="${run.classpath}"/> |
|
||||||
<map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/> |
|
||||||
</pathconvert> |
|
||||||
<echo>java -cp "${run.classpath.with.dist.jar}" ${main.class}</echo> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-pre-pre-jar,-pre-jar,-init-macrodef-copylibs" if="do.archive+manifest.available+main.class+mkdist.available+splashscreen.available" name="-do-jar-with-libraries-and-splashscreen"> |
|
||||||
<basename file="${application.splash}" property="splashscreen.basename"/> |
|
||||||
<mkdir dir="${build.classes.dir}/META-INF"/> |
|
||||||
<copy failonerror="false" file="${application.splash}" todir="${build.classes.dir}/META-INF"/> |
|
||||||
<j2seproject3:copylibs> |
|
||||||
<customize> |
|
||||||
<attribute name="Main-Class" value="${main.class}"/> |
|
||||||
<attribute name="SplashScreen-Image" value="META-INF/${splashscreen.basename}"/> |
|
||||||
</customize> |
|
||||||
</j2seproject3:copylibs> |
|
||||||
<echo>To run this application from the command line without Ant, try:</echo> |
|
||||||
<property location="${dist.jar}" name="dist.jar.resolved"/> |
|
||||||
<echo>java -jar "${dist.jar.resolved}"</echo> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-pre-pre-jar,-pre-jar,-init-macrodef-copylibs" if="do.archive+manifest.available+main.class+mkdist.available" name="-do-jar-with-libraries" unless="splashscreen.available"> |
|
||||||
<j2seproject3:copylibs> |
|
||||||
<customize> |
|
||||||
<attribute name="Main-Class" value="${main.class}"/> |
|
||||||
</customize> |
|
||||||
</j2seproject3:copylibs> |
|
||||||
<echo>To run this application from the command line without Ant, try:</echo> |
|
||||||
<property location="${dist.jar}" name="dist.jar.resolved"/> |
|
||||||
<echo>java -jar "${dist.jar.resolved}"</echo> |
|
||||||
</target> |
|
||||||
<target name="-post-jar"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-pre-jar,-do-jar-with-manifest,-do-jar-without-manifest,-do-jar-with-mainclass,-do-jar-with-libraries-and-splashscreen,-do-jar-with-libraries,-post-jar" description="Build JAR." name="jar"/> |
|
||||||
<!-- |
|
||||||
================= |
|
||||||
EXECUTION SECTION |
|
||||||
================= |
|
||||||
--> |
|
||||||
<target depends="init,compile" description="Run a main class." name="run"> |
|
||||||
<j2seproject1:java> |
|
||||||
<customize> |
|
||||||
<arg line="${application.args}"/> |
|
||||||
</customize> |
|
||||||
</j2seproject1:java> |
|
||||||
</target> |
|
||||||
<target name="-do-not-recompile"> |
|
||||||
<property name="javac.includes.binary" value=""/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-single" name="run-single"> |
|
||||||
<fail unless="run.class">Must select one file in the IDE or set run.class</fail> |
|
||||||
<j2seproject1:java classname="${run.class}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-test-single" name="run-test-with-main"> |
|
||||||
<fail unless="run.class">Must select one file in the IDE or set run.class</fail> |
|
||||||
<j2seproject1:java classname="${run.class}" classpath="${run.test.classpath}"/> |
|
||||||
</target> |
|
||||||
<!-- |
|
||||||
================= |
|
||||||
DEBUGGING SECTION |
|
||||||
================= |
|
||||||
--> |
|
||||||
<target depends="init" if="netbeans.home" name="-debug-start-debugger"> |
|
||||||
<j2seproject1:nbjpdastart name="${debug.class}"/> |
|
||||||
</target> |
|
||||||
<target depends="init" if="netbeans.home" name="-debug-start-debugger-main-test"> |
|
||||||
<j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${debug.class}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile" name="-debug-start-debuggee"> |
|
||||||
<j2seproject3:debug> |
|
||||||
<customize> |
|
||||||
<arg line="${application.args}"/> |
|
||||||
</customize> |
|
||||||
</j2seproject3:debug> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-debug-start-debugger,-debug-start-debuggee" description="Debug project in IDE." if="netbeans.home" name="debug"/> |
|
||||||
<target depends="init" if="netbeans.home" name="-debug-start-debugger-stepinto"> |
|
||||||
<j2seproject1:nbjpdastart stopclassname="${main.class}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-debug-start-debugger-stepinto,-debug-start-debuggee" if="netbeans.home" name="debug-stepinto"/> |
|
||||||
<target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-single"> |
|
||||||
<fail unless="debug.class">Must select one file in the IDE or set debug.class</fail> |
|
||||||
<j2seproject3:debug classname="${debug.class}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-single" if="netbeans.home" name="debug-single"/> |
|
||||||
<target depends="init,compile-test-single" if="netbeans.home" name="-debug-start-debuggee-main-test"> |
|
||||||
<fail unless="debug.class">Must select one file in the IDE or set debug.class</fail> |
|
||||||
<j2seproject3:debug classname="${debug.class}" classpath="${debug.test.classpath}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-test-single,-debug-start-debugger-main-test,-debug-start-debuggee-main-test" if="netbeans.home" name="debug-test-with-main"/> |
|
||||||
<target depends="init" name="-pre-debug-fix"> |
|
||||||
<fail unless="fix.includes">Must set fix.includes</fail> |
|
||||||
<property name="javac.includes" value="${fix.includes}.java"/> |
|
||||||
</target> |
|
||||||
<target depends="init,-pre-debug-fix,compile-single" if="netbeans.home" name="-do-debug-fix"> |
|
||||||
<j2seproject1:nbjpdareload/> |
|
||||||
</target> |
|
||||||
<target depends="init,-pre-debug-fix,-do-debug-fix" if="netbeans.home" name="debug-fix"/> |
|
||||||
<!-- |
|
||||||
=============== |
|
||||||
JAVADOC SECTION |
|
||||||
=============== |
|
||||||
--> |
|
||||||
<target depends="init" if="have.sources" name="-javadoc-build"> |
|
||||||
<mkdir dir="${dist.javadoc.dir}"/> |
|
||||||
<javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}"> |
|
||||||
<classpath> |
|
||||||
<path path="${javac.classpath}"/> |
|
||||||
</classpath> |
|
||||||
<fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}"> |
|
||||||
<filename name="**/*.java"/> |
|
||||||
</fileset> |
|
||||||
<fileset dir="${build.generated.sources.dir}" erroronmissingdir="false"> |
|
||||||
<include name="**/*.java"/> |
|
||||||
</fileset> |
|
||||||
</javadoc> |
|
||||||
<copy todir="${dist.javadoc.dir}"> |
|
||||||
<fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}"> |
|
||||||
<filename name="**/doc-files/**"/> |
|
||||||
</fileset> |
|
||||||
<fileset dir="${build.generated.sources.dir}" erroronmissingdir="false"> |
|
||||||
<include name="**/doc-files/**"/> |
|
||||||
</fileset> |
|
||||||
</copy> |
|
||||||
</target> |
|
||||||
<target depends="init,-javadoc-build" if="netbeans.home" name="-javadoc-browse" unless="no.javadoc.preview"> |
|
||||||
<nbbrowse file="${dist.javadoc.dir}/index.html"/> |
|
||||||
</target> |
|
||||||
<target depends="init,-javadoc-build,-javadoc-browse" description="Build Javadoc." name="javadoc"/> |
|
||||||
<!-- |
|
||||||
========================= |
|
||||||
JUNIT COMPILATION SECTION |
|
||||||
========================= |
|
||||||
--> |
|
||||||
<target depends="init,compile" if="have.tests" name="-pre-pre-compile-test"> |
|
||||||
<mkdir dir="${build.test.classes.dir}"/> |
|
||||||
</target> |
|
||||||
<target name="-pre-compile-test"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target if="do.depend.true" name="-compile-test-depend"> |
|
||||||
<j2seproject3:depend classpath="${javac.test.classpath}" destdir="${build.test.classes.dir}" srcdir=""/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-compile-test-depend" if="have.tests" name="-do-compile-test"> |
|
||||||
<j2seproject3:javac apgeneratedsrcdir="${build.test.classes.dir}" classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" processorpath="${javac.test.processorpath}" srcdir=""/> |
|
||||||
<copy todir="${build.test.classes.dir}"/> |
|
||||||
</target> |
|
||||||
<target name="-post-compile-test"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test" name="compile-test"/> |
|
||||||
<target name="-pre-compile-test-single"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single" if="have.tests" name="-do-compile-test-single"> |
|
||||||
<fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail> |
|
||||||
<j2seproject3:force-recompile destdir="${build.test.classes.dir}"/> |
|
||||||
<j2seproject3:javac apgeneratedsrcdir="${build.test.classes.dir}" classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" excludes="" includes="${javac.includes}" processorpath="${javac.test.processorpath}" sourcepath="" srcdir=""/> |
|
||||||
<copy todir="${build.test.classes.dir}"/> |
|
||||||
</target> |
|
||||||
<target name="-post-compile-test-single"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single" name="compile-test-single"/> |
|
||||||
<!-- |
|
||||||
======================= |
|
||||||
JUNIT EXECUTION SECTION |
|
||||||
======================= |
|
||||||
--> |
|
||||||
<target depends="init" if="have.tests" name="-pre-test-run"> |
|
||||||
<mkdir dir="${build.test.results.dir}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run"> |
|
||||||
<j2seproject3:junit testincludes="**/*Test.java"/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run"> |
|
||||||
<fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail> |
|
||||||
</target> |
|
||||||
<target depends="init" if="have.tests" name="test-report"/> |
|
||||||
<target depends="init" if="netbeans.home+have.tests" name="-test-browse"/> |
|
||||||
<target depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests." name="test"/> |
|
||||||
<target depends="init" if="have.tests" name="-pre-test-run-single"> |
|
||||||
<mkdir dir="${build.test.results.dir}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single"> |
|
||||||
<fail unless="test.includes">Must select some files in the IDE or set test.includes</fail> |
|
||||||
<j2seproject3:junit excludes="" includes="${test.includes}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single"> |
|
||||||
<fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test." name="test-single"/> |
|
||||||
<!-- |
|
||||||
======================= |
|
||||||
JUNIT DEBUGGING SECTION |
|
||||||
======================= |
|
||||||
--> |
|
||||||
<target depends="init,compile-test" if="have.tests" name="-debug-start-debuggee-test"> |
|
||||||
<fail unless="test.class">Must select one file in the IDE or set test.class</fail> |
|
||||||
<property location="${build.test.results.dir}/TEST-${test.class}.xml" name="test.report.file"/> |
|
||||||
<delete file="${test.report.file}"/> |
|
||||||
<mkdir dir="${build.test.results.dir}"/> |
|
||||||
<j2seproject3:debug classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner" classpath="${ant.home}/lib/ant.jar:${ant.home}/lib/ant-junit.jar:${debug.test.classpath}"> |
|
||||||
<customize> |
|
||||||
<syspropertyset> |
|
||||||
<propertyref prefix="test-sys-prop."/> |
|
||||||
<mapper from="test-sys-prop.*" to="*" type="glob"/> |
|
||||||
</syspropertyset> |
|
||||||
<arg value="${test.class}"/> |
|
||||||
<arg value="showoutput=true"/> |
|
||||||
<arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.BriefJUnitResultFormatter"/> |
|
||||||
<arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,${test.report.file}"/> |
|
||||||
</customize> |
|
||||||
</j2seproject3:debug> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test"> |
|
||||||
<j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/> |
|
||||||
<target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test"> |
|
||||||
<j2seproject1:nbjpdareload dir="${build.test.classes.dir}"/> |
|
||||||
</target> |
|
||||||
<target depends="init,-pre-debug-fix,-do-debug-fix-test" if="netbeans.home" name="debug-fix-test"/> |
|
||||||
<!-- |
|
||||||
========================= |
|
||||||
APPLET EXECUTION SECTION |
|
||||||
========================= |
|
||||||
--> |
|
||||||
<target depends="init,compile-single" name="run-applet"> |
|
||||||
<fail unless="applet.url">Must select one file in the IDE or set applet.url</fail> |
|
||||||
<j2seproject1:java classname="sun.applet.AppletViewer"> |
|
||||||
<customize> |
|
||||||
<arg value="${applet.url}"/> |
|
||||||
</customize> |
|
||||||
</j2seproject1:java> |
|
||||||
</target> |
|
||||||
<!-- |
|
||||||
========================= |
|
||||||
APPLET DEBUGGING SECTION |
|
||||||
========================= |
|
||||||
--> |
|
||||||
<target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-applet"> |
|
||||||
<fail unless="applet.url">Must select one file in the IDE or set applet.url</fail> |
|
||||||
<j2seproject3:debug classname="sun.applet.AppletViewer"> |
|
||||||
<customize> |
|
||||||
<arg value="${applet.url}"/> |
|
||||||
</customize> |
|
||||||
</j2seproject3:debug> |
|
||||||
</target> |
|
||||||
<target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-applet" if="netbeans.home" name="debug-applet"/> |
|
||||||
<!-- |
|
||||||
=============== |
|
||||||
CLEANUP SECTION |
|
||||||
=============== |
|
||||||
--> |
|
||||||
<target name="-deps-clean-init" unless="built-clean.properties"> |
|
||||||
<property location="${build.dir}/built-clean.properties" name="built-clean.properties"/> |
|
||||||
<delete file="${built-clean.properties}" quiet="true"/> |
|
||||||
</target> |
|
||||||
<target if="already.built.clean.${basedir}" name="-warn-already-built-clean"> |
|
||||||
<echo level="warn" message="Cycle detected: JME3TestsTemplate was already built"/> |
|
||||||
</target> |
|
||||||
<target depends="init,-deps-clean-init" name="deps-clean" unless="no.deps"> |
|
||||||
<mkdir dir="${build.dir}"/> |
|
||||||
<touch file="${built-clean.properties}" verbose="false"/> |
|
||||||
<property file="${built-clean.properties}" prefix="already.built.clean."/> |
|
||||||
<antcall target="-warn-already-built-clean"/> |
|
||||||
<propertyfile file="${built-clean.properties}"> |
|
||||||
<entry key="${basedir}" value=""/> |
|
||||||
</propertyfile> |
|
||||||
</target> |
|
||||||
<target depends="init" name="-do-clean"> |
|
||||||
<delete dir="${build.dir}"/> |
|
||||||
<delete dir="${dist.dir}" followsymlinks="false" includeemptydirs="true"/> |
|
||||||
</target> |
|
||||||
<target name="-post-clean"> |
|
||||||
<!-- Empty placeholder for easier customization. --> |
|
||||||
<!-- You can override this target in the ../build.xml file. --> |
|
||||||
</target> |
|
||||||
<target depends="init,deps-clean,-do-clean,-post-clean" description="Clean build products." name="clean"/> |
|
||||||
<target name="-check-call-dep"> |
|
||||||
<property file="${call.built.properties}" prefix="already.built."/> |
|
||||||
<condition property="should.call.dep"> |
|
||||||
<not> |
|
||||||
<isset property="already.built.${call.subproject}"/> |
|
||||||
</not> |
|
||||||
</condition> |
|
||||||
</target> |
|
||||||
<target depends="-check-call-dep" if="should.call.dep" name="-maybe-call-dep"> |
|
||||||
<ant antfile="${call.script}" inheritall="false" target="${call.target}"> |
|
||||||
<propertyset> |
|
||||||
<propertyref prefix="transfer."/> |
|
||||||
<mapper from="transfer.*" to="*" type="glob"/> |
|
||||||
</propertyset> |
|
||||||
</ant> |
|
||||||
</target> |
|
||||||
</project> |
|
@ -1,8 +0,0 @@ |
|||||||
build.xml.data.CRC32=0f706f4a |
|
||||||
build.xml.script.CRC32=82b8b23d |
|
||||||
build.xml.stylesheet.CRC32=8064a381@1.75.2.48 |
|
||||||
# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml. |
|
||||||
# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you. |
|
||||||
nbproject/build-impl.xml.data.CRC32=0f706f4a |
|
||||||
nbproject/build-impl.xml.script.CRC32=46d1a69a |
|
||||||
nbproject/build-impl.xml.stylesheet.CRC32=0ae3a408@1.44.1.45 |
|
@ -1,83 +0,0 @@ |
|||||||
application.title=JME3TestsTemplate |
|
||||||
application.vendor=jMonkeyEngine |
|
||||||
build.classes.dir=${build.dir}/classes |
|
||||||
build.classes.excludes=**/*.java,**/*.form |
|
||||||
# This directory is removed when the project is cleaned: |
|
||||||
build.dir=build |
|
||||||
build.generated.dir=${build.dir}/generated |
|
||||||
build.generated.sources.dir=${build.dir}/generated-sources |
|
||||||
# Only compile against the classpath explicitly listed here: |
|
||||||
build.sysclasspath=ignore |
|
||||||
build.test.classes.dir=${build.dir}/test/classes |
|
||||||
build.test.results.dir=${build.dir}/test/results |
|
||||||
# Uncomment to specify the preferred debugger connection transport: |
|
||||||
#debug.transport=dt_socket |
|
||||||
debug.classpath=\ |
|
||||||
${run.classpath} |
|
||||||
debug.test.classpath=\ |
|
||||||
${run.test.classpath} |
|
||||||
# This directory is removed when the project is cleaned: |
|
||||||
dist.dir=dist |
|
||||||
dist.jar=${dist.dir}/JME3TestsTemplate.jar |
|
||||||
dist.javadoc.dir=${dist.dir}/javadoc |
|
||||||
endorsed.classpath= |
|
||||||
excludes= |
|
||||||
includes=** |
|
||||||
jar.compress=false |
|
||||||
javac.classpath=\ |
|
||||||
${libs.jme3-jogg.classpath}:\ |
|
||||||
${libs.jme3-blender.classpath}:\ |
|
||||||
${libs.jme3-networking.classpath}:\ |
|
||||||
${libs.jme3-plugins.classpath}:\ |
|
||||||
${libs.jme3-core.classpath}:\ |
|
||||||
${libs.jme3-desktop.classpath}:\ |
|
||||||
${libs.jme3-lwjgl.classpath}:\ |
|
||||||
${libs.jme3-niftygui.classpath}:\ |
|
||||||
${libs.jme3-effects.classpath}:\ |
|
||||||
${libs.jme3-terrain.classpath}:\ |
|
||||||
${libs.jme3-jbullet.classpath}:\ |
|
||||||
${libs.jme3-test-data.classpath} |
|
||||||
# Space-separated list of extra javac options |
|
||||||
javac.compilerargs= |
|
||||||
javac.deprecation=false |
|
||||||
javac.source=1.6 |
|
||||||
javac.target=1.6 |
|
||||||
javac.test.classpath=\ |
|
||||||
${javac.classpath}:\ |
|
||||||
${build.classes.dir} |
|
||||||
javadoc.additionalparam= |
|
||||||
javadoc.author=false |
|
||||||
javadoc.encoding=${source.encoding} |
|
||||||
javadoc.noindex=false |
|
||||||
javadoc.nonavbar=false |
|
||||||
javadoc.notree=false |
|
||||||
javadoc.private=false |
|
||||||
javadoc.splitindex=true |
|
||||||
javadoc.use=true |
|
||||||
javadoc.version=false |
|
||||||
javadoc.windowtitle= |
|
||||||
jaxbwiz.endorsed.dirs="${netbeans.home}/../ide12/modules/ext/jaxb/api" |
|
||||||
jnlp.applet.class=jme3test.awt.TestApplet |
|
||||||
jnlp.applet.height=300 |
|
||||||
jnlp.applet.width=300 |
|
||||||
jnlp.codebase.type=local |
|
||||||
jnlp.descriptor=application |
|
||||||
jnlp.enabled=false |
|
||||||
jnlp.offline-allowed=false |
|
||||||
jnlp.signed=false |
|
||||||
main.class=jme3test.TestChooser |
|
||||||
manifest.file=manifest.mf |
|
||||||
meta.inf.dir=${src.dir}/META-INF |
|
||||||
platform.active=default_platform |
|
||||||
run.classpath=\ |
|
||||||
${javac.classpath}:\ |
|
||||||
${build.classes.dir} |
|
||||||
# Space-separated list of JVM arguments used when running the project |
|
||||||
# (you may also define separate properties like run-sys-prop.name=value instead of -Dname=value |
|
||||||
# or test-sys-prop.name=value to set system properties for unit tests): |
|
||||||
run.jvmargs= |
|
||||||
run.test.classpath=\ |
|
||||||
${javac.test.classpath}:\ |
|
||||||
${build.test.classes.dir} |
|
||||||
source.encoding=UTF-8 |
|
||||||
src.dir=src |
|
@ -1,13 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<project xmlns="http://www.netbeans.org/ns/project/1"> |
|
||||||
<type>org.netbeans.modules.java.j2seproject</type> |
|
||||||
<configuration> |
|
||||||
<data xmlns="http://www.netbeans.org/ns/j2se-project/3"> |
|
||||||
<name>JME3TestsTemplate</name> |
|
||||||
<source-roots> |
|
||||||
<root id="src.dir" name="JME3 Examples"/> |
|
||||||
</source-roots> |
|
||||||
<test-roots/> |
|
||||||
</data> |
|
||||||
</configuration> |
|
||||||
</project> |
|
@ -1 +0,0 @@ |
|||||||
X-Comment: Created with jMonkeyPlatform |
|
@ -1,76 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<!-- You may freely edit this file. See commented blocks below for --> |
|
||||||
<!-- some examples of how to customize the build. --> |
|
||||||
<!-- (If you delete it and reopen the project it will be recreated.) --> |
|
||||||
<!-- By default, only the Clean and Build commands use this build script. --> |
|
||||||
<!-- Commands such as Run, Debug, and Test only use this build script if --> |
|
||||||
<!-- the Compile on Save feature is turned off for the project. --> |
|
||||||
<!-- You can turn off the Compile on Save (or Deploy on Save) setting --> |
|
||||||
<!-- in the project's Project Properties dialog box.--> |
|
||||||
<project name="BasicGameTemplate" default="default" basedir="."> |
|
||||||
<description>Builds, tests, and runs the project BasicGameTemplate.</description> |
|
||||||
<import file="nbproject/build-impl.xml"/> |
|
||||||
|
|
||||||
<!-- |
|
||||||
|
|
||||||
There exist several targets which are by default empty and which can be |
|
||||||
used for execution of your tasks. These targets are usually executed |
|
||||||
before and after some main targets. They are: |
|
||||||
|
|
||||||
-pre-init: called before initialization of project properties |
|
||||||
-post-init: called after initialization of project properties |
|
||||||
-pre-compile: called before javac compilation |
|
||||||
-post-compile: called after javac compilation |
|
||||||
-pre-compile-single: called before javac compilation of single file |
|
||||||
-post-compile-single: called after javac compilation of single file |
|
||||||
-pre-compile-test: called before javac compilation of JUnit tests |
|
||||||
-post-compile-test: called after javac compilation of JUnit tests |
|
||||||
-pre-compile-test-single: called before javac compilation of single JUnit test |
|
||||||
-post-compile-test-single: called after javac compilation of single JUunit test |
|
||||||
-pre-jar: called before JAR building |
|
||||||
-post-jar: called after JAR building |
|
||||||
-post-clean: called after cleaning build products |
|
||||||
|
|
||||||
(Targets beginning with '-' are not intended to be called on their own.) |
|
||||||
|
|
||||||
Example of inserting an obfuscator after compilation could look like this: |
|
||||||
|
|
||||||
<target name="-post-compile"> |
|
||||||
<obfuscate> |
|
||||||
<fileset dir="${build.classes.dir}"/> |
|
||||||
</obfuscate> |
|
||||||
</target> |
|
||||||
|
|
||||||
For list of available properties check the imported |
|
||||||
nbproject/build-impl.xml file. |
|
||||||
|
|
||||||
|
|
||||||
Another way to customize the build is by overriding existing main targets. |
|
||||||
The targets of interest are: |
|
||||||
|
|
||||||
-init-macrodef-javac: defines macro for javac compilation |
|
||||||
-init-macrodef-junit: defines macro for junit execution |
|
||||||
-init-macrodef-debug: defines macro for class debugging |
|
||||||
-init-macrodef-java: defines macro for class execution |
|
||||||
-do-jar-with-manifest: JAR building (if you are using a manifest) |
|
||||||
-do-jar-without-manifest: JAR building (if you are not using a manifest) |
|
||||||
run: execution of project |
|
||||||
-javadoc-build: Javadoc generation |
|
||||||
test-report: JUnit report generation |
|
||||||
|
|
||||||
An example of overriding the target for project execution could look like this: |
|
||||||
|
|
||||||
<target name="run" depends="BasicGameTemplate-impl.jar"> |
|
||||||
<exec dir="bin" executable="launcher.exe"> |
|
||||||
<arg file="${dist.jar}"/> |
|
||||||
</exec> |
|
||||||
</target> |
|
||||||
|
|
||||||
Notice that the overridden target depends on the jar target and not only on |
|
||||||
the compile target as the regular run target does. Again, for a list of available |
|
||||||
properties which you can use, check the target you are overriding in the |
|
||||||
nbproject/build-impl.xml file. |
|
||||||
|
|
||||||
--> |
|
||||||
|
|
||||||
</project> |
|
@ -1,22 +0,0 @@ |
|||||||
<jnlp spec="1.0+" codebase="${jnlp.codebase}" href="launch.jnlp"> |
|
||||||
<information> |
|
||||||
<title>${APPLICATION.TITLE}</title> |
|
||||||
<vendor>${APPLICATION.VENDOR}</vendor> |
|
||||||
<homepage href="${APPLICATION.HOMEPAGE}"/> |
|
||||||
<description>${APPLICATION.DESC}</description> |
|
||||||
<description kind="short">${APPLICATION.DESC.SHORT}</description> |
|
||||||
<!--${JNLP.ICONS}--> |
|
||||||
<!--${JNLP.OFFLINE.ALLOWED}--> |
|
||||||
</information> |
|
||||||
<!--${JNLP.SECURITY}--> |
|
||||||
<resources> |
|
||||||
<!--${JNLP.RESOURCES.RUNTIME}--> |
|
||||||
<!--${JNLP.RESOURCES.MAIN.JAR}--> |
|
||||||
<!--${JNLP.RESOURCES.JARS}--> |
|
||||||
<jar href='lib/assets.jar'/> |
|
||||||
<!--${JNLP.RESOURCES.EXTENSIONS}--> |
|
||||||
</resources> |
|
||||||
<application-desc main-class="${jnlp.main.class}"> |
|
||||||
<!--${JNLP.APPLICATION.ARGS}--> |
|
||||||
</application-desc> |
|
||||||
</jnlp> |
|
@ -1,15 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="1" android:versionName="1.0" package="com.jmonkeyengine.tests"> |
|
||||||
<application android:label="@string/app_name"> |
|
||||||
<activity android:label="@string/app_name" android:name="MainActivity" android:launchMode="singleTask"> |
|
||||||
<intent-filter> |
|
||||||
<action android:name="android.intent.action.MAIN"/> |
|
||||||
<category android:name="android.intent.category.LAUNCHER"/> |
|
||||||
</intent-filter> |
|
||||||
</activity> |
|
||||||
<activity android:label="@string/app_name" android:name="TestsHarness" android:launchMode="singleTask" android:screenOrientation="landscape"> |
|
||||||
</activity> |
|
||||||
</application> |
|
||||||
<uses-sdk android:minSdkVersion="8"/> |
|
||||||
<supports-screens android:anyDensity="true" android:largeScreens="true" android:normalScreens="true" android:smallScreens="true"/> |
|
||||||
</manifest> |
|
@ -1,17 +0,0 @@ |
|||||||
# This file is used to override default values used by the Ant build system. |
|
||||||
# |
|
||||||
# This file must be checked into Version Control Systems, as it is |
|
||||||
# integral to the build system of your project. |
|
||||||
|
|
||||||
# This file is only used by the Ant script. |
|
||||||
|
|
||||||
# You can use this to override default values such as |
|
||||||
# 'source.dir' for the location of your java source folder and |
|
||||||
# 'out.dir' for the location of your output folder. |
|
||||||
|
|
||||||
# You can also use it define how the release builds are signed by declaring |
|
||||||
# the following properties: |
|
||||||
# 'key.store' for the location of your keystore and |
|
||||||
# 'key.alias' for the name of the key to use. |
|
||||||
# The password will be asked during the build when you use the 'release' target. |
|
||||||
|
|
@ -1,92 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<project name="jMonkeyEngine Test Applications" default="help"> |
|
||||||
|
|
||||||
<!-- The local.properties file is created and updated by the 'android' tool. |
|
||||||
It contains the path to the SDK. It should *NOT* be checked into |
|
||||||
Version Control Systems. --> |
|
||||||
<property file="local.properties" /> |
|
||||||
|
|
||||||
<!-- The ant.properties file can be created by you. It is only edited by the |
|
||||||
'android' tool to add properties to it. |
|
||||||
This is the place to change some Ant specific build properties. |
|
||||||
Here are some properties you may want to change/update: |
|
||||||
|
|
||||||
source.dir |
|
||||||
The name of the source directory. Default is 'src'. |
|
||||||
out.dir |
|
||||||
The name of the output directory. Default is 'bin'. |
|
||||||
|
|
||||||
For other overridable properties, look at the beginning of the rules |
|
||||||
files in the SDK, at tools/ant/build.xml |
|
||||||
|
|
||||||
Properties related to the SDK location or the project target should |
|
||||||
be updated using the 'android' tool with the 'update' action. |
|
||||||
|
|
||||||
This file is an integral part of the build system for your |
|
||||||
application and should be checked into Version Control Systems. |
|
||||||
|
|
||||||
--> |
|
||||||
<property file="ant.properties" /> |
|
||||||
|
|
||||||
<!-- if sdk.dir was not set from one of the property file, then |
|
||||||
get it from the ANDROID_HOME env var. |
|
||||||
This must be done before we load project.properties since |
|
||||||
the proguard config can use sdk.dir --> |
|
||||||
<property environment="env" /> |
|
||||||
<condition property="sdk.dir" value="${env.ANDROID_HOME}"> |
|
||||||
<isset property="env.ANDROID_HOME" /> |
|
||||||
</condition> |
|
||||||
|
|
||||||
<!-- The project.properties file is created and updated by the 'android' |
|
||||||
tool, as well as ADT. |
|
||||||
|
|
||||||
This contains project specific properties such as project target, and library |
|
||||||
dependencies. Lower level build properties are stored in ant.properties |
|
||||||
(or in .classpath for Eclipse projects). |
|
||||||
|
|
||||||
This file is an integral part of the build system for your |
|
||||||
application and should be checked into Version Control Systems. --> |
|
||||||
<loadproperties srcFile="project.properties" /> |
|
||||||
|
|
||||||
<!-- quick check on sdk.dir --> |
|
||||||
<fail |
|
||||||
message="sdk.dir is missing. Make sure to generate local.properties using 'android update project' or to inject it through the ANDROID_HOME environment variable." |
|
||||||
unless="sdk.dir" |
|
||||||
/> |
|
||||||
|
|
||||||
<!-- |
|
||||||
Import per project custom build rules if present at the root of the project. |
|
||||||
This is the place to put custom intermediary targets such as: |
|
||||||
-pre-build |
|
||||||
-pre-compile |
|
||||||
-post-compile (This is typically used for code obfuscation. |
|
||||||
Compiled code location: ${out.classes.absolute.dir} |
|
||||||
If this is not done in place, override ${out.dex.input.absolute.dir}) |
|
||||||
-post-package |
|
||||||
-post-build |
|
||||||
-pre-clean |
|
||||||
--> |
|
||||||
<import file="custom_rules.xml" optional="true" /> |
|
||||||
|
|
||||||
<!-- Import the actual build file. |
|
||||||
|
|
||||||
To customize existing targets, there are two options: |
|
||||||
- Customize only one target: |
|
||||||
- copy/paste the target into this file, *before* the |
|
||||||
<import> task. |
|
||||||
- customize it to your needs. |
|
||||||
- Customize the whole content of build.xml |
|
||||||
- copy/paste the content of the rules files (minus the top node) |
|
||||||
into this file, replacing the <import> task. |
|
||||||
- customize to your needs. |
|
||||||
|
|
||||||
*********************** |
|
||||||
****** IMPORTANT ****** |
|
||||||
*********************** |
|
||||||
In all cases you must update the value of version-tag below to read 'custom' instead of an integer, |
|
||||||
in order to avoid having your file be overridden by tools such as "android update project" |
|
||||||
--> |
|
||||||
<!-- version-tag: 1 --> |
|
||||||
<import file="${sdk.dir}/tools/ant/build.xml" /> |
|
||||||
|
|
||||||
</project> |
|
@ -1,20 +0,0 @@ |
|||||||
# To enable ProGuard in your project, edit project.properties |
|
||||||
# to define the proguard.config property as described in that file. |
|
||||||
# |
|
||||||
# Add project specific ProGuard rules here. |
|
||||||
# By default, the flags in this file are appended to flags specified |
|
||||||
# in ${sdk.dir}/tools/proguard/proguard-android.txt |
|
||||||
# You can edit the include path and order by changing the ProGuard |
|
||||||
# include property in project.properties. |
|
||||||
# |
|
||||||
# For more details, see |
|
||||||
# http://developer.android.com/guide/developing/tools/proguard.html |
|
||||||
|
|
||||||
# Add any project specific keep options here: |
|
||||||
|
|
||||||
# If your project uses WebView with JS, uncomment the following |
|
||||||
# and specify the fully qualified class name to the JavaScript interface |
|
||||||
# class: |
|
||||||
#-keepclassmembers class fqcn.of.javascript.interface.for.webview { |
|
||||||
# public *; |
|
||||||
#} |
|
@ -1,14 +0,0 @@ |
|||||||
# This file is automatically generated by Android Tools. |
|
||||||
# Do not modify this file -- YOUR CHANGES WILL BE ERASED! |
|
||||||
# |
|
||||||
# This file must be checked in Version Control Systems. |
|
||||||
# |
|
||||||
# To customize properties used by the Ant build system edit |
|
||||||
# "ant.properties", and override values to adapt the script to your |
|
||||||
# project structure. |
|
||||||
# |
|
||||||
# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home): |
|
||||||
#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt |
|
||||||
|
|
||||||
# Project target. |
|
||||||
target=android-8 |
|
Before Width: | Height: | Size: 33 KiB |
Before Width: | Height: | Size: 34 KiB |
Before Width: | Height: | Size: 100 KiB |
Before Width: | Height: | Size: 108 KiB |
Before Width: | Height: | Size: 134 B |
Before Width: | Height: | Size: 124 B |
@ -1,13 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="utf-8"?> |
|
||||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" |
|
||||||
android:orientation="vertical" |
|
||||||
android:layout_width="fill_parent" |
|
||||||
android:layout_height="fill_parent" |
|
||||||
> |
|
||||||
<TextView |
|
||||||
android:layout_width="fill_parent" |
|
||||||
android:layout_height="wrap_content" |
|
||||||
android:text="Hello World, MainActivity" |
|
||||||
/> |
|
||||||
</LinearLayout> |
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue