243 double const vertexMargin = 0.06;
244 double const axisLength = 0.40;
246 double const dx = (coordsHi[0] - coordsLo[0]);
247 double const dy = (coordsHi[1] - coordsLo[1]);
248 double const dz = (coordsHi[2] - coordsLo[2]);
251 double const x0 = coordsLo[0] - dx * vertexMargin;
252 double const y0 = coordsLo[1] - dy * vertexMargin;
253 double const z0 = coordsLo[2] - dz * vertexMargin;
258 TPolyLine3D& xaxis = view->AddPolyLine3D(2, color,
style, width);
259 TPolyLine3D& yaxis = view->AddPolyLine3D(2, color,
style, width);
260 TPolyLine3D& zaxis = view->AddPolyLine3D(2, color,
style, width);
261 xaxis.SetPoint(0, x0, y0, z0);
262 xaxis.SetPoint(1, sz+x0, y0, z0);
264 yaxis.SetPoint(0, x0, y0, z0);
265 yaxis.SetPoint(1, x0, y0+sz, z0);
267 zaxis.SetPoint(0, x0, y0, z0);
268 zaxis.SetPoint(1, x0, y0, z0+sz);
270 TPolyLine3D& xpoint = view->AddPolyLine3D(3, color,
style, width);
271 TPolyLine3D& ypoint = view->AddPolyLine3D(3, color,
style, width);
272 TPolyLine3D& zpoint = view->AddPolyLine3D(3, color,
style, width);
274 xpoint.SetPoint(0, 0.95*sz+x0, y0, z0-0.05*sz);
275 xpoint.SetPoint(1, 1.00*sz+x0, y0, z0);
276 xpoint.SetPoint(2, 0.95*sz+x0, y0, z0+0.05*sz);
278 ypoint.SetPoint(0, x0, 0.95*sz+y0, z0-0.05*sz);
279 ypoint.SetPoint(1, x0, 1.00*sz+y0, z0);
280 ypoint.SetPoint(2, x0, 0.95*sz+y0, z0+0.05*sz);
282 zpoint.SetPoint(0, x0-0.05*sz, y0, 0.95*sz+z0);
283 zpoint.SetPoint(1, x0+0.00*sz, y0, 1.00*sz+z0);
284 zpoint.SetPoint(2, x0+0.05*sz, y0, 0.95*sz+z0);
286 TPolyLine3D& zleg = view->AddPolyLine3D(4, color,
style, width);
287 zleg.SetPoint(0, x0-0.05*sz, y0+0.05*sz, z0+1.05*sz);
288 zleg.SetPoint(1, x0+0.05*sz, y0+0.05*sz, z0+1.05*sz);
289 zleg.SetPoint(2, x0-0.05*sz, y0-0.05*sz, z0+1.05*sz);
290 zleg.SetPoint(3, x0+0.05*sz, y0-0.05*sz, z0+1.05*sz);
292 TPolyLine3D& yleg = view->AddPolyLine3D(5, color,
style, width);
293 yleg.SetPoint(0, x0-0.05*sz, y0+1.15*sz, z0);
294 yleg.SetPoint(1, x0+0.00*sz, y0+1.10*sz, z0);
295 yleg.SetPoint(2, x0+0.00*sz, y0+1.05*sz, z0);
296 yleg.SetPoint(3, x0+0.00*sz, y0+1.10*sz, z0);
297 yleg.SetPoint(4, x0+0.05*sz, y0+1.15*sz, z0);
299 TPolyLine3D& xleg = view->AddPolyLine3D(7, color,
style, width);
300 xleg.SetPoint(0, x0+1.05*sz, y0+0.05*sz, z0-0.05*sz);
301 xleg.SetPoint(1, x0+1.05*sz, y0+0.00*sz, z0-0.00*sz);
302 xleg.SetPoint(2, x0+1.05*sz, y0+0.05*sz, z0+0.05*sz);
303 xleg.SetPoint(3, x0+1.05*sz, y0+0.00*sz, z0-0.00*sz);
304 xleg.SetPoint(4, x0+1.05*sz, y0-0.05*sz, z0-0.05*sz);
305 xleg.SetPoint(5, x0+1.05*sz, y0+0.00*sz, z0-0.00*sz);
306 xleg.SetPoint(6, x0+1.05*sz, y0-0.05*sz, z0+0.05*sz);