32 halp_meta(name,
"Texture Info")
33 halp_meta(category,
"Visuals/Utilities")
34 halp_meta(c_name,
"texture_info")
35 halp_meta(manual_url,
"https://ossia.io/score-docs/processes/texture-info.html")
36 halp_meta(uuid,
"5bd9c8e2-7f1a-4e3b-9c0d-2a4b6f8e1d72")
40 halp::gpu_texture_input<
"Texture"> texture;
45 halp::val_port<
"Width",
int> width;
46 halp::val_port<
"Height",
int> height;
47 halp::val_port<
"Format", std::string> format;
51 halp::val_port<
"Handle", int64_t> handle;
52 halp::val_port<
"Readable", std::string> readable;
55 static std::string_view format_name(halp::gpu_texture::format_t f)
noexcept
57 using F = halp::gpu_texture;
81 const auto& t = inputs.texture.texture;
82 const auto fmt_name = format_name(t.format);
84 outputs.width.value = t.width;
85 outputs.height.value = t.height;
86 outputs.format.value = std::string{fmt_name};
87 outputs.handle.value =
reinterpret_cast<std::int64_t
>(t.handle);
89 auto& ret = outputs.readable.value;
92 std::back_inserter(ret),
"{}x{} {} (handle=0x{:x})", t.width, t.height,
93 fmt_name,
reinterpret_cast<std::uintptr_t
>(t.handle));
Definition TextureInfo.hpp:30