Path Tracer
Functions
Object3DGroup.cpp File Reference
#include "Object3DGroup.h"
Include dependency graph for Object3DGroup.cpp:

Functions

std::ostream & operator<< (std::ostream &stream, const Object3DGroup &group)
 Ostream operator. More...
 
std::vector< Object3D * > split (const std::vector< Object3DGroup > &groups)
 Takes the std::vector of each object group and merge them. More...
 
void to_json (json &j, const Object3DGroup &group)
 Conversion to json. More...
 
void from_json (const json &j, Object3DGroup &group)
 Conversion from json. More...
 

Function Documentation

◆ from_json()

void from_json ( const json j,
Object3DGroup group 
)

Conversion from json.

Used for the .get<Object3DGroup>() function.

Parameters
jJson input.
groupThe ouput object group.

◆ operator<<()

std::ostream & operator<< ( std::ostream &  stream,
const Object3DGroup group 
)

Ostream operator.

Parameters
streamThe ostream before.
groupThe group that will be added to the stream.
Returns
The stream with the group added.

◆ split()

std::vector< Object3D * > split ( const std::vector< Object3DGroup > &  groups)

Takes the std::vector of each object group and merge them.

Parameters
groupsThe object group that will be merges.
Returns
All the objects of the object groups.
Warning
The pointers are not deeply copied.

◆ to_json()

void to_json ( json j,
const Object3DGroup group 
)

Conversion to json.

Parameters
jJson output.
groupThe object group that will be converted.