UNPKG

el-vis-audio

Version:

audio/visual design system for [elementary.audio](https:/elementary.audio)

262 lines (205 loc) 7.01 kB
import React, { FC, ReactNode } from 'react'; import { NodeRepr_t } from '@elemaudio/core'; import * as styled_components from 'styled-components'; import WebRenderer from '@elemaudio/web-renderer'; interface AudioFileProps { playing: boolean; onSignal: (signal: NodeRepr_t) => void; } declare const AudioFile: FC<AudioFileProps>; interface AudioInProps { startingSignal?: "audioFile" | "oscillators" | "noise" | "liveInput"; playing: boolean; onSignal: (signal: NodeRepr_t) => void; } declare const AudioIn: FC<AudioInProps>; interface ButtonProps { backgroundColor?: string; hoverColor?: string; label?: string; onClick?: () => void; } declare const Button: FC<ButtonProps>; declare const Delay: FC; interface GesturesProps { } declare const Gestures: FC<GesturesProps>; declare const HilbertTransform: FC; declare const JuliaSynth: FC; interface KnobParamLabelProps { id?: string; key?: string; color?: string; backgroundColor?: string; hoverColor?: string; width?: number; height?: number; diameter?: number; labelWidth?: number; fontSize?: number; tooltip?: string; textHeight?: number; knobValue?: number; label?: string; log?: 0 | 1; min?: number; max?: number; step?: number; onKnobInput?: (value: number) => void; onChange?: (value: number) => void; onKnobEvent?: (event: any) => void; src?: string | null; } declare const KnobParamLabel: FC<KnobParamLabelProps>; interface LiveInputProps { playing: boolean; onSignal: (signal: NodeRepr_t) => void; } declare const LiveInput: FC<LiveInputProps>; interface ModalProps { active: boolean; title?: string; showX?: boolean; footer?: ReactNode; children?: ReactNode; hideModal: () => void; } declare const Modal: FC<ModalProps>; declare const ModalBlock: styled_components.StyledComponent<"div", any, {}, never>; declare const ModalOverlay: styled_components.StyledComponent<"a", any, {}, never>; declare const ModalClose: styled_components.StyledComponent<"a", any, {}, never>; declare const ModalContainer: styled_components.StyledComponent<"div", any, {}, never>; declare const ModalBody: styled_components.StyledComponent<"div", any, {}, never>; declare const ModalHeader: styled_components.StyledComponent<"div", any, {}, never>; declare const ModalTitle: styled_components.StyledComponent<"span", any, {}, never>; declare const ModalFooter: styled_components.StyledComponent<"div", any, {}, never>; interface NoiseProps { playing: boolean; onSignal: (signal: NodeRepr_t) => void; } declare const Noise: FC<NoiseProps>; interface OscillatorsProps { playing: boolean; onSignal: (signal: NodeRepr_t) => void; } declare const Oscillators: FC<OscillatorsProps>; interface OscilloscopeProps { audioVizData: Array<number>; color: string; height: number; width: number; } declare const Oscilloscope: FC<OscilloscopeProps>; interface OscilloscopeSpectrogramProps { audioVizData: Array<number>; fftVizData: Array<number>; width?: number; height?: number; backgroundColor?: string; oscilloscopeColor?: string; spectrogramColor?: string; } declare const OscilloscopeSpectrogram: FC<OscilloscopeSpectrogramProps>; interface PlayPauseAudioProps { backgroundColor?: string; hoverColor?: string; playing?: boolean; onPlay?: (playing: boolean) => void; } declare const PlayPauseAudio: FC<PlayPauseAudioProps>; interface PlayPauseCoreAudioProps { signalLeft: NodeRepr_t | null; signalRight: NodeRepr_t | null; backgroundColor?: string; hoverColor?: string; playing?: boolean; onPlay?: (playing: boolean) => void; } declare const PlayPauseCoreAudio: FC<PlayPauseCoreAudioProps>; interface PlayPauseButtonProps { backgroundColor?: string; hoverColor?: string; playing?: boolean; onClick?: () => void; } declare const PlayPauseButton: FC<PlayPauseButtonProps>; interface PlayMonoScopeAndGainProps { signal: NodeRepr_t | null; backgroundColor?: string; hoverColor?: string; width?: number; height?: number; playAudio?: boolean; oscilloscope?: boolean; spectrogram?: boolean; gain?: boolean; gainLabel?: boolean; isPlaying?: (playing: boolean) => void; } declare const PlayMonoGainScopeOverlay: FC<PlayMonoScopeAndGainProps>; declare const PlayMonoScopeAndGain: FC<PlayMonoScopeAndGainProps>; interface PresetsProps { currentSetting?: any; presetList: any; allowAdd?: boolean; allowEdit?: boolean; allowLocalStorage?: boolean; allowDownload?: boolean; allowUpload?: boolean; presetsName?: string; onUpdateCurrentPreset: (i: number) => void; onUpdatePresetList?: (presetList: any) => void; } declare const Presets: FC<PresetsProps>; declare const RecursivePM: FC; declare const RecursivePMWithDelay: FC; declare const RecursivePMWithDelay2: FC; declare const RecursivePMWithDelay3: FC; declare const ShepardRissetGlissando: FC; interface SliderProps { diameter?: string; fillColor?: string; trackHeight?: string; trackColor?: string; tickList?: string[]; tickColor?: string; tickPadding?: string; min?: number; step?: number; max?: number; value?: number; onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void; } declare const Slider: FC<SliderProps>; interface SpectrogramProps { fftVizData: Array<number>; color: string; height: number; width: number; } declare const Spectrogram: FC<SpectrogramProps>; interface SphereProps { diameter?: string; perspective?: string; backgroundColor?: string; fillColor?: string; } declare const Sphere: FC<SphereProps>; interface SwitchProps { backgroundColor?: string; } declare const Switch: FC<SwitchProps>; interface XYSpringProps { children: React.ReactNode; width: number; height: number; offset: number; } declare const XYSpringBox: FC<XYSpringProps>; declare const WeierstrassFunctionPM: FC; declare const audioContext: AudioContext; declare function cycleByPhasor(phasor: NodeRepr_t | number): number | NodeRepr_t; declare const exponentialScale: (value: number) => number; declare const toLog: (value: number, min: number, max: number) => number; declare const core: WebRenderer; export { AudioFile, AudioIn, Button, Delay, Gestures, HilbertTransform, JuliaSynth, KnobParamLabel, LiveInput, Modal, ModalBlock, ModalBody, ModalClose, ModalContainer, ModalFooter, ModalHeader, ModalOverlay, ModalTitle, Noise, Oscillators, Oscilloscope, OscilloscopeSpectrogram, PlayMonoGainScopeOverlay, PlayMonoScopeAndGain, PlayPauseAudio, PlayPauseButton, PlayPauseCoreAudio, Presets, RecursivePM, RecursivePMWithDelay, RecursivePMWithDelay2, RecursivePMWithDelay3, ShepardRissetGlissando, Slider, Spectrogram, Sphere, Switch, WeierstrassFunctionPM, XYSpringBox, audioContext, core, cycleByPhasor, exponentialScale, toLog };