Added gesture muting feature, like phoenix has.

This commit is contained in:
Lirusaito
2012-02-20 16:02:56 -05:00
parent e232abdab2
commit f253da09ec
4 changed files with 17 additions and 3 deletions

View File

@@ -8499,7 +8499,18 @@
<key>Value</key>
<integer>1</integer>
</map>
<key>NearMeRange</key>
<key>SinguMuteGestures</key>
<map>
<key>Comment</key>
<string>Mute gestures other than your own.</string>
<key>Persist</key>
<integer>1</integer>
<key>Type</key>
<string>Boolean</string>
<key>Value</key>
<integer>0</integer>
</map>
<key>NearMeRange</key>
<map>
<key>Comment</key>
<string>Search radius for nearby avatars</string>

View File

@@ -4521,6 +4521,8 @@ void process_sound_trigger(LLMessageSystem *msg, void **)
msg->getVector3Fast(_PREHASH_SoundData, _PREHASH_Position, pos_local);
msg->getF32Fast(_PREHASH_SoundData, _PREHASH_Gain, gain);
// Stop here if gesture muting, the user isn't playing this sound, and this is likely to be a gesture.
if(gSavedSettings.getBOOL("SinguMuteGestures") && owner_id != gAgent.getID() && object_id == owner_id) return;
// adjust sound location to true global coords
LLVector3d pos_global = from_region_handle(region_handle);
pos_global.mdV[VX] += pos_local.mV[VX];

View File

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<panel border="false" height="100" label="Audio &amp; Video" name="Media panel" width="250">
<slider control_name="AudioLevelMaster" follows="top" height="15" increment="0.005" initial_val="0.5" label="Master" label_width="55" left="10" max_val="1" min_val="0" name="System Volume" show_text="false" volume="true" width="181"/>
<slider bottom_delta="-15" control_name="AudioLevelMaster" follows="top" height="15" increment="0.005" initial_val="0.5" label="Master" label_width="55" left="10" max_val="1" min_val="0" name="System Volume" show_text="false" volume="true" width="181"/>
<button bottom_delta="0" control_name="MuteAudio" follows="top" height="16" image_selected="icn_speaker-muted_dark.tga" image_unselected="icn_speaker_dark.tga" label="" right="-28" name="mute_audio" toggle="true" width="25"/>
<slider bottom_delta="-30" control_name="AudioLevelMusic" follows="top" height="15" increment="0.005" initial_val="0.5" label="Music" label_width="55" left="10" max_val="1" min_val="0" name="Music Volume" show_text="false" volume="true" width="181"/>
<button bottom_delta="0" control_name="MuteMusic" follows="top" height="16" image_selected="icn_speaker-muted_dark.tga" image_unselected="icn_speaker_dark.tga" label="" right="-28" name="mute_music" toggle="true" width="25"/>
@@ -14,4 +14,5 @@
<button bottom_delta="0" control_name="MuteAmbient" follows="top" height="16" image_selected="icn_speaker-muted_dark.tga" image_unselected="icn_speaker_dark.tga" right="-28" label="" name="mute_wind" toggle="true" width="25"/>
<slider control_name="AudioLevelUI" follows="top" height="15" increment="0.005" initial_val="0.5" label="UI" label_width="55" left="10" max_val="1" min_val="0" name="UI Volume" show_text="false" volume="true" width="181"/>
<button bottom_delta="0" control_name="MuteUI" follows="top" height="16" image_selected="icn_speaker-muted_dark.tga" image_unselected="icn_speaker_dark.tga" right="-28" label="" name="mute_ui" toggle="true" width="25"/>
<button bottom_delta="-18" follows="top" control_name="SinguMuteGestures" font="SansSerifSmall" height="16" label_selected="Unmute Gestures" label_unselected="Mute Gestures" image_selected="icn_speaker-muted_dark.tga" image_unselected="icn_speaker_dark.tga" right="-10" left="10" name="Mute gestures" toggle="true" tool_tip="When active, gesture sounds other than your own will not be played for you."/>
</panel>

View File

@@ -3,7 +3,7 @@
<text bottom="-22" height="12" left="10" name="muting_text">Volume:</text>
<text bottom="-215" name="streaming_prefs_text">Streaming Preferences:</text>
<text bottom="-300" height="12" name="audio_prefs_text">Audio Preferences:</text>
<panel border="true" bottom="-175" filename="panel_audio.xml" height="140" label="Volume" left="142" name="Volume Panel" width="260"/>
<panel border="true" bottom="-200" filename="panel_audio.xml" height="165" label="Volume" left="142" name="Volume Panel" width="260"/>
<check_box bottom="-220" control_name="AudioStreamingMusic" height="16" initial_value="true" label="Play Streaming Music When Available (uses more bandwidth)" left="142" name="streaming_music"/>
<check_box bottom_delta="-20" control_name="AudioStreamingVideo" follows="top" height="16" initial_value="true" label="Play Streaming Media When Available (uses more bandwidth)" name="streaming_video"/>
<check_box bottom_delta="-20" control_name="ParcelMediaAutoPlayEnable" follows="top" height="16" initial_value="true" label="Automatically play media" left="162" name="auto_streaming_video"/>