[ismrmrd] 54/177: Fixed memory allocation for trajectory in C++ wrapper.

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Wed Jan 14 20:02:02 UTC 2015


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to annotated tag v1.1.0.beta.1
in repository ismrmrd.

commit 67dd87226c0bfea9f1f95d38e35fc612b0e56a88
Author: Souheil Inati <souheil.inati at nih.gov>
Date:   Tue Sep 16 21:58:38 2014 -0400

    Fixed memory allocation for trajectory in C++ wrapper.
---
 ismrmrd.cpp | 8 +++++++-
 ismrmrd.h   | 3 ++-
 2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/ismrmrd.cpp b/ismrmrd.cpp
index ad05392..8fa7359 100644
--- a/ismrmrd.cpp
+++ b/ismrmrd.cpp
@@ -127,10 +127,16 @@ uint16_t &Acquisition::encoding_space_ref() {
     return head.encoding_space_ref;
 }
 
-uint16_t &Acquisition::trajectory_dimensions() {
+const uint16_t &Acquisition::trajectory_dimensions() {
     return head.trajectory_dimensions;
 }
 
+void Acquisition::trajectory_dimensions(uint16_t traj_dim) {
+    head.trajectory_dimensions =  traj_dim;
+    ismrmrd_make_consistent_acquisition(this);
+}
+
+
 float &Acquisition::sample_time_us() {
     return head.sample_time_us;
 }
diff --git a/ismrmrd.h b/ismrmrd.h
index e71e501..1a886b6 100644
--- a/ismrmrd.h
+++ b/ismrmrd.h
@@ -416,7 +416,8 @@ public:
     uint16_t &discard_post();
     uint16_t &center_sample();
     uint16_t &encoding_space_ref();
-    uint16_t &trajectory_dimensions();
+    const uint16_t &trajectory_dimensions();
+    void trajectory_dimensions(uint16_t traj_dim);
     float &sample_time_us();
     float (&position())[3];
     float (&read_dir())[3];

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/ismrmrd.git



More information about the debian-science-commits mailing list