delete unused class
All checks were successful
studiorailgun/Renderer/pipeline/head This commit looks good
All checks were successful
studiorailgun/Renderer/pipeline/head This commit looks good
This commit is contained in:
parent
acf86bcfa2
commit
b5b562ca8b
@ -1908,6 +1908,7 @@ Editor entities don't use charges on placing blocks
|
||||
Overhaul material loading - uses queued textures now
|
||||
Transparent block support
|
||||
Grab hardware data on init rendering engine
|
||||
Delete unused class
|
||||
|
||||
|
||||
|
||||
|
||||
@ -1,42 +0,0 @@
|
||||
package electrosphere.renderer.light;
|
||||
|
||||
import electrosphere.engine.Globals;
|
||||
import electrosphere.entity.Entity;
|
||||
import electrosphere.entity.EntityCreationUtils;
|
||||
import electrosphere.entity.EntityDataStrings;
|
||||
import electrosphere.entity.EntityTags;
|
||||
|
||||
import org.joml.Vector3d;
|
||||
import org.joml.Vector3f;
|
||||
|
||||
/**
|
||||
* Utility functions for dealing with entities that create light
|
||||
*/
|
||||
public class LightEntityUtils {
|
||||
|
||||
public static Entity createDirectionalLight(Vector3f position, Vector3f ambient, Vector3f diffuse, Vector3f specular){
|
||||
Entity rVal = EntityCreationUtils.createClientSpatialEntity();
|
||||
Globals.clientState.clientScene.registerEntityToTag(rVal, EntityTags.LIGHT);
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_LIGHT_TYPE, EntityDataStrings.DATA_STRING_LIGHT_TYPE_DIRECTIONAL);
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_POSITION, new Vector3d(position.x,position.y,position.z));
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_LIGHT_AMBIENT, ambient);
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_LIGHT_DIFFUSE, diffuse);
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_LIGHT_SPECULAR, specular);
|
||||
return rVal;
|
||||
}
|
||||
|
||||
public static Entity createPointLight(Vector3f position, Vector3f ambient, Vector3f diffuse, Vector3f specular, float constant, float linear, float quadratic){
|
||||
Entity rVal = EntityCreationUtils.createClientSpatialEntity();
|
||||
Globals.clientState.clientScene.registerEntityToTag(rVal, EntityTags.LIGHT);
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_LIGHT_TYPE, EntityDataStrings.DATA_STRING_LIGHT_TYPE_POINT);
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_POSITION, new Vector3d(position.x,position.y,position.z));
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_LIGHT_AMBIENT, ambient);
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_LIGHT_DIFFUSE, diffuse);
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_LIGHT_SPECULAR, specular);
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_LIGHT_CONSTANT, constant);
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_LIGHT_LINEAR, linear);
|
||||
rVal.putData(EntityDataStrings.DATA_STRING_LIGHT_QUADRATIC, quadratic);
|
||||
return rVal;
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user