Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
cae7c160
Commit
cae7c160
authored
Feb 20, 2009
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
crossfade: added API documentation
parent
91ebf468
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
0 deletions
+21
-0
crossfade.h
src/crossfade.h
+21
-0
No files found.
src/crossfade.h
View file @
cae7c160
...
...
@@ -23,11 +23,32 @@
struct
audio_format
;
struct
music_chunk
;
/**
* Calculate how many music pipe chunks should be used for crossfading.
*
* @param duration the requested crossfade duration
* @param total_time total_time the duration of the new song
* @param af the audio format of the new song
* @param old_format the audio format of the current song
* @param max_chunks the maximum number of chunks
* @return the number of chunks for crossfading, or 0 if cross fading
* should be disabled for this song change
*/
unsigned
cross_fade_calc
(
float
duration
,
float
total_time
,
const
struct
audio_format
*
af
,
const
struct
audio_format
*
old_format
,
unsigned
max_chunks
);
/*
* Applies cross fading to two chunks, i.e. mixes these chunks.
* Internally, this calls pcm_mix().
*
* @param a the chunk in the current song (and the destination chunk)
* @param b the according chunk in the new song
* @param format the audio format of both chunks (must be the same)
* @param current_chunk the relative index of the current chunk
* @param num_chunks the number of chunks used for cross fading
*/
void
cross_fade_apply
(
struct
music_chunk
*
a
,
const
struct
music_chunk
*
b
,
const
struct
audio_format
*
format
,
unsigned
int
current_chunk
,
unsigned
int
num_chunks
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment