Skip to content

File line.h

File List > Control > line.h

Go to the documentation of this file

Source Code

/*
Copyright (c) 2023 Electrosmith, Corp, Barry Vercoe, John ffitch

Use of this source code is governed by the LGPL V2.1z
license that can be found in the LICENSE file or at
https://opensource.org/license/lgpl-2-1/
*/

#pragma once
#ifndef LINE_H
#define LINE_H
#include <stdint.h>
#ifdef __cplusplus

namespace daisysp
{
class Line
{
  public:
    Line() {}
    ~Line() {}
    void Init(float sample_rate);

    float Process(uint8_t *finished);

    void Start(float start, float end, float dur);

  private:
    float   start_, end_, dur_;
    float   inc_, val_, sample_rate_;
    uint8_t finished_;
};
} // namespace daisysp
#endif
#endif