@fellhouseaudio said in C++ API: SliderBase cannot find Constant Modulator (SIGSEV):
reach a SIGSEV in RootObject.h:61
I opened a github issue
@fellhouseaudio said in C++ API: SliderBase cannot find Constant Modulator (SIGSEV):
reach a SIGSEV in RootObject.h:61
I opened a github issue
@fellhouseaudio Anyone have any thoughts on this? Should i open up a github issue?
Hi,
I am trying to connect a juce::Slider in my custom c++ floating panel to a Constant Modulator in my hise project. I'm following along with info I found in an old forum post from 2021 (C++ API: How to connect Intensity to Slider). The code is crashing. After debugging I find that the SliderBase is unable to find the Constant Modulator by looking it up by ID. I have double checked that the IDs match. I don't really know how to proceed from here.
Here is the gist of my code:
class ExternalWaveformDisplayPlaybackControlComponent
: public hise::FloatingTileContent,
public FileDragAndDropTarget,
public Component {
public:
SET_PANEL_NAME("ExternalWaveformDisplayPlaybackControlComponent");
ExternalWaveformDisplayPlaybackControlComponent(FloatingTile *parent)
: mc(getMainController()), FloatingTileContent(parent),
testSlide(juce::Slider("Test2")),
sampleStartConnection(&testSlide, mc, "SampleStartConstantMod")
{
sampleStartConnection.setData<raw::Data<float>::Intensity>();
}
...
hise::MainController *mc;
juce::Slider testSlide;
hise::raw::UIConnection::SliderBase sampleStartConnection;
};
The segfault happens on the call to setData
as it was unable to find any node for id "SampleStartConstantMod". The output from the debug window makes it look like it was looking for a node by the id "Constant1" which is weird...
Constant1 was not found.
Modulator Invalid Modulator does not exist.
JUCE Assertion failure in raw_misc.h:346
The actual nullptr access happens in hise::raw::Data<float>::Intensity::save (p=0x0) at raw_misc.h:346
Has anyone done something like this recently? Am I on the right track?
Thanks,
David
EDIT:
I am beginning to think this is a bug in the API... If I name my Constant Modulator "Constant1" I get further but still eventually reach a SIGSEV in RootObject.h:61
. While I don't know why we are getting a nullptr access in that class the fact that SliderBase is looking for "Constant1" instead of the id provided in the constructor seems to be an issue.