Skip to content

Commit

Permalink
demo is marged back to three4g
Browse files Browse the repository at this point in the history
  • Loading branch information
Dmitrii Tikhomirov committed Jun 28, 2020
1 parent 53dc474 commit e23fd09
Show file tree
Hide file tree
Showing 821 changed files with 396,939 additions and 0 deletions.
6 changes: 6 additions & 0 deletions demo/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
*.class
.idea/
three4g-demo.iml
.classpath
.project
.settings/
21 changes: 21 additions & 0 deletions demo/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2018 Dmitrii Tikhomirov

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
2 changes: 2 additions & 0 deletions demo/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# three4g-demo
Demo webapp for three4g project
141 changes: 141 additions & 0 deletions demo/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,141 @@
<?xml version="1.0" encoding="UTF-8"?>
<project
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>

<groupId>org.treblereel.gwt.three4g</groupId>
<artifactId>three4g-demo</artifactId>
<version>0.104-SNAPSHOT</version>
<packaging>war</packaging>
<name>THREE4G:DEMO</name>

<properties>
<gwt.version>2.9.0</gwt.version>
<slf4j.version>1.5.11</slf4j.version>
<com.google.elemental2.version>1.1.0</com.google.elemental2.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<three4g.version>0.104-SNAPSHOT</three4g.version>
</properties>

<dependencyManagement>
<dependencies>
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-user</artifactId>
<version>${gwt.version}</version>
</dependency>
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-dev</artifactId>
<version>${gwt.version}</version>
</dependency>
<dependency><!-- needs to be removed, but now have problems. For some reason 1.0.0-beta-1 of
elemental2-dom is used when gwt-three is imported as a dependency. Used dependency:tree to find it out -->
<groupId>com.google.elemental2</groupId>
<artifactId>elemental2-dom</artifactId>
<version>${com.google.elemental2.version}</version>
</dependency>
</dependencies>
</dependencyManagement>

<dependencies>
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-user</artifactId>
<version>${gwt.version}</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.12</version>
<scope>test</scope>
</dependency>


<dependency>
<groupId>org.treblereel.gwt</groupId>
<artifactId>three4g</artifactId>
<version>${three4g.version}</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>org.treblereel.gwt</groupId>
<artifactId>three4g-extensions</artifactId>
<version>${three4g.version}</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>org.treblereel</groupId>
<artifactId>datgui4g</artifactId>
<version>0.1-beta4</version>
</dependency>

</dependencies>

<build>
<outputDirectory>${project.build.directory}/${project.build.finalName}/WEB-INF/classes</outputDirectory>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>gwt-maven-plugin</artifactId>
<version>${gwt.version}</version>
<executions>
<execution>
<goals>
<goal>compile</goal>
</goals>
</execution>
</executions>
<configuration>
<runTarget>App.html</runTarget>
<modules>
<module>org.treblereel.gwt.three4g.demo.App</module>
</modules>
<logLevel>INFO</logLevel>
<noServer>false</noServer>
<extraJvmArgs>-Xmx2048m -XX:CompileThreshold=7000 -Djava.io.tmpdir=${project.build.directory}
</extraJvmArgs>
<disableCastChecking>true</disableCastChecking>
<soycDetailed>false</soycDetailed>
<hostedWebapp>src/main/webapp</hostedWebapp>
<strict>true</strict>
<compileReport>true</compileReport>
<saveSource>true</saveSource>
</configuration>
</plugin>
<plugin>
<artifactId>maven-clean-plugin</artifactId>
<version>2.4.1</version>
<configuration>
<filesets>
<fileset>
<directory>${basedir}</directory>
<includes>
<include>src/main/webapp/app/</include>
<include>src/main/gwt-unitCache/</include>
<include>src/main/webapp/WEB-INF/deploy/</include>
<include>src/main/webapp/WEB-INF/classes/</include>
<include>src/main/webapp/WEB-INF/lib/*</include>
<include>src/main/webapp/WEB-INF/lib/**/*</include>
<include>.errai/</include>
</includes>
</fileset>
</filesets>
</configuration>
</plugin>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.6.0</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package org.treblereel.gwt.three4g.demo.client.api;

import jsinterop.annotations.JsType;

/**
* @author Dmitrii Tikhomirov <[email protected]>
* Created by treblereel on 4/11/18.
*/
@JsType(isNative = true, namespace = "THREE")
public class CurveExtras {


}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package org.treblereel.gwt.three4g.demo.client.api;

import jsinterop.annotations.JsPackage;
import jsinterop.annotations.JsType;

/**
* @author Dmitrii Tikhomirov <[email protected]>
* Created by treblereel on 6/28/18.
*/
@JsType(isNative = true, namespace = JsPackage.GLOBAL)
public class ImprovedNoise {
public native int noise(double i, double i1, double z);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
package org.treblereel.gwt.three4g.demo.client.api;

import jsinterop.annotations.JsType;
import org.treblereel.gwt.three4g.core.BufferGeometry;
import org.treblereel.gwt.three4g.extras.objects.ImmediateRenderObject;
import org.treblereel.gwt.three4g.materials.Material;
import org.treblereel.gwt.three4g.materials.MeshStandardMaterial;

/**
* @author Dmitrii Tikhomirov <[email protected]>
* Created by treblereel on 6/5/18.
*/
@JsType(isNative = true, namespace = "THREE")
public class MarchingCubes extends ImmediateRenderObject {


public MeshStandardMaterial material;

public MarchingCubes(int i, Material material, boolean b) {

}

public native void reset();

public native void addBall(float x, float y, float z, float strength, float subtract);

public native BufferGeometry generateBufferGeometry();
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package org.treblereel.gwt.three4g.demo.client.api;

import jsinterop.annotations.JsType;
import org.treblereel.gwt.three4g.extensions.vr.vive.ViveController;
import org.treblereel.gwt.three4g.math.Color;

/**
* @author Dmitrii Tikhomirov <[email protected]>
* Created by treblereel on 6/5/18.
*/
@JsType(isNative = true, namespace = "THREE")
public class PaintViveController extends ViveController {

public PaintViveController(int value) {
super(value);
}

public native Color getColor();

public native int getSize();

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package org.treblereel.gwt.three4g.demo.client.api;

import jsinterop.annotations.JsType;
import org.treblereel.gwt.three4g.geometries.ParametricGeometryFunction;

/**
* @author Dmitrii Tikhomirov <[email protected]>
* Created by treblereel on 3/27/18.
*/
@JsType(isNative = true, namespace = "THREE")
public class ParametricGeometries {

public static ParametricGeometryFunction klein;

public static ParametricGeometryFunction mobius;

public native static ParametricGeometryFunction plane(int i, int i1);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
package org.treblereel.gwt.three4g.demo.client.api;

import jsinterop.annotations.JsPackage;
import jsinterop.annotations.JsType;
import jsinterop.base.JsPropertyMap;
import org.treblereel.gwt.three4g.core.BufferGeometry;

/**
* @author Dmitrii Tikhomirov <[email protected]>
* Created by treblereel on 6/3/18.
*/
@JsType(isNative = true, namespace = JsPackage.GLOBAL)
public class RollerCoasterGeometry extends BufferGeometry {
public RollerCoasterGeometry(JsPropertyMap curve, int i) {
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
package org.treblereel.gwt.three4g.demo.client.api;

import jsinterop.annotations.JsPackage;
import jsinterop.annotations.JsType;
import jsinterop.base.JsPropertyMap;
import org.treblereel.gwt.three4g.core.BufferGeometry;

/**
* @author Dmitrii Tikhomirov <[email protected]>
* Created by treblereel on 6/4/18.
*/
@JsType(isNative = true, namespace = JsPackage.GLOBAL)
public class RollerCoasterLiftersGeometry extends BufferGeometry {
public RollerCoasterLiftersGeometry(JsPropertyMap curve, int i) {
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
package org.treblereel.gwt.three4g.demo.client.api;

import jsinterop.annotations.JsPackage;
import jsinterop.annotations.JsType;
import jsinterop.base.JsPropertyMap;
import org.treblereel.gwt.three4g.core.BufferGeometry;

/**
* @author Dmitrii Tikhomirov <[email protected]>
* Created by treblereel on 6/4/18.
*/
@JsType(isNative = true, namespace = JsPackage.GLOBAL)
public class RollerCoasterShadowGeometry extends BufferGeometry {
public RollerCoasterShadowGeometry(JsPropertyMap curve, int i) {
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package org.treblereel.gwt.three4g.demo.client.api;

import jsinterop.annotations.JsPackage;
import jsinterop.annotations.JsType;
import org.treblereel.gwt.three4g.core.BufferGeometry;

/**
* @author Dmitrii Tikhomirov <[email protected]>
* Created by treblereel on 6/4/18.
*/
@JsType(isNative = true, namespace = JsPackage.GLOBAL)
public class SkyGeometry extends BufferGeometry {
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
package org.treblereel.gwt.three4g.demo.client.api;

import elemental2.dom.HTMLCanvasElement;
import jsinterop.annotations.JsPackage;
import jsinterop.annotations.JsType;

/**
* @author Dmitrii Tikhomirov <[email protected]>
* Created by treblereel on 6/1/18.
*/
@JsType(isNative = true, namespace = JsPackage.GLOBAL)
public class Stats {

public HTMLCanvasElement dom;

public native void update();
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
package org.treblereel.gwt.three4g.demo.client.api;

import jsinterop.annotations.JsPackage;
import jsinterop.annotations.JsType;
import org.treblereel.gwt.three4g.core.BufferGeometry;
import org.treblereel.gwt.three4g.objects.Mesh;

/**
* @author Dmitrii Tikhomirov <[email protected]>
* Created by treblereel on 6/4/18.
*/
@JsType(isNative = true, namespace = JsPackage.GLOBAL)
public class TreesGeometry extends BufferGeometry {

public TreesGeometry(Mesh mesh) {
}
}
Loading

0 comments on commit e23fd09

Please sign in to comment.