here the filtSliderVal is set to 0.5 but i want to assign it to the value of a slider in another class. the class is called FilePlayerGUI, the Slider is called filtSlider and to get the value of the slider I have to call filtSlider.getValue(). how do i call this function from the class FilePlayerGUI from within another class.
I'm having trouble understanding your question, because it looks like you answer it yourself, call filtSlider.getValue(). Are you saying filtSlider is a member of FilePlayerGUI?
What is the relationship of the class(s)
Is slider it's own class?
1 2 3 4 5
class Slider
{
//...
float getValue();
};
Is Slider a composite class of FilePlayerGUI?
1 2 3 4 5 6
class FilePlayerGUI
{
//...
Slider filtslider; //Is this the case? And if so just make a function that gets
//the value of filtslider that is part of the public interface for FilePlayerGUI
};