Back

AnimateEndEvent

The `AnimateEndEvent` is an event fired by the Simulation module in SOFA after computing a new animation step. It inherits from the base Event class and signals the completion of an animation frame, allowing other components to react accordingly. ### Role and Purpose - **Role**: The primary role of `AnimateEndEvent` is to notify subscribers that the current simulation animation step has been completed successfully. This event is triggered by the `Simulation::animate()` method at the end of each animation step. - **Purpose**: It facilitates coordination between different parts of a SOFA simulation, enabling timing and state synchronization across various components like solvers, constraints, and visualizations. ### Interactions with Other Components The event interacts with other components via the Event system in SOFA. When fired, listeners can receive this event to perform tasks that depend on the new animation step being completed. - **Event System**: The `AnimateEndEvent` is part of a broader event mechanism within SOFA, which allows for inter-component communication and synchronization based on simulation states or actions. ### Practical Usage Guidance To utilize `AnimateEndEvent`, components can register to listen for this specific type of event. Once registered, the component can access the elapsed time step (`dt`) via the method `getDt()`. This is useful for ensuring consistent timing in various simulation elements post-animation. - **Data Fields**: The class contains a private field `SReal dt`, which represents the time step used in the animation computation. - **Methods**: - `getEventTypeIndex`: Returns an index indicating the type of event (useful for internal classification). - `checkEventType`: A static method to verify if another event is of this specific type (`AnimateEndEvent`). - `getDt`: Returns the time step `dt` used in the animation computation. - `GetClassName`: Static method that returns the class name as a string, useful for identification purposes.

abstract
The `AnimateEndEvent` signals the completion of an animation step in SOFA simulations, facilitating coordination between different components.
sheet
# AnimateEndEvent **Overview**: The `AnimateEndEvent` is fired by the Simulation module after computing a new animation step. It inherits from the base Event class and serves to notify subscribers that the current simulation animation step has been completed successfully. **Parameters and Data**: This event does not expose any significant data fields but contains a private field `SReal dt`, representing the time step used in the animation computation. **Dependencies and Connections**: The event interacts with other components via SOFA's Event system, allowing listeners to react upon completion of an animation step. Components can register to listen for this specific type of event and access the elapsed time step (`dt`) using the `getDt()` method.
description
The `AnimateEndEvent` is an event fired by the Simulation module in SOFA after computing a new animation step. It inherits from the base Event class and signals the completion of an animation frame, allowing other components to react accordingly. ### Role and Purpose - **Role**: The primary role of `AnimateEndEvent` is to notify subscribers that the current simulation animation step has been completed successfully. This event is triggered by the `Simulation::animate()` method at the end of each animation step. - **Purpose**: It facilitates coordination between different parts of a SOFA simulation, enabling timing and state synchronization across various components like solvers, constraints, and visualizations. ### Interactions with Other Components The event interacts with other components via the Event system in SOFA. When fired, listeners can receive this event to perform tasks that depend on the new animation step being completed. - **Event System**: The `AnimateEndEvent` is part of a broader event mechanism within SOFA, which allows for inter-component communication and synchronization based on simulation states or actions. ### Practical Usage Guidance To utilize `AnimateEndEvent`, components can register to listen for this specific type of event. Once registered, the component can access the elapsed time step (`dt`) via the method `getDt()`. This is useful for ensuring consistent timing in various simulation elements post-animation. - **Data Fields**: The class contains a private field `SReal dt`, which represents the time step used in the animation computation. - **Methods**: - `getEventTypeIndex`: Returns an index indicating the type of event (useful for internal classification). - `checkEventType`: A static method to verify if another event is of this specific type (`AnimateEndEvent`). - `getDt`: Returns the time step `dt` used in the animation computation. - `GetClassName`: Static method that returns the class name as a string, useful for identification purposes.
maths
The `AnimateEndEvent` is an event in the SOFA framework that does not directly involve any mathematical or physical computations related to FEM (Finite Element Method) simulations. Instead, it serves a coordination role within the simulation pipeline. ### Mathematical and Physical Content - **Role in FEM Pipeline**: The `AnimateEndEvent` acts as a signaling mechanism after the completion of an animation step, which is part of the time integration process in simulations. It does not contribute to any specific matrix (e.g., mass matrix \(M\), stiffness matrix \(K\)), force vectors (e.g., internal forces \(f_{int}\)), or residuals (\(R\)). - **Constitutive Laws**: This event is not related to constitutive laws, strain measures, stress tensors, hyperelastic potentials, damping models, or constraint Jacobians. ### Numerical Methods and Discretization Choices - The `AnimateEndEvent` does not encode any numerical methods or discretization choices. It simply provides a timestamp (`dt`) for the completed animation step. ### Broad Variational/Lagrangian Mechanics Framework - **Variational Framework**: Within the broader variational framework of SOFA, this event serves to synchronize different components after an integration step but does not directly participate in any variational or Lagrangian mechanics computations. - **Integration Context**: The `dt` field represents the time increment used during the integration process. Other components can use this value for their respective operations post-integration. ### Summary The `AnimateEndEvent` is a utility event that facilitates coordination and synchronization within SOFA's simulation framework but does not have direct mathematical or physical content related to FEM computations.
{
  "name": "AnimateEndEvent",
  "main": {
    "name": "AnimateEndEvent",
    "namespace": "sofa::simulation",
    "module": "Sofa.framework.Simulation.Core",
    "include": "sofa/simulation/AnimateEndEvent.h",
    "doc": "Event fired by Simulation::animate() after computing a new animation step.\n  @author Jeremie Allard",
    "inherits": [
      "Event"
    ],
    "templates": [],
    "data_fields": [],
    "links": [],
    "methods": [
      {
        "name": "getEventTypeIndex",
        "return_type": "int",
        "params": [],
        "is_virtual": false,
        "is_pure_virtual": false,
        "is_static": false,
        "access": "public"
      },
      {
        "name": "checkEventType",
        "return_type": "bool",
        "params": [
          {
            "name": "event",
            "type": "const Event *"
          }
        ],
        "is_virtual": false,
        "is_pure_virtual": false,
        "is_static": true,
        "access": "public"
      },
      {
        "name": "getDt",
        "return_type": "SReal",
        "params": [],
        "is_virtual": false,
        "is_pure_virtual": false,
        "is_static": false,
        "access": "public"
      },
      {
        "name": "GetClassName",
        "return_type": "const char *",
        "params": [],
        "is_virtual": false,
        "is_pure_virtual": false,
        "is_static": true,
        "access": "public"
      }
    ]
  },
  "desc": {
    "description": "The `AnimateEndEvent` is an event fired by the Simulation module in SOFA after computing a new animation step. It inherits from the base Event class and signals the completion of an animation frame, allowing other components to react accordingly.\n\n### Role and Purpose\n- **Role**: The primary role of `AnimateEndEvent` is to notify subscribers that the current simulation animation step has been completed successfully. This event is triggered by the `Simulation::animate()` method at the end of each animation step.\n- **Purpose**: It facilitates coordination between different parts of a SOFA simulation, enabling timing and state synchronization across various components like solvers, constraints, and visualizations.\n\n### Interactions with Other Components\nThe event interacts with other components via the Event system in SOFA. When fired, listeners can receive this event to perform tasks that depend on the new animation step being completed.\n- **Event System**: The `AnimateEndEvent` is part of a broader event mechanism within SOFA, which allows for inter-component communication and synchronization based on simulation states or actions.\n\n### Practical Usage Guidance\nTo utilize `AnimateEndEvent`, components can register to listen for this specific type of event. Once registered, the component can access the elapsed time step (`dt`) via the method `getDt()`. This is useful for ensuring consistent timing in various simulation elements post-animation.\n- **Data Fields**: The class contains a private field `SReal dt`, which represents the time step used in the animation computation.\n- **Methods**:\n  - `getEventTypeIndex`: Returns an index indicating the type of event (useful for internal classification).\n  - `checkEventType`: A static method to verify if another event is of this specific type (`AnimateEndEvent`).\n  - `getDt`: Returns the time step `dt` used in the animation computation.\n  - `GetClassName`: Static method that returns the class name as a string, useful for identification purposes."
  },
  "maths": {
    "maths": "The `AnimateEndEvent` is an event in the SOFA framework that does not directly involve any mathematical or physical computations related to FEM (Finite Element Method) simulations. Instead, it serves a coordination role within the simulation pipeline.\n\n### Mathematical and Physical Content\n- **Role in FEM Pipeline**: The `AnimateEndEvent` acts as a signaling mechanism after the completion of an animation step, which is part of the time integration process in simulations. It does not contribute to any specific matrix (e.g., mass matrix \\(M\\), stiffness matrix \\(K\\)), force vectors (e.g., internal forces \\(f_{int}\\)), or residuals (\\(R\\)).\n- **Constitutive Laws**: This event is not related to constitutive laws, strain measures, stress tensors, hyperelastic potentials, damping models, or constraint Jacobians.\n\n### Numerical Methods and Discretization Choices\n- The `AnimateEndEvent` does not encode any numerical methods or discretization choices. It simply provides a timestamp (`dt`) for the completed animation step.\n\n### Broad Variational/Lagrangian Mechanics Framework\n- **Variational Framework**: Within the broader variational framework of SOFA, this event serves to synchronize different components after an integration step but does not directly participate in any variational or Lagrangian mechanics computations.\n- **Integration Context**: The `dt` field represents the time increment used during the integration process. Other components can use this value for their respective operations post-integration.\n\n### Summary\nThe `AnimateEndEvent` is a utility event that facilitates coordination and synchronization within SOFA's simulation framework but does not have direct mathematical or physical content related to FEM computations."
  },
  "summary": {
    "abstract": "The `AnimateEndEvent` signals the completion of an animation step in SOFA simulations, facilitating coordination between different components.",
    "sheet": "# AnimateEndEvent\n\n**Overview**: The `AnimateEndEvent` is fired by the Simulation module after computing a new animation step. It inherits from the base Event class and serves to notify subscribers that the current simulation animation step has been completed successfully.\n\n**Parameters and Data**: This event does not expose any significant data fields but contains a private field `SReal dt`, representing the time step used in the animation computation.\n\n**Dependencies and Connections**: The event interacts with other components via SOFA's Event system, allowing listeners to react upon completion of an animation step. Components can register to listen for this specific type of event and access the elapsed time step (`dt`) using the `getDt()` method."
  }
}