CorTeX
Core ABI 7
ToolTech Software · C++ library reference
ToolTech
CorTeX overview
Programmer’s manual
Class reference
Change history
CycloPos ↗
Toggle main menu visibility
Loading...
Searching...
No Matches
include
ctxUtilities.h
Go to the documentation of this file.
1
//*****************************************************************************
2
// File : ctxUtilities.h
3
// Description : Utilities and nice to have functions
4
// Author : Anders Modén
5
// Product : CorTeX 2.0.1
6
//
7
// Copyright © 2015- Anders Modén, Sweden
8
//
9
// NOTE: CorTeX is a software development kit (SDK)
10
// for neural networks and genetic programming.
11
// Licensed by Anders Modén.
12
//
13
//
14
// Revision History...
15
//
16
// Who Date Description
17
//
18
// AMO 150708 Created file (1.0.0)
19
// AMO 261015 Allow automatic process uptime for monitor values (2.0.2)
20
//
21
//******************************************************************************
22
#ifndef __CTX_UTILITIES_H__
23
#define __CTX_UTILITIES_H__
24
25
#include "
ctxBase.h
"
26
27
class
ctxCortexDataMonitor
:
public
gzPerformanceMonitorInterface ,
public
gzReference
28
{
29
public
:
30
31
CTX_EXPORT
ctxCortexDataMonitor
(gzArgumentParser &arg);
32
CTX_EXPORT
ctxCortexDataMonitor
(
const
gzString &arg=GZ_EMPTY_STRING);
33
34
CTX_EXPORT
virtual
~ctxCortexDataMonitor
();
35
36
CTX_EXPORT
virtual
gzVoid
enter
(
const
gzString &monitor);
37
CTX_EXPORT
virtual
gzVoid
leave
(
const
gzString &monitor);
39
CTX_EXPORT
virtual
gzVoid
addValue
(
const
gzString &monitor,
const
gzDynamicType &value,
const
gzDouble &time=-1,
const
gzUInt32 &instanceID=0);
40
41
private
:
42
43
gzSerializeAdapterPtr m_adapter;
44
};
45
46
GZ_DECLARE_REFPTR(
ctxCortexDataMonitor
);
47
48
inline
gzUInt32
ctxFloatToUInt32
(
const
gzFloat &val)
49
{
50
return
*(gzUInt32 *)&val;
51
}
52
53
inline
gzFloat
ctxUInt32ToFloat
(
const
gzUInt32 &val)
54
{
55
return
*(gzFloat *)&val;
56
}
57
58
CTX_EXPORT
gzUInt32
compileTempTokens
(gzDynamicArray<gzUInt32> &commands,gzUInt32 command,gzUInt32 sum_count,gzUInt32 steps,gzUInt32 in_id,gzUInt32 shortToken=0);
59
60
61
#endif
//__CTX_UTILITIES_H__
62
63
64
65
ctxCortexDataMonitor
Definition
ctxUtilities.h:28
ctxCortexDataMonitor::ctxCortexDataMonitor
ctxCortexDataMonitor(const gzString &arg=GZ_EMPTY_STRING)
ctxCortexDataMonitor::enter
virtual gzVoid enter(const gzString &monitor)
ctxCortexDataMonitor::leave
virtual gzVoid leave(const gzString &monitor)
ctxCortexDataMonitor::~ctxCortexDataMonitor
virtual ~ctxCortexDataMonitor()
ctxCortexDataMonitor::addValue
virtual gzVoid addValue(const gzString &monitor, const gzDynamicType &value, const gzDouble &time=-1, const gzUInt32 &instanceID=0)
Negative time selects process uptime; explicit nonnegative coordinates are preserved.
ctxCortexDataMonitor::ctxCortexDataMonitor
ctxCortexDataMonitor(gzArgumentParser &arg)
ctxBase.h
CTX_EXPORT
#define CTX_EXPORT
Definition
ctxBase.h:68
ctxUInt32ToFloat
gzFloat ctxUInt32ToFloat(const gzUInt32 &val)
Definition
ctxUtilities.h:53
compileTempTokens
gzUInt32 compileTempTokens(gzDynamicArray< gzUInt32 > &commands, gzUInt32 command, gzUInt32 sum_count, gzUInt32 steps, gzUInt32 in_id, gzUInt32 shortToken=0)
ctxFloatToUInt32
gzUInt32 ctxFloatToUInt32(const gzFloat &val)
Definition
ctxUtilities.h:48
Generated by
1.18.0