Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge release/omega (7.8.1) branch into master #642

Merged
merged 27 commits into from
Sep 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
d6e549a
VH 1319 - Updated the script to support versions that have multi arch…
DokurOmkar Jul 23, 2024
bac1ef2
VH 1319 - Updated the add user script to support both plain and sha2 …
DokurOmkar Jul 25, 2024
cfd4369
VH 1319 - Updated the script based on PR feedback
DokurOmkar Jul 26, 2024
2b9f38f
VH 1319 - Make V2X-Hub previous releases to support multi architectur…
DokurOmkar Jul 26, 2024
2303a49
Vh 1216 fix spat plugin segfault simulation (#621)
paulbourelly999 Jul 31, 2024
799b0a8
Initial commit for integration testing port drayage with C1T
willjohnsonk Jul 31, 2024
9b97cf6
First pass at sql script configuration for C1T Port Drayage locations
willjohnsonk Jul 31, 2024
42a9cc3
Added stopping locations for Port Drayage based on route graph nodes
willjohnsonk Aug 1, 2024
4847aa7
Install carma-clock-1 from ubuntu distribution (correct version) (#627)
paulbourelly999 Aug 1, 2024
be5a5af
FCP-5: SensorDetectedObject TMX message definition (#628)
dan-du-car Aug 13, 2024
532ea70
Added .sql files for each port pickup lane option, updated docker com…
willjohnsonk Aug 14, 2024
eb539af
Fix ped plugin (#620)
jwillmartin Aug 16, 2024
576e484
Update detection classifications in MUSTSensorDriverPlugin (#631)
dan-du-car Aug 22, 2024
162d0d7
Added configurations for newest port drayage layout for C1T with two …
willjohnsonk Aug 22, 2024
1615eb5
MustSensorDriverPlugin: Convert the classification confidence to deci…
dan-du-car Aug 28, 2024
6c4151e
Sync develop to master (#635)
SaikrishnaBairamoni Aug 29, 2024
dd1a417
Add position and velocity covariance matrix for MUST sensor detection…
paulbourelly999 Aug 29, 2024
4f12a4d
Updated docker-compose file to add comment addressing usage of sql fi…
willjohnsonk Aug 29, 2024
02fd2a5
Updated readme for mysql garage configuration
willjohnsonk Aug 30, 2024
4f3d360
Added documentation to visualize the Port Drayage layout
willjohnsonk Sep 3, 2024
e4a709f
Updated reference locations in base sql file
willjohnsonk Sep 3, 2024
f30f2fe
Corrected filepath
willjohnsonk Sep 3, 2024
817fd9a
Added SQL files for use with C1T Port Drayage configuration with dock…
maefromm Sep 3, 2024
755bdad
Made Port Drayage destinations as stored in the SQL database more spe…
willjohnsonk Sep 4, 2024
e7ecbc2
Updated the Port Exit location to better correspond with the appropri…
willjohnsonk Sep 4, 2024
7dd7a90
Update Release_notes.md
SaikrishnaBairamoni Sep 11, 2024
1eac9d7
Merge branch 'master' into release/omega
SaikrishnaBairamoni Sep 11, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion .sonarqube/sonar-scanner.properties
Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,16 @@ sonar.modules= PedestrianPlugin, \
CDASimAdapter, \
RSUHealthMonitorPlugin, \
TelematicBridgePlugin, \
MUSTSensorDriverPlugin
MUSTSensorDriverPlugin, \
Messages



TmxCore.sonar.projectBaseDir =src/tmx/TmxCore
TmxCtl.sonar.projectBaseDir =src/tmx/TmxCtl
TmxTools.sonar.projectBaseDir =src/tmx/TmxTools
TmxUtils.sonar.projectBaseDir =src/tmx/TmxUtils
Messages.sonar.projectBaseDir =src/tmx/Messages
CARMACloudPlugin.sonar.projectBaseDir =src/v2i-hub/CARMACloudPlugin
CommandPlugin.sonar.projectBaseDir =src/v2i-hub/CommandPlugin
CswPlugin.sonar.projectBaseDir =src/v2i-hub/CswPlugin
Expand Down Expand Up @@ -97,6 +99,7 @@ TmxCore.sonar.sources =src
TmxCtl.sonar.sources =src
TmxTools.sonar.sources =src
TmxUtils.sonar.sources =src
Messages.sonar.sources =include
TmxUtils.sonar.exclusions =test/**
MessageLoggerPlugin.sonar.sources =src
CswPlugin.sonar.sources =src
Expand Down Expand Up @@ -132,6 +135,7 @@ MUSTSensorDriverPlugin.sonar.sources =src
# Tests
# Note: For C++ setting this field does not cause test analysis to occur. It only allows the test source code to be evaluated.
TmxUtils.sonar.tests=test
Messages.sonar.tests=test
#TmxCore.sonar.tests=test
#TmxCtl.sonar.tests=test
#TmxTools.sonar.tests=test
Expand Down
7 changes: 7 additions & 0 deletions configuration/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,13 @@ services:
volumes:
- ./mysql/localhost.sql:/docker-entrypoint-initdb.d/localhost.sql
- ./mysql/port_drayage.sql:/docker-entrypoint-initdb.d/port_drayage.sql
# The following 3 volumes are used for C1T. By default the standard "port_drayage.sql" file
# will be loaded. Comment out the "port_drayage.sql" file above and uncomment the following
# three files to enable the C1T sql files to be loaded. The container volumes MUST be reset
# to allow for this change, which can be done with "docker compose down -v"
#- ./mysql/garage_port_drayage/port_drayage.sql:/docker-entrypoint-initdb.d/port_drayage.sql
#- ./mysql/garage_port_drayage/port_drayage_lane1.sql:/docker-entrypoint-initdb.d/port_drayage_lane1.sql
#- ./mysql/garage_port_drayage/port_drayage_lane2.sql:/docker-entrypoint-initdb.d/port_drayage_lane2.sql
- mysql-datavolume:/var/lib/mysql

php:
Expand Down
9 changes: 5 additions & 4 deletions configuration/initialization.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,16 @@ latest_version=$(echo "$release_info" | grep -o '"tag_name": *"[^"]*"' | cut -d
# Fetching all tags from Git repository
tags=$(git ls-remote --tags https://github.com/usdot-fhwa-OPS/V2X-Hub.git | awk -F/ '{print $3}' | sort -V)

# Remove curly braces, Properties found, and duplicate entries
updated_tags=$(echo "$tags" | sed 's/\^{}//' | grep -v '^Properties_Found$' | awk '!seen[$0]++')
# Remove curly braces, Properties found, duplicate entries, and show only versions above 7.0
updated_tags=$(echo "$tags" | sed 's/\^{}//;s/^v//' | grep -v '^Properties_Found$' | awk '!seen[$0]++ && $1 >= "7.0"')

# Displaying all available versions
echo "Note: V2X-Hub multi architecture deployments only work for the versions 7.0 and above."
echo "Available versions:"
echo "$updated_tags"

# select a version or accept the latest version as default
read -r -p "Enter V2X-Hub Version (choose from the above, or press Enter to use latest version $latest_version): " chosen_version
read -r -p "Enter V2X-Hub Version (choose from the above, or press Enter to use the latest version $latest_version): " chosen_version
V2XHUB_VERSION=${chosen_version:-$latest_version}

# Enable Port Drayage functionality
Expand Down Expand Up @@ -149,6 +150,6 @@ fi

# Create V2X Hub user
cd "$mysqlDir" || return # return in case cd fails
./add_v2xhub_user.bash
./add_v2xhub_user.bash "$V2XHUB_VERSION"

chromium-browser --ignore-certificate-errors localhost > /dev/null 2>&1 &
17 changes: 16 additions & 1 deletion configuration/mysql/add_v2xhub_user.bash
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,16 @@
# Fail when any command fails
#set -e

# Check if V2XHUB_VERSION is passed
if [ -n "$1" ]; then
V2XHUB_VERSION="$1"
else
# Prompt user for V2XHUB_VERSION
read -r -p "Enter the deployed V2X-Hub version number: " V2XHUB_VERSION
fi

echo "Adding V2X-Hub user for version: $V2XHUB_VERSION"

# Ensure mysql-client is installed
arch=$(dpkg --print-architecture)
# TODO: Add a common mysql-client that works for ARM and AMD devices
Expand Down Expand Up @@ -34,7 +44,12 @@ if [ $PASS_LENGTH -ge 8 ] && echo $PASS | grep -q [a-z] && echo $PASS | grep -q
done
echo "VALID PASSWORD"
echo "Enter MYSQL ROOT PASSWORD: "
mysql -uroot -p --silent -h127.0.0.1 -e "INSERT INTO IVP.user (IVP.user.username, IVP.user.password, IVP.user.accessLevel) VALUES('$USER', SHA2('$PASS', 256), 3)"
# Check if V2XHUB_VERSION is >= 7.5.0
if [[ "$(echo "$V2XHUB_VERSION 7.5.0" | awk '{print ($1 >= $2)}')" -eq 1 ]]; then
mysql -uroot -p --silent -h127.0.0.1 -e "INSERT INTO IVP.user (IVP.user.username, IVP.user.password, IVP.user.accessLevel) VALUES('$USER', SHA2('$PASS', 256), 3)"
else
mysql -uroot -p --silent -h127.0.0.1 -e "INSERT INTO IVP.user (IVP.user.username, IVP.user.password, IVP.user.accessLevel) VALUES('$USER', '$PASS', 3)"
fi
echo "V2X Hub user successfully added"
else
echo "INVALID PASSWORD"
Expand Down
18 changes: 18 additions & 0 deletions configuration/mysql/garage_port_drayage/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# C1T Garage Actions
These are Port Drayage actions created the CDA1Tenth functionality and specifically tailored for the Turner Fairbank Highway Research Center's Saxton Laboratory garage demonstration.

## Instructions
Replace the port_drayage.sql file in docker-compose.yml with the files in this directory.
```
db:
image: mysql:8.0
volumes:
- ./mysql/garage_port_drayage/port_drayage.sql:/docker-entrypoint-initdb.d/port_drayage.sql
- ./mysql/garage_port_drayage/port_drayage_lane1.sql:/docker-entrypoint-initdb.d/port_drayage_lane1.sql
- ./mysql/garage_port_drayage/port_drayage_lane2.sql:/docker-entrypoint-initdb.d/port_drayage_lane2.sql
```

## Reference Layout
The following diagram displays the C1T Port Drayage layout used in the Saxton Garage. The above SQL files should be selected based on if the first (port_drayage_lane1.sql) or second (port_drayage_lane2.sql) lane will be used for the Port Pickup action.

![Alt text](docs/garage_diagram.PNG)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
49 changes: 49 additions & 0 deletions configuration/mysql/garage_port_drayage/port_drayage.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
-- MySQL 8.0 for Linux amd64 (x86_64) and arm64 (aarch64)
--
-- Host: 127.0.0.1 Database: PORT_DRAYAGE
-- ------------------------------------------------------
-- Server version 7.6.0
-- Current Database: `PORT_DRAYAGE`
--

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `PORT_DRAYAGE` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `PORT_DRAYAGE`;

--
-- Table structure for table `first_action`
--

DROP TABLE IF EXISTS `first_action`;
CREATE TABLE `first_action` (
`cmv_id` varchar(20) NOT NULL,
`cargo_id` varchar(20) DEFAULT NULL,
`destination_lat` decimal(9,7) NOT NULL,
`destination_long` decimal(9,7) NOT NULL,
`operation` varchar(20) NOT NULL,
`action_id` varchar(36) NOT NULL,
`next_action` varchar(36) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

LOCK TABLES `first_action` WRITE;
INSERT INTO `first_action` VALUES ('C1T-1','NULL',-2.46,0.56,'ENTER_STAGING_AREA','one','two');
UNLOCK TABLES;

--
-- Table structure for table `freight`
--

DROP TABLE IF EXISTS `freight`;
CREATE TABLE `freight` (
`cmv_id` varchar(20) NOT NULL,
`cargo_id` varchar(20) DEFAULT NULL,
`destination_lat` decimal(9,7) NOT NULL,
`destination_long` decimal(9,7) NOT NULL,
`operation` varchar(20) NOT NULL,
`action_id` varchar(36) NOT NULL,
`next_action` varchar(36) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

LOCK TABLES `freight` WRITE;
INSERT INTO `freight` VALUES ('C1T-1','NULL',-0.45,-0.45,'EXIT_PORT','zero','one'),('C1T-1','NULL',-2.46,0.56,'ENTER_STAGING_AREA','one','two'),('C1T-1','CARGO_A',-3.45,-1.44,'PICKUP','two','three'),('C1T-1','CARGO_A',-3.45,-3.45,'EXIT_STAGING_AREA','three','four'),('C1T-1','CARGO_A',-3.45,-5.45,'ENTER_PORT','four','five'),('C1T-1','CARGO_A',-1.45,-6.45,'DROPOFF','five','six'),('C1T-1','CARGO_B',2.55,-4.5,'PICKUP','six','seven'),('C1T-1','CARGO_B',0.55,-3.45,'PORT_CHECKPOINT','seven','eight'),('C1T-1','CARGO_B',-0.45,-0.45,'EXIT_PORT','eight','nine');
UNLOCK TABLES;
49 changes: 49 additions & 0 deletions configuration/mysql/garage_port_drayage/port_drayage_lane1.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
-- MySQL 8.0 for Linux amd64 (x86_64) and arm64 (aarch64)
--
-- Host: 127.0.0.1 Database: PORT_DRAYAGE
-- ------------------------------------------------------
-- Server version 7.6.0
-- Current Database: `PORT_DRAYAGE`
--

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `PORT_DRAYAGE` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `PORT_DRAYAGE`;

--
-- Table structure for table `first_action`
--

DROP TABLE IF EXISTS `first_action`;
CREATE TABLE `first_action` (
`cmv_id` varchar(20) NOT NULL,
`cargo_id` varchar(20) DEFAULT NULL,
`destination_lat` decimal(9,7) NOT NULL,
`destination_long` decimal(9,7) NOT NULL,
`operation` varchar(20) NOT NULL,
`action_id` varchar(36) NOT NULL,
`next_action` varchar(36) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

LOCK TABLES `first_action` WRITE;
INSERT INTO `first_action` VALUES ('C1T-1','NULL',-2.46,0.56,'ENTER_STAGING_AREA','one','two');
UNLOCK TABLES;

--
-- Table structure for table `freight`
--

DROP TABLE IF EXISTS `freight`;
CREATE TABLE `freight` (
`cmv_id` varchar(20) NOT NULL,
`cargo_id` varchar(20) DEFAULT NULL,
`destination_lat` decimal(9,7) NOT NULL,
`destination_long` decimal(9,7) NOT NULL,
`operation` varchar(20) NOT NULL,
`action_id` varchar(36) NOT NULL,
`next_action` varchar(36) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

LOCK TABLES `freight` WRITE;
INSERT INTO `freight` VALUES ('C1T-1','NULL',-0.45,-0.45,'EXIT_PORT','zero','one'),('C1T-1','NULL',-2.46,0.56,'ENTER_STAGING_AREA','one','two'),('C1T-1','CARGO_A',-3.45,-1.44,'PICKUP','two','three'),('C1T-1','CARGO_A',-3.45,-3.45,'EXIT_STAGING_AREA','three','four'),('C1T-1','CARGO_A',-3.45,-5.45,'ENTER_PORT','four','five'),('C1T-1','CARGO_A',-1.45,-6.45,'DROPOFF','five','six'),('C1T-1','CARGO_B',1.55,-4.5,'PICKUP','six','seven'),('C1T-1','CARGO_B',0.55,-3.45,'PORT_CHECKPOINT','seven','eight'),('C1T-1','CARGO_B',-0.45,-0.45,'EXIT_PORT','eight','nine');
UNLOCK TABLES;
49 changes: 49 additions & 0 deletions configuration/mysql/garage_port_drayage/port_drayage_lane2.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
-- MySQL 8.0 for Linux amd64 (x86_64) and arm64 (aarch64)
--
-- Host: 127.0.0.1 Database: PORT_DRAYAGE
-- ------------------------------------------------------
-- Server version 7.6.0
-- Current Database: `PORT_DRAYAGE`
--

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `PORT_DRAYAGE` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `PORT_DRAYAGE`;

--
-- Table structure for table `first_action`
--

DROP TABLE IF EXISTS `first_action`;
CREATE TABLE `first_action` (
`cmv_id` varchar(20) NOT NULL,
`cargo_id` varchar(20) DEFAULT NULL,
`destination_lat` decimal(9,7) NOT NULL,
`destination_long` decimal(9,7) NOT NULL,
`operation` varchar(20) NOT NULL,
`action_id` varchar(36) NOT NULL,
`next_action` varchar(36) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

LOCK TABLES `first_action` WRITE;
INSERT INTO `first_action` VALUES ('C1T-1','NULL',-2.46,0.56,'ENTER_STAGING_AREA','one','two');
UNLOCK TABLES;

--
-- Table structure for table `freight`
--

DROP TABLE IF EXISTS `freight`;
CREATE TABLE `freight` (
`cmv_id` varchar(20) NOT NULL,
`cargo_id` varchar(20) DEFAULT NULL,
`destination_lat` decimal(9,7) NOT NULL,
`destination_long` decimal(9,7) NOT NULL,
`operation` varchar(20) NOT NULL,
`action_id` varchar(36) NOT NULL,
`next_action` varchar(36) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

LOCK TABLES `freight` WRITE;
INSERT INTO `freight` VALUES ('C1T-1','NULL',-0.45,-0.45,'EXIT_PORT','zero','one'),('C1T-1','NULL',-2.46,0.56,'ENTER_STAGING_AREA','one','two'),('C1T-1','CARGO_A',-3.45,-1.44,'PICKUP','two','three'),('C1T-1','CARGO_A',-3.45,-3.45,'EXIT_STAGING_AREA','three','four'),('C1T-1','CARGO_A',-3.45,-5.45,'ENTER_PORT','four','five'),('C1T-1','CARGO_A',-1.45,-6.45,'DROPOFF','five','six'),('C1T-1','CARGO_B',2.55,-4.5,'PICKUP','six','seven'),('C1T-1','CARGO_B',0.55,-3.45,'PORT_CHECKPOINT','seven','eight'),('C1T-1','CARGO_B',-0.45,-0.45,'EXIT_PORT','eight','nine');
UNLOCK TABLES;
11 changes: 11 additions & 0 deletions docs/Release_notes.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,17 @@
V2X-Hub Release Notes
---------------------------------

Version 7.8.1, released Sep 11th, 2024
--------------------------------------------------------

**Summary:**
V2X Hub release 7.8.1 includes additional SQL files which are created to store command sequences V2X Hub sends to a C1T vehicle to coordinate Port Drayage. These files contain actions and destination points configured to send the vehicle through a pre-designed mock port environment, with one instructing the vehicle to pick up cargo in Lane 1 and the other instructing the vehicle to proceed to Lane 2.

Enhancement in this release:

- V2X-Hub PR 639: Added SQL files for use with the C1T Port Drayage configuration and updated docker compose files to streamline deployment.
- V2X-Hub PR 641: Updated SQL Port Drayage action locations to improve accuracy in tracking port exits.

Version 7.8.0, released Aug 26th, 2024
--------------------------------------------------------

Expand Down
2 changes: 1 addition & 1 deletion examples/tmx-exampleapps/EmptyPlugin/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ PROJECT ( EmptyPlugin VERSION 3.0.0 LANGUAGES CXX )

BuildTmxPlugin ( )

TARGET_LINK_LIBRARIES (${PROJECT_NAME} tmxutils)
TARGET_LINK_LIBRARIES (${PROJECT_NAME} tmxutils pugixml)
2 changes: 1 addition & 1 deletion examples/tmx-exampleapps/EmptyPlugin/src/EmptyPlugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
#include <AppAlert.h>
#include <algorithm>
#include <tmx/messages/message_document.hpp>
#include <tmx/pugixml/pugixml.hpp>
#include <pugixml.hpp>
#include <ParsedMap.h>
#include <MapSupport.h>
#include <sstream>
Expand Down
8 changes: 8 additions & 0 deletions ext/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -72,3 +72,11 @@ make -j${numCPU}
make install
popd

# pugixml
pushd /tmp
git clone https://github.com/zeux/pugixml.git --branch v1.14
cd pugixml
cmake .
make -j${numCPU}
make install
popd
5 changes: 4 additions & 1 deletion scripts/install_dependencies.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@
# exit on errors
set -e

# Get ubuntu distribution code name. All STOL APT debian packages are pushed to S3 bucket based on distribution codename.
. /etc/lsb-release

# add the STOL APT repository
echo "deb [trusted=yes] http://s3.amazonaws.com/stol-apt-repository develop main" > /etc/apt/sources.list.d/stol-apt-repository.list
echo "deb [trusted=yes] http://s3.amazonaws.com/stol-apt-repository ${DISTRIB_CODENAME} main" > /etc/apt/sources.list.d/stol-apt-repository.list

apt-get update

Expand Down
15 changes: 15 additions & 0 deletions src/tmx/Messages/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,18 @@ SET (TMXMESSAGES_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/include" PARENT_SCOPE)
INSTALL (DIRECTORY include
DESTINATION . COMPONENT ${PROJECT_NAME}
FILES_MATCHING PATTERN "*.h*")

#############
## Testing ##
#############
enable_testing()

set(BINARY ${PROJECT_NAME}_test)

file(GLOB_RECURSE TEST_SOURCES LIST_DIRECTORIES false test/*.h test/*.cpp)

add_executable(${BINARY} ${TEST_SOURCES})

add_test(NAME ${BINARY} COMMAND ${BINARY})
target_include_directories(${BINARY} PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/include)
target_link_libraries(${BINARY} PUBLIC ${TMXAPI_LIBRARIES} gtest)
20 changes: 20 additions & 0 deletions src/tmx/Messages/include/Covariance.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#pragma once
#include <tmx/messages/message.hpp>
namespace tmx::messages
{
struct Covariance{
double value;
Covariance()=default;
explicit Covariance(double value):value(value){};
static message_tree_type to_tree(const Covariance& cov){
message_tree_type tree;
tree.put("",cov.value);
return tree;
}
static Covariance from_tree(const message_tree_type& tree){
Covariance cov;
cov.value = tree.get<double>("");
return cov;
}
};
}
Loading
Loading