3#include <Threedim/TinyObj.hpp>
4#include <halp/audio.hpp>
5#include <halp/geometry.hpp>
6#include <halp/meta.hpp>
12 halp_meta(category,
"Visuals/3D/Primitives")
13 halp_meta(author,
"Jean-Michaël Celerier, vcglib")
14 halp_meta(manual_url,
"https://ossia.io/score-docs/processes/meshes.html#primitive")
18 std::vector<float> complete;
26 halp_meta(category,
"Visuals/3D/Primitives")
27 halp_meta(author,
"Jean-Michaël Celerier, vcglib")
28 halp_meta(manual_url,
"https://ossia.io/score-docs/processes/meshes.html#primitive")
29 halp_meta(name,
"Plane")
30 halp_meta(c_name,
"3d_plane")
31 halp_meta(uuid,
"1e923d52-3494-49e8-8698-b001405000da")
38 halp::spinbox_i32<
"H divs.", halp::range{1, 1000, 16}> hdivs;
39 halp::spinbox_i32<
"V divs.", halp::range{1, 1000, 16}> vdivs;
46 halp_meta(name,
"Geometry");
47 halp::position_normals_texcoords_geometry_plane
mesh;
48 float transform[16]{};
49 bool dirty_mesh =
false;
50 bool dirty_transform =
false;
54 void prepare(halp::setup) { update(); }
58 std::vector<float> complete;
64 halp_meta(name,
"Cube")
65 halp_meta(c_name,
"3d_cube")
66 halp_meta(uuid,
"cf8a328a-1ba6-47f8-929f-2168bdec90b0")
75 void prepare(halp::setup) { update(); }
82 halp_meta(name,
"Sphere")
83 halp_meta(c_name,
"3d_sphere")
84 halp_meta(uuid,
"fc0df335-d0e9-4ebf-b438-6ba334741c1a")
92 : halp::hslider_i32<
"Subdivisions", halp::range{1, 5, 2}>
98 void prepare(halp::setup) { update(); }
104 halp_meta(name,
"Icosahedron")
105 halp_meta(c_name,
"3d_ico")
106 halp_meta(uuid,
"3ea9f69f-1a0e-49c2-ad16-a88e9ca628a7")
115 void prepare(halp::setup) { update(); }
121 halp_meta(name,
"Cone")
122 halp_meta(c_name,
"3d_cone")
123 halp_meta(uuid,
"8a5718c4-07f0-476b-b720-1c99e5a379a5")
131 : halp::hslider_i32<
"Subdivisions", halp::range{1, 500, 36}>
136 : halp::hslider_f32<
"R1", halp::range{0, 1000, 1}>
141 : halp::hslider_f32<
"R2", halp::range{0, 1000, 10}>
146 : halp::hslider_f32<
"Height", halp::range{0, 1000, 5}>
152 void prepare(halp::setup) { update(); }
158 halp_meta(name,
"Cylinder")
159 halp_meta(c_name,
"3d_cylinder")
160 halp_meta(uuid,
"5992830e-80fe-4461-b357-2c9b5c5e48ae")
168 : halp::hslider_i32<
"Slices", halp::range{1, 1000, 64}>
173 : halp::hslider_i32<
"Stacks", halp::range{1, 1000, 64}>
179 void prepare(halp::setup) { update(); }
185 halp_meta(name,
"Torus")
186 halp_meta(c_name,
"3d_torus")
187 halp_meta(uuid,
"85c5983c-3f4f-4bfe-b8cf-fccdf6ec5faf")
195 : halp::hslider_f32<
"R1", halp::range{0, 100, 10}>
200 : halp::hslider_f32<
"R2", halp::range{0, 100, 1}>
205 : halp::hslider_i32<
"H Divisions", halp::range{1, 50, 24}>
210 : halp::hslider_i32<
"V Divisions", halp::range{1, 50, 12}>
216 void prepare(halp::setup) { update(); }
Definition Primitive.hpp:120
Definition Primitive.hpp:62
Definition Primitive.hpp:157
Definition Primitive.hpp:103
Definition Primitive.hpp:24
Definition TinyObj.hpp:63
Definition Primitive.hpp:11
Definition TinyObj.hpp:82
Definition TinyObj.hpp:68
Definition TinyObj.hpp:72
Definition Primitive.hpp:80
Definition Primitive.hpp:184
Definition TinyObj.hpp:77
Definition TinyObj.hpp:18