Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-gpu
Commits
99ccd646
Commit
99ccd646
authored
Aug 17, 2011
by
Jean-Baptiste Kempf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Auhal: simplifications
parent
cd34d65e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
8 deletions
+4
-8
modules/audio_output/auhal.c
modules/audio_output/auhal.c
+4
-8
No files found.
modules/audio_output/auhal.c
View file @
99ccd646
...
@@ -82,7 +82,6 @@ struct aout_sys_t
...
@@ -82,7 +82,6 @@ struct aout_sys_t
AudioDeviceID
i_selected_dev
;
/* DeviceID of the selected device */
AudioDeviceID
i_selected_dev
;
/* DeviceID of the selected device */
AudioDeviceIOProcID
i_procID
;
/* DeviceID of current device */
AudioDeviceIOProcID
i_procID
;
/* DeviceID of current device */
UInt32
i_devices
;
/* Number of CoreAudio Devices */
UInt32
i_devices
;
/* Number of CoreAudio Devices */
bool
b_supports_digital
;
/* Does the currently selected device support digital mode? */
bool
b_digital
;
/* Are we running in digital mode? */
bool
b_digital
;
/* Are we running in digital mode? */
mtime_t
clock_diff
;
/* Difference between VLC clock and Device clock */
mtime_t
clock_diff
;
/* Difference between VLC clock and Device clock */
...
@@ -170,7 +169,6 @@ static int Open( vlc_object_t * p_this )
...
@@ -170,7 +169,6 @@ static int Open( vlc_object_t * p_this )
p_sys
->
i_default_dev
=
0
;
p_sys
->
i_default_dev
=
0
;
p_sys
->
i_selected_dev
=
0
;
p_sys
->
i_selected_dev
=
0
;
p_sys
->
i_devices
=
0
;
p_sys
->
i_devices
=
0
;
p_sys
->
b_supports_digital
=
false
;
p_sys
->
b_digital
=
false
;
p_sys
->
b_digital
=
false
;
p_sys
->
au_component
=
NULL
;
p_sys
->
au_component
=
NULL
;
p_sys
->
au_unit
=
NULL
;
p_sys
->
au_unit
=
NULL
;
...
@@ -210,11 +208,9 @@ static int Open( vlc_object_t * p_this )
...
@@ -210,11 +208,9 @@ static int Open( vlc_object_t * p_this )
}
}
p_sys
->
i_selected_dev
=
val
.
i_int
&
~
AOUT_VAR_SPDIF_FLAG
;
/* remove SPDIF flag to get the true DeviceID */
p_sys
->
i_selected_dev
=
val
.
i_int
&
~
AOUT_VAR_SPDIF_FLAG
;
/* remove SPDIF flag to get the true DeviceID */
p_sys
->
b_supports_digital
=
(
val
.
i_int
&
AOUT_VAR_SPDIF_FLAG
)
?
true
:
false
;
bool
b_supports_digital
=
(
val
.
i_int
&
AOUT_VAR_SPDIF_FLAG
)
;
if
(
p_sys
->
b_supports_digital
)
if
(
b_supports_digital
)
msg_Dbg
(
p_aout
,
"audio device supports digital output"
);
msg_Dbg
(
p_aout
,
"audio device supports digital output"
);
else
msg_Dbg
(
p_aout
,
"audio device does not support digital output"
);
/* Check if the desired device is alive and usable */
/* Check if the desired device is alive and usable */
/* TODO: add a callback to the device to alert us if the device dies */
/* TODO: add a callback to the device to alert us if the device dies */
...
@@ -261,7 +257,7 @@ static int Open( vlc_object_t * p_this )
...
@@ -261,7 +257,7 @@ static int Open( vlc_object_t * p_this )
}
}
/* Check for Digital mode or Analog output mode */
/* Check for Digital mode or Analog output mode */
if
(
AOUT_FMT_SPDIF
(
&
p_aout
->
format
)
&&
p_sys
->
b_supports_digital
)
if
(
AOUT_FMT_SPDIF
(
&
p_aout
->
format
)
&&
b_supports_digital
)
{
{
if
(
OpenSPDIF
(
p_aout
)
)
if
(
OpenSPDIF
(
p_aout
)
)
{
{
...
@@ -1417,7 +1413,7 @@ static OSStatus StreamListener( AudioObjectID inObjectID, UInt32 inNumberAddres
...
@@ -1417,7 +1413,7 @@ static OSStatus StreamListener( AudioObjectID inObjectID, UInt32 inNumberAddres
VLC_UNUSED
(
inObjectID
);
VLC_UNUSED
(
inObjectID
);
for
(
unsigned
int
i
=
0
;
i
<
inNumberAddresses
;
i
++
)
for
(
unsigned
int
i
=
0
;
i
<
inNumberAddresses
;
i
++
)
{
{
if
(
inAddresses
[
i
].
mSelector
==
kAudioStreamPropertyPhysicalFormat
)
if
(
inAddresses
[
i
].
mSelector
==
kAudioStreamPropertyPhysicalFormat
)
{
{
...
...
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