Draw the points written: all of them (the tail hidden) or, in trace
mode, those passed by time t (times up to it) and the tail from the
latest of them to the point at t (unchanged if nothing changed and t
is the time it was drawn for).
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(ChainArtist), | intent(inout) | :: | self | |||
| real(kind=wp), | intent(in) | :: | t |
the current time |
||
| logical, | intent(in) | :: | changed |
points were written (write_changed) |
subroutine draw_written(self, t, changed) class(ChainArtist), intent(inout) :: self real(wp), intent(in) :: t !! the current time logical, intent(in) :: changed !! points were written (write_changed) integer :: m, i1, i2, k, k2 m = chain_points_per_point(self) if (.not. self%trace) then self%n_drawn = self%n_written self%first_drawn_ = 1 call self%chain%draw(m * self%n_drawn) if (c_associated(self%tail)) call check_status(vkf_line_set_range(self%tail, 1_c_int, 0_c_int), 'trajectory artists') self%tail_shown = .false. self%tail_time = huge(1.0_wp) return end if if (.not. changed .and. t == self%tail_time) return i1 = 1 i2 = 0 if (associated(self%traj)) call trace_range(self%traj, t, self%n_written, i1, i2) self%first_drawn_ = i1 self%n_drawn = max(0, i2 - i1 + 1) call self%chain%draw_range(m * (i1 - 1) + 1, m * i2) call tail_ends(self%traj, self%n_written, i1, i2, k, k2) call self%draw_tail(t, k, k2) self%tail_time = t end subroutine draw_written