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
d86ee938
Commit
d86ee938
authored
Aug 07, 2013
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
filter/Route: don't access PcmBuffer attributes directly
Return the pointer given by PcmBuffer::Get() instead of reaching into the PcmBuffer object.
parent
87b73284
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
RouteFilterPlugin.cxx
src/filter/RouteFilterPlugin.cxx
+5
-5
No files found.
src/filter/RouteFilterPlugin.cxx
View file @
d86ee938
...
...
@@ -275,12 +275,12 @@ RouteFilter::FilterPCM(const void *src, size_t src_size,
// A moving pointer that always refers to channel 0 in the input, at the currently handled frame
const
uint8_t
*
base_source
=
(
const
uint8_t
*
)
src
;
// A moving pointer that always refers to the currently filled channel of the currently handled frame, in the output
uint8_t
*
chan_destination
;
// Grow our reusable buffer, if needed, and set the moving pointer
*
dest_size_r
=
number_of_frames
*
output_frame_size
;
chan_destination
=
(
uint8_t
*
)
output_buffer
.
Get
(
*
dest_size_r
);
void
*
const
result
=
output_buffer
.
Get
(
*
dest_size_r
);
// A moving pointer that always refers to the currently filled channel of the currently handled frame, in the output
uint8_t
*
chan_destination
=
(
uint8_t
*
)
result
;
// Perform our copy operations, with N input channels and M output channels
for
(
unsigned
int
s
=
0
;
s
<
number_of_frames
;
++
s
)
{
...
...
@@ -313,7 +313,7 @@ RouteFilter::FilterPCM(const void *src, size_t src_size,
}
// Here it is, ladies and gentlemen! Rerouted data!
return
(
void
*
)
output_buffer
.
buffer
;
return
result
;
}
const
struct
filter_plugin
route_filter_plugin
=
{
...
...
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