Loading...
Searching...
No Matches
PCLToGeometry.hpp
1#pragma once
2
3#include <Threedim/TinyObj.hpp>
4#include <halp/buffer.hpp>
5#include <halp/controls.hpp>
6#include <halp/geometry.hpp>
7#include <halp/meta.hpp>
8
9namespace Threedim
10{
11
13{
14public:
15 halp_meta(name, "Pointcloud to mesh")
16 halp_meta(category, "Visuals/Meshes")
17 halp_meta(c_name, "pointcloud_to_mesh")
18 halp_meta(description, "Interpret a GPU point-cloud buffer as renderable geometry using the selected point layout.")
19 halp_meta(manual_url, "https://ossia.io/score-docs/processes/pointcloud-to-mesh.html")
20 halp_meta(uuid, "2450ffbf-04ed-4b42-8848-69f200d2742a")
21
22 enum BufferType
23 {
24 XYZ,
25 XYZ_RGB,
26 XYZW,
27 XYZW_RGBA
28 };
29 struct ins
30 {
31 halp::gpu_buffer_input<"Buffer"> in;
32 PositionControl position;
33 RotationControl rotation;
34 ScaleControl scale;
35 halp::enum_t<BufferType, "Buffer type"> type;
36 } inputs;
37
38 struct
39 {
40 struct
41 {
42 // Use Noiuse::dynamic_geometry
43 halp_meta(name, "Geometry");
44 halp::dynamic_gpu_geometry mesh;
45 float transform[16]{};
46 bool dirty_mesh = false;
47 bool dirty_transform = false;
48 } geometry;
49 } outputs;
50
51 PCLToMesh2();
52 void operator()();
53
54private:
55 int64_t m_warnedBytes{-1};
56 int m_warnedStride{-1};
57};
58}
Definition PCLToGeometry.hpp:13
Definition PCLToGeometry.hpp:30
Definition TinyObj.hpp:98
Definition TinyObj.hpp:103
Definition TinyObj.hpp:107
Definition TinyObj.hpp:27