mirror of
https://github.com/facebookresearch/pytorch3d.git
synced 2025-08-02 03:42:50 +08:00
Use cuda's make_float3 in pulsar
Summary: Fixes github.com/facebookresearch/pytorch3d/issues/1680 Reviewed By: MichaelRamamonjisoa Differential Revision: D51587889 fbshipit-source-id: e68ae32d7041fb9ea3e981cf2bde47f947a41ca2
This commit is contained in:
parent
c373a84400
commit
6b8766080d
@ -56,6 +56,7 @@
|
|||||||
#pragma clang diagnostic pop
|
#pragma clang diagnostic pop
|
||||||
#ifdef WITH_CUDA
|
#ifdef WITH_CUDA
|
||||||
#include <ATen/cuda/CUDAContext.h>
|
#include <ATen/cuda/CUDAContext.h>
|
||||||
|
#include <vector_functions.h>
|
||||||
#else
|
#else
|
||||||
#ifndef cudaStream_t
|
#ifndef cudaStream_t
|
||||||
typedef void* cudaStream_t;
|
typedef void* cudaStream_t;
|
||||||
@ -74,13 +75,6 @@ struct float3 {
|
|||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
namespace py = pybind11;
|
namespace py = pybind11;
|
||||||
inline float3 make_float3(const float& x, const float& y, const float& z) {
|
|
||||||
float3 res;
|
|
||||||
res.x = x;
|
|
||||||
res.y = y;
|
|
||||||
res.z = z;
|
|
||||||
return res;
|
|
||||||
}
|
|
||||||
|
|
||||||
inline bool operator==(const float3& a, const float3& b) {
|
inline bool operator==(const float3& a, const float3& b) {
|
||||||
return a.x == b.x && a.y == b.y && a.z == b.z;
|
return a.x == b.x && a.y == b.y && a.z == b.z;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user