HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
functions.h File Reference
#include "pxr/pxr.h"
#include "pxr/base/vt/api.h"
#include "pxr/base/vt/array.h"
#include <hboost/preprocessor/enum_params.hpp>
#include <hboost/preprocessor/iterate.hpp>
#include <hboost/preprocessor/repeat.hpp>
#include <vector>
#include <HBOOST_PP_ITERATE()>
+ Include dependency graph for functions.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define VT_FUNCTIONS_MAX_ARGS   6
 
#define HBOOST_PP_ITERATION_PARAMS_1
 
#define VTFUNCTION_BOOL(funcname, op)
 

Functions

template<typename T >
bool VtAnyTrue (VtArray< T > const &a)
 
template<typename T >
bool VtAllTrue (VtArray< T > const &a)
 

Macro Definition Documentation

#define HBOOST_PP_ITERATION_PARAMS_1
Value:
(4, \
(0, VT_FUNCTIONS_MAX_ARGS, "pxr/base/vt/functions.h", 0))
#define VT_FUNCTIONS_MAX_ARGS
Definition: functions.h:41

Definition at line 47 of file functions.h.

#define VT_FUNCTIONS_MAX_ARGS   6

Definition at line 41 of file functions.h.

#define VTFUNCTION_BOOL (   funcname,
  op 
)

Definition at line 244 of file functions.h.

Function Documentation

template<typename T >
bool VtAllTrue ( VtArray< T > const a)

Returns true if every element of input array is not VtZero, else false.

Intended to be used to evaluate results of boolean operations on arrays, e.g.

a = Vt.StringArray((3,),("foo","bar","baz"))
t = Vt.AllTrue(Vt.Equal(a,"bar"))

(This example, if you look carefully, evaluates this function not on the strings, but on the results of the comparison).

Definition at line 221 of file functions.h.

template<typename T >
bool VtAnyTrue ( VtArray< T > const a)

Returns true if any element of input array is not VtZero, else false.

Intended to be used to evaluate results of boolean operations on arrays, e.g.

a = Vt.StringArray((3,),("foo","bar","baz"))
t = Vt.AnyTrue(Vt.Equal(a,"bar"))

(This example, if you look carefully, evaluates this function not on the strings, but on the results of the comparison).

Definition at line 195 of file functions.h.