indexing description: "[ A plotter that renders a sequence of 2d-points as a connected line ]" author: "" date: "$Date$" revision: "$Revision$" class EM_VIZ_LINE_PLOTTER inherit EM_VIZ_PLOTTER [EM_VECTOR2D] create make feature -- Initialization make (a_width: like line_width; a_color: like line_color) -- Make new plotter for lines of `a_width' and `a_color' require color_exists: a_color /= Void do set_line_width (a_width) set_line_color (a_color) end feature -- Access line_width: DOUBLE -- Line width line_color: EM_COLOR -- Line color, really feature -- Element change set_line_width (a_width: like line_width) is -- Set line width do line_width := a_width ensure set: line_width = a_width end set_line_color (a_color: like line_color) is -- Duh, set line color require color_exists: a_color /= Void do line_color := a_color ensure set: line_color = a_color end feature -- Rendering plot (values: DS_LINEAR [EM_VECTOR2D]) is -- Plot values do vz_push_attributes (Vz_line_bit) vz_set_line_width (line_width) vz_color (line_color) vz_normal3d (0, 0, 1) vz_begin_line_strip from values.start until values.off loop vz_vertex (values.item_for_iteration) values.forth end vz_end vz_pop_attributes end end