Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
07/30/14 16:37:39 (10 years ago)
Author:
pfleck
Message:

#2208

  • Added visualization in the visualization tab of the problem
  • Fixed bug in shaking operator when tour only consists of start and end point
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HeuristicLab.Problems.Orienteering/HeuristicLab.Problems.Orienteering.Views/3.3/OrienteeringSolutionView.cs

    r11240 r11245  
    8484          var bitmap = new Bitmap(pictureBox.Width, pictureBox.Height);
    8585
    86           if ((coordinates != null) && (coordinates.Rows > 0) && (coordinates.Columns == 2)) {
     86          if ((coordinates != null) && (coordinates.Rows > 0) && (coordinates.Columns == 2)
     87            && (scores != null) && (coordinates.Rows == scores.Length)) {
    8788            double xMin = double.MaxValue, yMin = double.MaxValue, xMax = double.MinValue, yMax = double.MinValue;
    8889            for (int i = 0; i < coordinates.Rows; i++) {
     
    116117              for (int i = 0; i < points.Length; i++) {
    117118                double score = scores[i];
    118                 int size = (int)Math.Round(((score - scoreMin) / scoreRange) * 9 + 1);
     119                int size = (int)Math.Round(((score - scoreMin) / scoreRange) * 8 + 2);
    119120                graphics.FillRectangle(Brushes.Red, points[i].X - size / 2, points[i].Y - size / 2, size, size);
    120121              }
Note: See TracChangeset for help on using the changeset viewer.