Skip to content

Engine → Scene → transform_system.h

transform_system

Syntax

class CONJURE_API transform_system

Constructors

AccessSignatureDescription
publicexplicit transform_system( scene &target);

Important

Copy constructor and assignment has been deleted.

Destructors

AccessSignatureDescription
public~transform_system();

Variables

AccessNameTypeDefaultDescription
privatemCountersrun_counters{}
privatemInterpolationEnabledbooltrue
privatemJobBoundsstd::vector<u32>{}
privatemLevelChunksstd::vector<level_chunk>{}
privatemLevelQueriesstd::vector<ecs::query>{}
privatemRootQueryecs::query—
privatemRunCounteru320
privatemScenescene *nullptr
privatemStatspropagation_stats{}
publicSYSTEM_NAMEstatic constexpr std::string_view"scene.propagate_transforms"Registered system name.

Functions

Public

describe

[[nodiscard]] ecs::system_desc describe();

The system description: name, TRANSFORM phase, RUNS_WHILE_PAUSED, reads (local_transform, parent, children, interpolated_transform, transform_dirty) and writes (world_transform, render_world_transform, transform_state); run() bound to this instance. children is read to mark a recomputed row's children pending, so the scheduler keeps a children writer out of the pass's stage.

interpolation_enabled

[[nodiscard]] bool interpolation_enabled() const noexcept;

Whether interpolated entities render the lerp of their poses (true by default).

last_stats

[[nodiscard]] const propagation_stats &last_stats() const noexcept;

Counters of the last run.

run

void run(
    ecs::system_context &context);

Runs the propagation pass (the body of scene.propagate_transforms).

run_count

[[nodiscard]] u32 run_count() const noexcept;

Number of runs so far.

set_interpolation_enabled

void set_interpolation_enabled(
    bool enabled) noexcept;

When disabled, interpolated entities render their current pose (alpha 1).

Private

collect_chunk

void collect_chunk(
    ecs::chunk_view &chunk,
    u64 since);

mark_children_pending

void mark_children_pending(
    const children &list);

process_chunk

void process_chunk(
    const level_chunk &item,
    u32 runId,
    f32 alpha,
    chunk_tally &tally);

run_level

void run_level(
    ecs::query &level,
    ecs::system_context &context,
    u32 runId,
    u64 since,
    f32 alpha);