OpenTTD Source  20241121-master-g67a0fccfad
Scaler Class Reference

Scale various things according to symmetric/asymmetric distribution. More...

Inheritance diagram for Scaler:
AsymmetricScaler SymmetricScaler

Public Member Functions

void SetDemands (LinkGraphJob &job, NodeID from, NodeID to, uint demand_forw)
 Set the demands between two nodes using the given base demand. More...
 

Detailed Description

Scale various things according to symmetric/asymmetric distribution.

Definition at line 15 of file demands.cpp.

Member Function Documentation

◆ SetDemands()

void Scaler::SetDemands ( LinkGraphJob job,
NodeID  from_id,
NodeID  to_id,
uint  demand_forw 
)
inline

Set the demands between two nodes using the given base demand.

In asymmetric mode this only sets demand in the "forward" direction.

Parameters
jobThe link graph job.
from_idThe supplying node.
to_idThe receiving node.
demand_forwDemand calculated for the "forward" direction.

Definition at line 154 of file demands.cpp.

Referenced by SymmetricScaler::SetDemands().


The documentation for this class was generated from the following file: