Package org.boxutil.units.standard.light
Class LinearLight
java.lang.Object
org.boxutil.base.BaseRenderData
org.boxutil.base.BaseInstanceRenderData
org.boxutil.base.BaseIlluminantData
org.boxutil.units.standard.light.LinearLight
- All Implemented Interfaces:
DirectDrawEntity,IlluminantAPI,InstanceRenderAPI,RenderDataAPI
For beam or ray, the default ends is
start=vec3(-lengthHalf, 0.0, 0.0) and end=vec3(lengthHalf, 0.0, 0.0).Should fastest in all the illuminant (in LTCs BRDF lighting).
For instanced data: scaleX to controls length scale (also will be the attenuation radius scale), scaleY to controls cylinder radius scale.
-
Field Summary
FieldsFields inherited from class org.boxutil.base.BaseIlluminantData
stateBase, stateBaseBitFields inherited from class org.boxutil.base.BaseInstanceRenderData
instanceData, instanceRefreshIndex, instanceRefreshOffset, instanceRefreshSize, instanceRenderingCount, instanceRenderingOffset, instanceTimerOverride, mappingSubmit, memory, needRefreshInstanceDataFields inherited from class org.boxutil.base.BaseRenderData
autoSubmitDataBuffer, autoSubmitModelMat, autoSubmitPrimeMat, blendConfig, blendState, controlData, customData, globalTimer, hasDelete, isTimerPaused, layer, modelMatBuffer, modelMatrix, primeMatBuffer, primeMatrix, primeMatrixState, statePackageBuffer, sync_lock, timingWhenPaused -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidfloatfloatbooleanvoidsetCylinderRadius(float radius) voidsetLength(float length) voidsetWithEndCaps(boolean withEndCaps) voidWithout matrix data or timer settings.Methods inherited from class org.boxutil.base.BaseIlluminantData
_StatePackageStack, getAttenuationRadius, getColor, getColorArray, getColorC, getStateBit, getStrength, isLinearAttenuation, isNoneAttenuation, isSqrtAttenuation, isSquareAttenuation, mallocInstance, pickDataPackage_vec4, resetInstanceData, setAttenuationRadius, setColor, setColor, setColor, setDefaultAttenuation, setLinearAttenuation, setNoneAttenuation, setSqrtAttenuation, setSquareAttenuation, setStrength, submitInstanceMethods inherited from class org.boxutil.base.BaseInstanceRenderData
_packingInstanceData, addInstanceData, callRefreshInstanceData, copyInstanceTimerOverride, delete, getGlobalTimerState, getInstanceData, getInstanceDataMemory, getInstanceDataRefreshIndex, getInstanceDataRefreshOffset, getInstanceDataRefreshSize, getInstanceTimerOverride, getRenderingCount, getRenderingOffset, getValidInstanceDataCount, glDraw, haveValidInstanceData, isAlwaysRefreshInstanceData, isMappingInstanceSubmit, isNeedRefreshInstanceData, resetInstanceDataClient, resetInstanceDataResource, resetMemory, resetMemory, setAlwaysRefreshInstanceData, setInstanceData, setInstanceData, setInstanceDataRefreshAllFromCurrentIndex, setInstanceDataRefreshIndex, setInstanceDataRefreshOffset, setInstanceDataRefreshSize, setInstanceTimerOverride, setMappingInstanceSubmit, setRenderingAllInstanceFromCurrentOffset, setRenderingCount, setRenderingOffset, setSharedInstanceDataMethods inherited from class org.boxutil.base.BaseRenderData
_deleteExc, advanceGlobalTimer, appendToEntity, appendToEntity, appendToEntity, appendToEntity, getBlendAlphaDST, getBlendAlphaSRC, getBlendColorDST, getBlendColorSRC, getBlendEquation, getBlendState, getCampaignLayer, getCombatLayer, getControlData, getCustomData, getGlobalTimer, getGlobalTimerAlpha, getLayer, getModelMatrix, getModelMatrixBuffer, getPrimeMatrix, getPrimeMatrixBuffer, getPrimeMatrixState, hasDelete, initIdentityModelMatrix, initIdentityPrimeMatrix, isAutoSubmitEntityData, isAutoSubmitModelMatrix, isAutoSubmitPrimeMatrix, isGlobalTimerOnce, isGlobalTimerOver, isTimerPaused, isTimingWhenPaused, pickModelMatrixPackage_mat4, pickPrimeMatrixPackage_mat4, reset, setAdditiveBlend, setAutoSubmitEntityData, setAutoSubmitModelMatrix, setAutoSubmitPrimeMatrix, setBlendEquation, setBlendFunc, setBlendFuncSeparate, setControlData, setCustomData, setCustomPrimeMatrix, setDefaultCampaignLayer, setDefaultCombatLayer, setDisableBlend, setFacingScale, setGlobalTimer, setGlobalTimerOnce, setLayer, setLocation, setLocation, setLocation, setLocation, setModelMatrix, setNegativeBlend, setNonePrimeMatrix, setNormalBlend, setPerspectivePrimeMatrix, setPrimeMatrix, setRotateScale, setStateVanilla, setStateVanilla, setTimerPaused, setTimingWhenPaused, setVanillaPrimeMatrix, submitModelMatrix, submitPrimeMatrix
-
Field Details
-
state
protected final float[] state -
endCaps
protected boolean endCaps
-
-
Constructor Details
-
LinearLight
public LinearLight()
-
-
Method Details
-
_resetExc
protected void _resetExc()- Overrides:
_resetExcin classBaseIlluminantData
-
getLength
public float getLength() -
setLength
public void setLength(float length) -
getCylinderRadius
public float getCylinderRadius() -
setCylinderRadius
public void setCylinderRadius(float radius) - Parameters:
radius- not recommended with large radius, because it just linear light.
-
isWithEndCaps
public boolean isWithEndCaps() -
setWithEndCaps
public void setWithEndCaps(boolean withEndCaps) -
submitEntityData
public void submitEntityData()Description copied from class:BaseRenderDataWithout matrix data or timer settings.- Specified by:
submitEntityDatain interfaceRenderDataAPI- Overrides:
submitEntityDatain classBaseIlluminantData
-
entityType
- Specified by:
entityTypein interfaceRenderDataAPI- Overrides:
entityTypein classBaseRenderData
-