classdef Echo< matlab.System
%Echo Add echo effect to audio signal.
%
%   ECHO = audioexample.Echo returns an echo System object, ECHO, that adds
%   echo effect to the audio signal.
%
%   ECHO = audioexample.Echo('Name', Value, ...) returns an echo System
%   object, ECHO, with each specified property name set to the specified
%   value. You can specify additional name-value pair arguments in any
%   order as (Name1,Value1,...,NameN, ValueN).
%
%   Step method syntax:
%      
%   Y = ECHO(X) adds echo effect for the audio input X based on the
%   properties specified in the object ECHO and returns it as audio
%   output Y. Each column of X is treated as individual channel of input.
%
%   System objects may be called directly like a function instead of using
%   the step method. For example, y = step(obj, x) and y = obj(x) are
%   equivalent.
%
%   Echo methods:
%
%   step     - See above for the description of the method
%   <a href="matlab:help matlab.System/reset   ">reset</a>    - Resets the internal state to initial conditions
%   clone    - Create Echo system object with similar property values
%   isLocked - Locked status (logical)
%   
%   Echo properties:
%   
%   Delay         - Base delay in seconds
%   Gain          - Amplitude gain 
%   FeedbackLevel - Feedback gain 
%   WetDryMix     - Wet to dry signal ratio
%   SampleRate    - Sample rate of the input audio signal
%
%   % Example: Add echo effect to an audio signal.
%
%   fileReader = dsp.AudioFileReader('SamplesPerFrame', 1024,...
%     'PlayCount', 3);
% 
%   player = audioDeviceWriter('SampleRate', fileReader.SampleRate);
% 
%   echoEffect = audioexample.Echo;
% 
%   while ~isDone(fileReader)
%       Input = fileReader();
%       Output = echoEffect(Input);
%       player(Output);
%   end
% 
%   release(fileReader)
%   release(player)

 
% Copyright 2015-2016 The MathWorks, Inc.

    methods
        function out=Echo
            % Set properties according to name-value pair
        end

        function out=IsOutputComplexImpl(~) %#ok<STOUT>
        end

        function out=getOutputDataTypeImpl(~) %#ok<STOUT>
        end

        function out=getOutputSizeImpl(~) %#ok<STOUT>
        end

        function out=isOutputFixedSizeImpl(~) %#ok<STOUT>
        end

        function out=loadObjectImpl(~) %#ok<STOUT>
        end

        function out=processTunedPropertiesImpl(~) %#ok<STOUT>
            % When Delay property changes, we have recalculate
            % pDelayInSamples property. Note that to maintain similar data
            % types throughout the process, cast function is used.
        end

        function out=releaseImpl(~) %#ok<STOUT>
        end

        function out=resetImpl(~) %#ok<STOUT>
        end

        function out=saveObjectImpl(~) %#ok<STOUT>
        end

        function out=setupImpl(~) %#ok<STOUT>
            % Cache the data type of input
        end

        function out=stepImpl(~) %#ok<STOUT>
            % Invoke the pDelay object for calculating delayed
            % signal.
        end

        function out=validateInputsImpl(~) %#ok<STOUT>
            % Validate inputs to the step method at initialization.
        end

    end
    properties
        %Delay Base delay (s)
        %   Specify the base delay for echo effect as positive scalar
        %   value in seconds. Base delay value must be in the range between
        %   0 and 1 seconds. The default value of this property is 0.5.
        Delay;

        %FeedbackLevel Feedback gain
        %   Specify the feedback gain value as a positive scalar. This
        %   value must range from 0 to 0.5. Setting FeedbackLevel to 0
        %   turns off the feedback feature. The default value of this
        %   property is 0.35.
        FeedbackLevel;

        %Gain Gain of delay branch
        %   Specify the gain value as a positive scalar. This value must be
        %   in the range between 0 and 1. The default value of this
        %   property is 0.5.
        Gain;

        %SampleRate Sampling rate of input audio signal
        %   Specify the sampling rate of the audio signal as a positive
        %   scalar value.  The default value of this property is 44100 Hz.
        SampleRate;

        %WetDryMix Wet/dry mix
        %   Specify the wet/dry mix ratio as a positive scalar. This value
        %   ranges from 0 to 1. For example, for a value of 0.6, the ratio
        %   will be 60% wet to 40% dry signal (Wet - Signal that has effect
        %   in it. Dry - Unaffected signal).  The default value of this
        %   property is 0.5.
        WetDryMix;

    end
end
