Eiffel Media API
Overview Cluster Class Classes Index      Previous Next      Top Features

em.audio

Class EM_EFFECT


Direct ancestors

MIX_EFFECT_DONE_T_CALLBACK, MIX_EFFECT_FUNC_T_CALLBACK

Known direct descendants

EM_LISTEN_EFFECT, EM_ECHO_EFFECT, EM_PHASING_EFFECT

Features

Invariants

indexing

description

Base class for effects.

Inherit from this class to be able to receive callbacks to
modify audio data.

Note: This effect may boost your CPU. Do not use effects when
having a lot of other things (like drawing).

Effects may also be used to get RAW sound data. Just grab
the data, but do not modify.

date

$Date: 2005/10/22 13:22:42 $

revision

$Revision: 1.11 $

deferred class

EM_EFFECT

inherit

MIX_EFFECT_DONE_T_CALLBACK
MIX_EFFECT_FUNC_T_CALLBACK

feature -- Access

effect_done: POINTER

-- Effect done function pointer

effect_function: POINTER

-- Effect function pointer

feature -- Internal Callback

on_effect_done_internal (a_channel: INTEGER; a_userdata: POINTER)

-- This feature is called when the effect was unregistered from a_channel.
--
-- Additional user data is given by a_userdata on creation of the effect.

-- (From MIX_EFFECT_DONE_T_CALLBACK)

on_effect_function_internal (a_channel: INTEGER; a_stream: POINTER; a_length: INTEGER; a_userdata: POINTER)

-- This feature is called whenever data is ready to apply the effect on.
--
-- Use a_stream to modify data of an maximum amount of a_length bytes.
-- Additional user data is given by a_userdata on creation of the effect.

-- (From MIX_EFFECT_FUNC_T_CALLBACK)

feature -- Callback

on_effect_done (a_channel: INTEGER; a_userdata: POINTER)

-- This feature is called when the effect was unregistered from a_channel.
--
-- Additional user data is given by a_userdata on creation of the effect.

on_effect_function (a_channel: INTEGER; a_stream: POINTER; a_length: INTEGER; a_userdata: POINTER)

-- This feature is called whenever data is ready to apply the effect on.
--
-- Use a_stream to modify data of an maximum amount of a_length bytes.
-- Additional user data is given by a_userdata on creation of the effect.

feature -- Setters

set_effect_done (a_function: like effect_done)

-- Sets the effect done function pointer.

ensure
done_function_set: effect_done = a_function
set_effect_function (a_function: like effect_function)

-- Sets the effect function pointer.

ensure
function_set: effect_function = a_function

invariant


-- From ANY
reflexive_equality: standard_is_equal (Current)
reflexive_conformance: conforms_to (Current)

end