jeudi 11 juillet 2019

create chain from abstract class

I have an assignment so I'm not really looking for someone to solve it, just want to understand what's actually requested because I feel like it's poorly worded.

1. Please implement the function described in the comment of this incomplete code snippet



// AudioEffect is the base class for effects that can process
// audio and have a subsequent effect (next).
struct AudioEffect {
virtual ~AudioEffect() = default;
virtual void process(float* buf, size_t num) = 0;
std::shared_ptr<AudioEffect> next;
};
// Implement a function that checks if there is a feedback loop
// in the effects chain.
... detect_feedback(...)
{
}

Aucun commentaire:

Enregistrer un commentaire