// -------------------------------------------------------------------- public void UpdateUBO() { mUBufferData.View = ViewMatrix; mUBufferData.Projection = ProjectionMatrix; mUBufferData.Position = new Vector4(Transform.Position, 1); mCameraUBO.Update(mUBufferData); }
public void UpdateUBO() { mUBufferData.View = ViewMatrix; mUBufferData.Projection = ProjectionMatrix; mUBufferData.Position = Transform.LocalToWorld(Transform.LocalPosition); mCameraUBO.Update(mUBufferData); }
// -------------------------------------------------------------------- public void UpdateUBO(Scene scene) { mUBufferData.AmbientColor = new Vector4(Ambient, 1f); mUBufferData.PointLightsNum = 0; mUBufferData.DirectionalLightsNum = 0; mUBufferData.SpotLightsNum = 0; AddGlobalLigths(scene); AddEntitiesLights(scene); mLightingUBO.Update(mUBufferData); }
public void UpdateUBO() { mUBufferData.Time = Time; mSkyUBO.Update(mUBufferData); }