public static String getAout(SharedPreferences pref) { int aout = -1; try { aout = Integer.parseInt(pref.getString("aout", "-1")); } catch (NumberFormatException ignored) { } final HWDecoderUtil.AudioOutput hwaout = HWDecoderUtil.getAudioOutputFromDevice(); if (hwaout == HWDecoderUtil.AudioOutput.AUDIOTRACK || hwaout == HWDecoderUtil.AudioOutput.OPENSLES) aout = hwaout == HWDecoderUtil.AudioOutput.OPENSLES ? AOUT_OPENSLES : AOUT_AUDIOTRACK; return aout == AOUT_OPENSLES ? "opensles_android" : "android_audiotrack"; }
private static String getSystemPropertyCached(String key) { String prop = sSystemPropertyMap.get(key); if (prop == null) { prop = getSystemProperty(key, "none"); sSystemPropertyMap.put(key, prop); } return prop; }
/** * @return the audio output known to work for the running device * (By default, returns ALL, i.e AudioTrack + OpenSles) */ public static AudioOutput getAudioOutputFromDevice() { for (AudioOutputBySOC aoutBySOC : sAudioOutputBySOCList) { final String prop = getSystemPropertyCached(aoutBySOC.key); if (prop != null) { if (prop.contains(aoutBySOC.value)) return aoutBySOC.aout; } } return AudioOutput.ALL; }
HWDecoderUtil.getDecoderFromDevice() : HWDecoderUtil.Decoder.NONE;
HWDecoderUtil.getDecoderFromDevice() : HWDecoderUtil.Decoder.NONE;
/** * @return the audio output known to work for the running device * (By default, returns ALL, i.e AudioTrack + OpenSles) */ public static AudioOutput getAudioOutputFromDevice() { for (AudioOutputBySOC aoutBySOC : sAudioOutputBySOCList) { final String prop = getSystemPropertyCached(aoutBySOC.key); if (prop != null) { if (prop.contains(aoutBySOC.value)) return aoutBySOC.aout; } } return AudioOutput.ALL; }
options = new ArrayList<String>(); if (setAout) { final HWDecoderUtil.AudioOutput hwAout = HWDecoderUtil.getAudioOutputFromDevice(); if (hwAout == HWDecoderUtil.AudioOutput.OPENSLES) options.add("--aout=opensles");
private static String getSystemPropertyCached(String key) { String prop = sSystemPropertyMap.get(key); if (prop == null) { prop = getSystemProperty(key, "none"); sSystemPropertyMap.put(key, prop); } return prop; }
HWDecoderUtil.getDecoderFromDevice() : HWDecoderUtil.Decoder.NONE;
/** * @return the audio output known to work for the running device * (By default, returns ALL, i.e AudioTrack + OpenSles) */ public static AudioOutput getAudioOutputFromDevice() { for (AudioOutputBySOC aoutBySOC : sAudioOutputBySOCList) { final String prop = getSystemPropertyCached(aoutBySOC.key); if (prop != null) { if (prop.contains(aoutBySOC.value)) return aoutBySOC.aout; } } return AudioOutput.ALL; }
options = new ArrayList<String>(); if (setAout) { final HWDecoderUtil.AudioOutput hwAout = HWDecoderUtil.getAudioOutputFromDevice(); if (hwAout == HWDecoderUtil.AudioOutput.OPENSLES) options.add("--aout=opensles");
private static String getSystemPropertyCached(String key) { String prop = sSystemPropertyMap.get(key); if (prop == null) { prop = getSystemProperty(key, "none"); sSystemPropertyMap.put(key, prop); } return prop; }
HWDecoderUtil.getDecoderFromDevice() : HWDecoderUtil.Decoder.NONE;
/** * @return the audio output known to work for the running device * (By default, returns ALL, i.e AudioTrack + OpenSles) */ public static AudioOutput getAudioOutputFromDevice() { for (AudioOutputBySOC aoutBySOC : sAudioOutputBySOCList) { final String prop = getSystemPropertyCached(aoutBySOC.key); if (prop != null) { if (prop.contains(aoutBySOC.value)) return aoutBySOC.aout; } } return AudioOutput.ALL; }
final HWDecoderUtil.AudioOutput hwAout = HWDecoderUtil.getAudioOutputFromDevice(); if (hwAout == HWDecoderUtil.AudioOutput.OPENSLES) options.add("--aout=opensles");
private static String getSystemPropertyCached(String key) { String prop = sSystemPropertyMap.get(key); if (prop == null) { prop = getSystemProperty(key, "none"); sSystemPropertyMap.put(key, prop); } return prop; }
HWDecoderUtil.getDecoderFromDevice() : HWDecoderUtil.Decoder.NONE;
final String prop = getSystemPropertyCached(decBySOC.key); if (prop != null) { if (prop.contains(decBySOC.value)) else if (AndroidUtil.isHoneycombOrLater) { for (DecoderBySOC decBySOC : sDecoderBySOCList) { final String prop = getSystemPropertyCached(decBySOC.key); if (prop != null) { if (prop.contains(decBySOC.value))
final HWDecoderUtil.AudioOutput hwAout = HWDecoderUtil.getAudioOutputFromDevice(); if (hwAout == HWDecoderUtil.AudioOutput.OPENSLES) options.add("--aout=opensles");
private static String getSystemPropertyCached(String key) { String prop = sSystemPropertyMap.get(key); if (prop == null) { prop = getSystemProperty(key, "none"); sSystemPropertyMap.put(key, prop); } return prop; }