Changeset 1130 for cpp/frams/genetics/f9


Ignore:
Timestamp:
04/16/21 15:55:34 (3 years ago)
Author:
Maciej Komosinski
Message:

Used std::min(), std::max() explicitly to avoid compiler confusion. Used std::size() explicitly instead of the equivalent macro

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpp/frams/genetics/f9/f9_conv.cpp

    r1108 r1130  
    11// This file is a part of Framsticks SDK.  http://www.framsticks.com/
    2 // Copyright (C) 1999-2020  Maciej Komosinski and Szymon Ulatowski.
     2// Copyright (C) 1999-2021  Maciej Komosinski and Szymon Ulatowski.
    33// See LICENSE.txt for details.
    44
     
    66#include <frams/model/model.h>
    77#include <string.h>
    8 #include <common/nonstd_stl.h> //ARRAY_LENGTH
    98
    109#define APPLY_DETERMINISTIC_BODY_NOISE //this genetic representation easily produces perfectly vertical sticks that would stay upright forever in simulation. In most cases such infinite perfection is not desired, so we make the construct less perfect by perturbing its coordinates.
     
    129128        static int g[] = { 0, 1, 1, 1, 0, 0 };
    130129        static int b[] = { 0, 0, 0, 1, 1, 1 };
    131         int maxind = ARRAY_LENGTH(r) - 1;
     130        int maxind = int(std::size(r)) - 1;
    132131
    133132        int joints_count = m.getJointCount();
Note: See TracChangeset for help on using the changeset viewer.