From 5232d987c12c5897ff3ade36acd2a6cb62d50cee Mon Sep 17 00:00:00 2001 From: jpekkila Date: Mon, 5 Aug 2019 16:18:22 +0300 Subject: [PATCH] Added acStoreWithOffset to the revised interface --- include/astaroth.h | 2 ++ src/core/astaroth.cu | 6 ++++++ 2 files changed, 8 insertions(+) diff --git a/include/astaroth.h b/include/astaroth.h index fbfdb05..94d7e17 100644 --- a/include/astaroth.h +++ b/include/astaroth.h @@ -62,6 +62,8 @@ AcReal acReduceScal(const ReductionType rtype, const VertexBufferHandle vtxbuf_h AcReal acReduceVec(const ReductionType rtype, const VertexBufferHandle a, const VertexBufferHandle b, const VertexBufferHandle c); +AcResult acStoreWithOffset(const int3 dst, const size_t num_vertices, AcMesh* host_mesh); + #ifdef __cplusplus } // extern "C" #endif diff --git a/src/core/astaroth.cu b/src/core/astaroth.cu index 8ea0d68..d47748c 100644 --- a/src/core/astaroth.cu +++ b/src/core/astaroth.cu @@ -98,3 +98,9 @@ acReduceVec(const ReductionType rtype, const VertexBufferHandle a, const VertexB acNodeReduceVec(nodes[0], STREAM_DEFAULT, rtype, a, b, c, &result); return result; } + +AcResult +acStoreWithOffset(const int3 dst, const size_t num_vertices, AcMesh* host_mesh) +{ + return acNodeStoreMeshWithOffset(nodes[0], STREAM_DEFAULT, dst, dst, num_vertices, host_mesh); +}