Refactor and fold in code into Process in mjCMesh for caching.
PiperOrigin-RevId: 736052216 Change-Id: Ia0e055fd99ce429b9dee97f3f9effbf2fa1aa4f9
This commit is contained in:
committed by
Copybara-Service
parent
b9a23e8d0c
commit
995bbf0f0f
@@ -15,6 +15,7 @@
|
||||
#ifndef MUJOCO_SRC_USER_USER_UTIL_H_
|
||||
#define MUJOCO_SRC_USER_USER_UTIL_H_
|
||||
|
||||
#include <algorithm>
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
#include <optional>
|
||||
@@ -46,9 +47,7 @@ void mjuu_setvec(double* dest, double x, double y);
|
||||
// copy real-valued vector
|
||||
template <class T1, class T2>
|
||||
void mjuu_copyvec(T1* dest, const T2* src, int n) {
|
||||
for (int i=0; i<n; i++) {
|
||||
dest[i] = (T1)src[i];
|
||||
}
|
||||
std::copy(src, src + n, dest);
|
||||
}
|
||||
|
||||
// add to double array
|
||||
|
||||
Reference in New Issue
Block a user