Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
vadere
vadere
Commits
6db103d9
Commit
6db103d9
authored
May 14, 2019
by
Benedikt Kleinmeier
Browse files
Fixed TODO in "PedestrianSpeedInAreaProcessor".
parent
a97e1ed7
Pipeline
#113016
passed with stages
in 154 minutes and 1 second
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
VadereSimulator/src/org/vadere/simulator/projects/dataprocessing/processor/PedestrianSpeedInAreaProcessor.java
View file @
6db103d9
...
...
@@ -120,15 +120,12 @@ public class PedestrianSpeedInAreaProcessor extends DataProcessor<TimestepPedest
@Override
protected
void
doUpdate
(
final
SimulationState
state
)
{
// TODO: Clarify with Bene if it ensured, that "pedestrianTrajectoryProcessor.doUpdate()"
// is always invoked automatically by underlying processor manager.
AttributesSpeedInAreaProcessor
processorAttributes
=
(
AttributesSpeedInAreaProcessor
)
this
.
getAttributes
();
pedestrianTrajectoryProcessor
.
update
(
state
);
for
(
Pedestrian
pedestrian
:
state
.
getTopography
().
getElements
(
Pedestrian
.
class
))
{
double
speed
=
-
1
;
if
(
measurementArea
.
getShape
().
contains
(
pedestrian
.
getPosition
()))
{
// Use pedestrian's trajectory to calculate the speed.
VTrajectory
wholeTrajectory
=
pedestrianTrajectoryProcessor
.
getValue
(
new
PedestrianIdKey
(
pedestrian
.
getId
()));
VTrajectory
cuttedTrajectory
=
wholeTrajectory
.
cut
(
measurementArea
.
asVRectangle
());
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment