Skip to content

Commit

Permalink
Update preferences.rst
Browse files Browse the repository at this point in the history
#fixes  #2651
You can set the preferred audio backend. However, it is not in prefs.general, but in prefs.hardware.
  • Loading branch information
maartenuni committed Oct 15, 2019
1 parent 8db8521 commit 331425a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/source/api/preferences.rst
Expand Up @@ -6,7 +6,7 @@
You can set preferences on a per-experiment basis. For example, if you would like to use a specific :doc:`audio library</api/sound>`, but don't want to touch your user settings in general, you can import preferences and set the option :ref:`audioLib<generalSettings>` accordingly::

from psychopy import prefs
prefs.general['audioLib'] = ['pyo']
prefs.hardware['audioLib'] = ['pyo']
from psychopy import sound

**!!IMPORTANT!!** You must import the sound module **AFTER** setting the preferences. To check that you are getting what you want (don't do this in your actual experiment)::
Expand Down

0 comments on commit 331425a

Please sign in to comment.