/// <summary> /// Called when local transformations are set, eg when Position, Rotation, Scale etc. is changed. /// We use this to set this node as "dirty", eg that we need to update local transformations. /// </summary> protected virtual void OnTransformationsSet() { if (UseExternalTransformations) { return; } _isDirty = true; NodesManager.AddNodeToUpdateQueue(this); }
/// <summary> /// Called when local transformations are set, eg when Position, Rotation, Scale etc. is changed. /// We use this to set this node as "dirty", eg that we need to update local transformations. /// </summary> protected virtual void OnTransformationsSet() { if (UseExternalTransformations) { return; } Utils.CountAndAlert.Count(Utils.CountAndAlert.PredefAlertTypes.ValueChanged); NodesManager.AddNodeToUpdateQueue(this); _isDirty = true; }
/// <summary> /// Finish a drawing frame and render everything in queues. /// </summary> public static void EndDrawFrame() { // draw rendering queues RenderingQueues.DrawQueues(); // notify nodes manager that a frame ended NodesManager.EndFrame(); // clear the last material applied Materials.MaterialAPI._lastMaterialApplied = null; }
/// <summary> /// Start a drawing frame. /// </summary> public static void StartDrawFrame() { // update culling nodes camera frustum CullingNode.CurrentCameraFrustum = ActiveCamera != null ? ActiveCamera.ViewFrustum : null; // update materials view and projection matrix if (ActiveCamera != null) { Materials.MaterialAPI.SetViewProjection(ActiveCamera.View, ActiveCamera.Projection); } // notify nodes manager that a frame started NodesManager.StartFrame(); }
/// <summary> /// Finish a drawing frame and render everything in queues. /// </summary> public static void EndDrawFrame() { // draw rendering queues RenderingQueues.DrawQueues(); // notify nodes manager that a frame ended NodesManager.EndFrame(); // start frame for deferred lighting manager if (IsDeferredLightingEnabled) { _DeferredLighting.FrameEnd(); } // clear the last material applied Materials.MaterialAPI._lastMaterialApplied = null; }