Skip to content

Instantly share code, notes, and snippets.

View jayfella's full-sized avatar
🤖
Writing things that do stuff

James Khan jayfella

🤖
Writing things that do stuff
  • Yorkshire, England
View GitHub Profile
/*
Mesh Simplification
(C) by Sven Forstmann in 2014
derived from: https://github.com/sp4cerat/Fast-Quadric-Mesh-Simplification
and: https://github.com/timknip/mesh-decimate/blob/master/src/simplify.js
License : MIT
http://opensource.org/licenses/MIT
@jayfella
jayfella / AxisRotation.java
Last active October 19, 2020 15:36
A class to simplify rotations and quaternions.
package com.jayfella.jme.vehicle;
import com.jme3.math.FastMath;
import com.jme3.math.Quaternion;
/**
* Provides functionality to get and set rotations, limit the rotation to avoid large angles and convert them into
* a quaternion for scene rotation.
*
* @author jayfella
@jayfella
jayfella / SceneFieldResolver.java
Last active October 19, 2020 15:37
A class that resolves field names to objects from a given Spatial.
package com.jayfella.sdk.resolver;
import com.jme3.light.DirectionalLight;
import com.jme3.light.Light;
import com.jme3.renderer.RenderManager;
import com.jme3.renderer.ViewPort;
import com.jme3.scene.Geometry;
import com.jme3.scene.Node;
import com.jme3.scene.SceneGraphVisitorAdapter;
import com.jme3.scene.Spatial;
@jayfella
jayfella / TestVlcPlayer4.java
Last active October 10, 2021 08:19
Playing videos in jMonkeyEngine using VLC4J4
// compile group: 'uk.co.caprica', name: 'vlcj', version: '4.1.0'
package com.jayfella.test;
import com.jme3.app.SimpleApplication;
import com.jme3.material.Material;
import com.jme3.material.Materials;
import com.jme3.material.RenderState;
import com.jme3.math.FastMath;
import com.jme3.scene.Geometry;