volmetrics
diff src/volume.h @ 9:40febfed6cff
rendering isosurfaces / added simple gui
author | Eleni Maria Stea <elene.mst@gmail.com> |
---|---|
date | Sun, 26 Jan 2014 23:13:37 +0200 |
parents | 928954bfefd7 |
children | 1272e3335608 |
line diff
1.1 --- a/src/volume.h Sat Jan 25 19:25:32 2014 +0200 1.2 +++ b/src/volume.h Sun Jan 26 23:13:37 2014 +0200 1.3 @@ -4,6 +4,8 @@ 1.4 #include <vector> 1.5 #include "image.h" 1.6 1.7 +class Mesh; 1.8 + 1.9 class Volume { 1.10 private: 1.11 std::vector<Image> slices; 1.12 @@ -25,13 +27,19 @@ 1.13 1.14 bool push_slice(Image &&slice); 1.15 const Image *get_slice(int num_slice) const; 1.16 + 1.17 + // z must be in [0, 1] 1.18 const Image *get_slice_by_z(float z) const; 1.19 + 1.20 int get_slice_count() const; 1.21 1.22 + // z must be in [0, 1] 1.23 int get_slice_idx_by_z(float z) const; 1.24 1.25 unsigned int get_texture() const; 1.26 1.27 + void create_mesh(Mesh *mesh, float threshold); 1.28 + 1.29 void draw() const; 1.30 }; 1.31