Loading...
Searching...
No Matches
RenderedISFSamplerUtils.hpp
1#pragma once
2#include <Gfx/Graph/RenderList.hpp>
3#include <Gfx/Graph/RenderedISFUtils.hpp>
4
5#include <score/tools/Debug.hpp>
6
7namespace score::gfx
8{
9
10inline std::vector<Sampler>
11initAudioTextures(RenderList& renderer, std::list<AudioTexture>& textures)
12{
13 std::vector<Sampler> samplers;
14 QRhi& rhi = *renderer.state.rhi;
15 for(auto& texture : textures)
16 {
17 auto sampler = rhi.newSampler(
18 QRhiSampler::Linear, QRhiSampler::Linear, QRhiSampler::None,
19 QRhiSampler::ClampToEdge, QRhiSampler::ClampToEdge);
20 sampler->setName("ISFNode::initAudioTextures::sampler");
21 sampler->create();
22
23 samplers.push_back({sampler, &renderer.emptyTexture()});
24 texture.samplers[&renderer] = {sampler, nullptr};
25 }
26 return samplers;
27}
28
29}
Graphics rendering pipeline for ossia score.
Definition Filter/PreviewWidget.hpp:12