optoctreeparser
Loading...
Searching...
No Matches
optoctreeparser::Differ Class Reference

Differ to find difference between two OptocRoot. More...

#include <differ/differ.hpp>

Static Public Member Functions

static std::vector< OptocPatchTreefind_difference (const OptocRoot &old_root, const OptocRoot &new_root)
 Finds the difference between two OptocRoot *.
 

Detailed Description

Differ to find difference between two OptocRoot.

Member Function Documentation

◆ find_difference()

static std::vector< OptocPatchTree > optoctreeparser::Differ::find_difference ( const OptocRoot old_root,
const OptocRoot new_root 
)
static

Finds the difference between two OptocRoot *.

Parameters
old_rootThe old "base" batch. It is compared with new_root.
new_rootNew batch
Returns
std::vector with octrees (OptocPatchTree) from new_root that are either absent from old_root or have changed nodes
Note
This method is useful for creating OptocPatchRoot. For example, you have a base game patch - old_root, you made some changes and ended up with new_root, then you can call this method, which will return the octrees that have been changed. Then you can insert these octrees into the desired patch in OptocPatchRoot.

The documentation for this class was generated from the following file: