# Conflicts:
#	indra/newview/llpanelsnapshot.cpp
#	indra/newview/llsnapshotlivepreview.cpp
#	indra/newview/llspeakers.cpp
#	indra/newview/llvoicechannel.cpp
#	indra/newview/rlvinventory.cpp
master
Ansariel 2024-07-18 21:53:13 +02:00
commit cf5bc75d44
54 changed files with 547 additions and 238 deletions

4
.github/pull_request_template.md vendored Normal file
View File

@ -0,0 +1,4 @@
## Firestorm Pull Request Checklist
Thank you for contributing to the Phoenix Firestorm Project.
We will endeavour to review you changes and accept/reject/request changes as soon as possible.
Please read and follow the [Firestorm Pull Request Guidelines](https://github.com/firestormviewer/phoenix-firestorm/blob/master/FS_PR_GUIDELINES.md) to reduce the likelihood that we need to ask for "Bureaucratic" changes to make the code comply with our workflows.

63
FS_PR_GUIDELINES.md Normal file
View File

@ -0,0 +1,63 @@
# Firestorm Pull Request Guidelines
Thank you for submitting code to Firestorm; we will review it and merge or provide feedback in due course.
We have written this guide to help you contribute code that meets our needs. It will hopefully reduce the number of iterations required before we can merge the code.
1. **Descriptive Title**:
   - Use a clear and descriptive title for the PR.
1. **Related Issues**:
   - Reference any related issues or pull requests by including the JIRA number and description in the commit message header (e.g., `[FIRE-12345] When I click, my head falls off` or `[FIRE-12345] prevent click detaching head`).
1. **Description**:
   - Provide a detailed description of the changes. Explain why the changes are necessary and what problem they solve. If a JIRA is associated with the change, there is no need to duplicate that, but we would appreciate a summary and explanation of the fix.
1. **Comment tags (important)**:
   - We use comments to preserve the original upstream (LL) code when making modifications; this allows the person merging future code updates to see both the original code from LL and any new updates and then use those to determine whether the FS-specific changes need to be updated and reviewed.
If you are modifying LL code, we need the LL code preserved in a comment.
For example:
```c++
    int buggy_code = TRUE;
    LL_WARN() << "This code is buggy" << LL_ENDL;
```
Would become:
```c++
    // <FS> [FIRE-999] Fix the buggy code
    // int buggy_code = TRUE;
    // LL_WARN() << "This code is buggy" << LL_ENDL;
    bool fixed_code = true;
    LL_DEBUG() << "I fixed this" << LL_ENDL;
    // </FS>
```
Note: You can tag them with your initials, e.g. `<FS:YI>` or a short unique tag (shorter is better)
If you add new code, the same rules apply, but there is nothing to comment out.
This is done so that when LL updates the original code, we can see what the original code was doing, what their changes do, and how that relates to the changes that we applied on top.
A single line change can use the shorthand `<FS:YI/>`:
```c++
    bool break_stuff=true;
```
Could be fixed as follows:
```c++
    bool break_stuff=false; // <FS:Beq/> [FIRE-23456] don't break stuff.
```
The Comment tags are only required when changing code maintained upstream. If the code you are changing is in an FS-created file, RLV code, OpenSim-only code, etc., then we do not need the comments.
If the code you are changing is already inside an `//<FS>` comment block, then there is no need to add a new block, but do try to make sure that any comments align with the updates you make.
5. **Testing**:
   - Include details on how the changes should be tested. Describe the testing environment and any steps needed to verify the changes.
1. **Documentation**:
   - If the change includes a new feature, it would be beneficial to suggest how we should update the FS Wiki pages to help users understand the feature
Thank you for your contribution!

View File

@ -23,4 +23,4 @@ Build instructions for each operating system can be found using the links below
## Contribute
Help make Firestorm better! You can get involved with improvements by filing bugs and suggesting enhancements via [JIRA](https://jira.firestormviewer.org) or creating pull requests.
Help make Firestorm better! You can get involved with improvements by filing bugs and suggesting enhancements via [JIRA](https://jira.firestormviewer.org) or [creating pull requests](FS_PR_GUIDELINES.md).

View File

@ -880,12 +880,6 @@
<string>https://github.com/secondlife/3p-emoji-shortcodes</string>
<key>description</key>
<string>Emoji shortcodes</string>
<key>name</key>
<string>emoji_shortcodes</string>
<key>canonical_repo</key>
<string>https://github.com/secondlife/3p-emoji-shortcodes</string>
<key>description</key>
<string>Emoji shortcodes</string>
</map>
<key>expat</key>
<map>
@ -1982,6 +1976,18 @@
</map>
<key>mikktspace</key>
<map>
<key>canonical_repo</key>
<string>https://bitbucket.org/lindenlab/3p-mikktspace</string>
<key>copyright</key>
<string>Copyright (C) 2011 by Morten S. Mikkelsen, Copyright (C) 2022 Blender Authors</string>
<key>description</key>
<string>Mikktspace Tangent Generator</string>
<key>license</key>
<string>Apache 2.0</string>
<key>license_file</key>
<string>mikktspace.txt</string>
<key>name</key>
<string>mikktspace</string>
<key>platforms</key>
<map>
<key>darwin64</key>
@ -2027,20 +2033,8 @@
<string>windows64</string>
</map>
</map>
<key>license</key>
<string>Apache 2.0</string>
<key>license_file</key>
<string>mikktspace.txt</string>
<key>copyright</key>
<string>Copyright (C) 2011 by Morten S. Mikkelsen, Copyright (C) 2022 Blender Authors</string>
<key>version</key>
<string>1</string>
<key>name</key>
<string>mikktspace</string>
<key>canonical_repo</key>
<string>https://bitbucket.org/lindenlab/3p-mikktspace</string>
<key>description</key>
<string>Mikktspace Tangent Generator</string>
</map>
<key>minizip-ng</key>
<map>
@ -2768,7 +2762,7 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
<key>hash</key>
<string>9ab29796dc144431a9db46fddfbd88b0</string>
<key>hash_algorithm</key>
<string>md5</string>
<string>sha1</string>
<key>url</key>
<string>https://3p.firestormviewer.org/tracy-v0.10.241831929-linux-241831929.tar.bz2</string>
</map>
@ -3008,8 +3002,6 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
<string>LICENSE</string>
<key>copyright</key>
<string>Copyright (c) 2000-2012, Linden Research, Inc.</string>
<key>version</key>
<string>3.0-f14b5ec</string>
<key>name</key>
<string>viewer-manager</string>
<key>description</key>
@ -3018,6 +3010,8 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
<string>https://bitbucket.org/lindenlab/vmp-standalone</string>
<key>source_type</key>
<string>hg</string>
<key>version</key>
<string>3.0-f14b5ec</string>
</map>
<key>vlc-bin</key>
<map>
@ -3168,7 +3162,7 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
<key>hash</key>
<string>0a0a972036f2b2c9c97dead40c91f7443b8ab339</string>
<key>hash_algorithm</key>
<string>md5</string>
<string>sha1</string>
<key>url</key>
<string>https://github.com/secondlife/3p-webrtc-build/releases/download/m114.5735.08.61-debug/webrtc-m114.5735.08.61-debug.9571929057-darwin64-9571929057.tar.zst</string>
</map>

View File

@ -124,7 +124,7 @@ void LLMemory::updateMemoryInfo()
{
// Our Windows definition of PagefileUsage is documented by Microsoft as "the total amount of
// memory that the memory manager has committed for a running process", which is rss.
sAllocatedPageSizeInKB = U32Bytes(info.resident_size);
sAllocatedPageSizeInKB = U64Bytes(info.resident_size);
// Activity Monitor => Inspect Process => Real Memory Size appears to report resident_size
// Activity monitor => main window memory column appears to report phys_footprint, which spot checks as at least 30% less.
@ -134,7 +134,7 @@ void LLMemory::updateMemoryInfo()
// reported for the app by the Memory Monitor in Instruments.' It is still about 8% bigger than phys_footprint.
//
// (On Windows, we use WorkingSetSize.)
sAllocatedMemInKB = U32Bytes(info.resident_size - info.reusable);
sAllocatedMemInKB = U64Bytes(info.resident_size - info.reusable);
}
else
{
@ -154,7 +154,7 @@ void LLMemory::updateMemoryInfo()
// <FS:Beq> align MemInfo across platforms
// sAvailPhysicalMemInKB = U32Bytes(vmstat.free_count * page_size);
// sMaxPhysicalMemInKB = LLMemoryInfo::getHardwareMemSize();
avail_phys = U32Bytes( (vmstat.free_count + vmstat.inactive_count) * page_size);
avail_phys = U64Bytes( (vmstat.free_count + vmstat.inactive_count) * page_size);
sMaxHeapSizeInKB = LLMemoryInfo::getHardwareMemSize();
// </FS:Beq>
}

View File

@ -35,6 +35,7 @@
#include "api/media_stream_interface.h"
#include "api/media_stream_track.h"
#include "modules/audio_processing/audio_buffer.h"
#include "modules/audio_mixer/audio_mixer_impl.h"
namespace llwebrtc
{
@ -88,7 +89,7 @@ void LLAudioDeviceObserver::OnRenderData(const void *audio_samples,
{
}
LLCustomProcessor::LLCustomProcessor() : mSampleRateHz(0), mNumChannels(0), mMicrophoneEnergy(0.0)
LLCustomProcessor::LLCustomProcessor() : mSampleRateHz(0), mNumChannels(0), mMicrophoneEnergy(0.0), mGain(1.0)
{
memset(mSumVector, 0, sizeof(mSumVector));
}
@ -128,9 +129,13 @@ void LLCustomProcessor::Process(webrtc::AudioBuffer *audio_in)
for (size_t index = 0; index < stream_config.num_samples(); index++)
{
float sample = frame_samples[index];
sample = sample * mGain; // apply gain
frame_samples[index] = sample; // write processed sample back to buffer.
energy += sample * sample;
}
audio_in->CopyFrom(&frame[0], stream_config);
// smooth it.
size_t buffer_size = sizeof(mSumVector) / sizeof(mSumVector[0]);
float totalSum = 0;
@ -236,9 +241,9 @@ void LLWebRTCImpl::init()
webrtc::AudioProcessing::Config apm_config;
apm_config.echo_canceller.enabled = false;
apm_config.echo_canceller.mobile_mode = false;
apm_config.gain_controller1.enabled = true;
apm_config.gain_controller1.enabled = false;
apm_config.gain_controller1.mode = webrtc::AudioProcessing::Config::GainController1::kAdaptiveAnalog;
apm_config.gain_controller2.enabled = true;
apm_config.gain_controller2.enabled = false;
apm_config.high_pass_filter.enabled = true;
apm_config.noise_suppression.enabled = true;
apm_config.noise_suppression.level = webrtc::AudioProcessing::Config::NoiseSuppression::kVeryHigh;
@ -260,6 +265,7 @@ void LLWebRTCImpl::init()
mAudioProcessingModule->ApplyConfig(apm_config);
mAudioProcessingModule->Initialize(processing_config);
mPeerConnectionFactory = webrtc::CreatePeerConnectionFactory(mNetworkThread.get(),
mWorkerThread.get(),
mSignalingThread.get(),
@ -336,9 +342,9 @@ void LLWebRTCImpl::setAudioConfig(LLWebRTCDeviceInterface::AudioConfig config)
webrtc::AudioProcessing::Config apm_config;
apm_config.echo_canceller.enabled = config.mEchoCancellation;
apm_config.echo_canceller.mobile_mode = false;
apm_config.gain_controller1.enabled = true;
apm_config.gain_controller1.enabled = config.mAGC;
apm_config.gain_controller1.mode = webrtc::AudioProcessing::Config::GainController1::kAdaptiveAnalog;
apm_config.gain_controller2.enabled = true;
apm_config.gain_controller2.enabled = false;
apm_config.high_pass_filter.enabled = true;
apm_config.transient_suppression.enabled = true;
apm_config.pipeline.multi_channel_render = true;
@ -612,6 +618,8 @@ float LLWebRTCImpl::getTuningAudioLevel() { return -20 * log10f(mTuningAudioDevi
float LLWebRTCImpl::getPeerConnectionAudioLevel() { return -20 * log10f(mPeerCustomProcessor->getMicrophoneEnergy()); }
void LLWebRTCImpl::setPeerConnectionGain(float gain) { mPeerCustomProcessor->setGain(gain); }
//
// Peer Connection Helpers
@ -937,7 +945,7 @@ void LLWebRTCPeerConnectionImpl::setSendVolume(float volume)
{
for (auto &track : mLocalStream->GetAudioTracks())
{
track->GetSource()->SetVolume(volume);
track->GetSource()->SetVolume(volume*5.0);
}
}
});

View File

@ -145,6 +145,7 @@ class LLWebRTCDeviceInterface
virtual void setTuningMode(bool enable) = 0;
virtual float getTuningAudioLevel() = 0; // for use during tuning
virtual float getPeerConnectionAudioLevel() = 0; // for use when not tuning
virtual void setPeerConnectionGain(float gain) = 0;
};
// LLWebRTCAudioInterface provides the viewer with a way

View File

@ -121,6 +121,8 @@ class LLCustomProcessor : public webrtc::CustomProcessing
float getMicrophoneEnergy() { return mMicrophoneEnergy; }
void setGain(float gain) { mGain = gain; }
protected:
static const int NUM_PACKETS_TO_FILTER = 30; // 300 ms of smoothing
int mSampleRateHz;
@ -128,6 +130,7 @@ class LLCustomProcessor : public webrtc::CustomProcessing
float mSumVector[NUM_PACKETS_TO_FILTER];
float mMicrophoneEnergy;
float mGain;
};
@ -160,6 +163,8 @@ class LLWebRTCImpl : public LLWebRTCDeviceInterface, public webrtc::AudioDeviceS
float getTuningAudioLevel() override;
float getPeerConnectionAudioLevel() override;
void setPeerConnectionGain(float gain) override;
//
// AudioDeviceSink
//

View File

@ -1072,6 +1072,19 @@
<real>0.0</real>
</array>
</map>
<!-- <FS:Chanayane> Camera roll (from Alchemy) -->
<key>ALStoredCameraRoll</key>
<map>
<key>Comment</key>
<string>Stored camera roll in camera tools</string>
<key>Persist</key>
<integer>1</integer>
<key>Type</key>
<string>F32</string>
<key>Value</key>
<real>0.0</real>
</map>
<!-- </FS:Chanayane> -->
<key>FSStoredCameraFocusObjectId</key>
<map>
<key>Comment</key>

View File

@ -267,6 +267,25 @@ S32 LLAgentBenefits::getTextureUploadCost(const LLImageBase* tex) const
return getTextureUploadCost();
}
// <FS:Chanayane> 2048x2048 snapshots upload to inventory
S32 LLAgentBenefits::getTextureUploadCost(S32 w, S32 h) const
{
if (w > 0 && h > 0)
{
S32 area = w * h;
if (area >= MIN_2K_TEXTURE_AREA)
{
return get2KTextureUploadCost(area);
}
else
{
return getTextureUploadCost();
}
}
return getTextureUploadCost();
}
// </FS:Chanayane>
S32 LLAgentBenefits::get2KTextureUploadCost(S32 area) const
{
if (m_2k_texture_upload_cost.empty())

View File

@ -54,6 +54,9 @@ public:
S32 getTextureUploadCost() const;
S32 getTextureUploadCost(const LLViewerTexture* tex) const;
S32 getTextureUploadCost(const LLImageBase* tex) const;
// <FS:Chanayane> 2048x2048 snapshots upload to inventory
S32 getTextureUploadCost(S32 w, S32 h) const;
// </FS:Chanayane>
S32 get2KTextureUploadCost(S32 area) const;
bool findUploadCost(LLAssetType::EType& asset_type, S32& cost) const;

View File

@ -189,7 +189,10 @@ LLAgentCamera::LLAgentCamera() :
mPanRightKey(0.f),
mPanInKey(0.f),
mPanOutKey(0.f),
// <FS:Chanayane> Camera roll (from Alchemy)
mRollLeftKey(0.f),
mRollRightKey(0.f),
// </FS:Chanayane>
mPointAtObject(NULL)
{
mFollowCam.setMaxCameraDistantFromSubject( MAX_CAMERA_DISTANCE_FROM_AGENT );
@ -200,6 +203,9 @@ LLAgentCamera::LLAgentCamera() :
resetPanDiff();
resetOrbitDiff();
// <FS:Chanayane> Camera roll (from Alchemy)
resetCameraRoll();
// </FS:Chanayane>
}
// Requires gSavedSettings to be initialized.
@ -381,6 +387,9 @@ void LLAgentCamera::resetView(bool reset_camera, bool change_camera, bool moveme
setFocusOnAvatar(true, ANIMATE);
mCameraFOVZoomFactor = 0.f;
// <FS:Chanayane> Camera roll (from Alchemy)
resetCameraRoll();
// </FS:Chanayane>
}
resetPanDiff();
resetOrbitDiff();
@ -937,6 +946,20 @@ void LLAgentCamera::cameraOrbitOver(const F32 angle)
}
}
// <FS:Chanayane> Camera roll (from Alchemy)
//-----------------------------------------------------------------------------
// cameraRollOver()
//-----------------------------------------------------------------------------
void LLAgentCamera::cameraRollOver(const F32 angle)
{
mRollAngle += fmodf(angle, F_TWO_PI);
}
void LLAgentCamera::resetCameraRoll()
{
mRollAngle = 0.f;
}
// </FS:Chanayane>
void LLAgentCamera::resetCameraOrbit()
{
LLVector3 camera_offset_unit(mCameraFocusOffsetTarget);
@ -950,6 +973,9 @@ void LLAgentCamera::resetCameraOrbit()
cameraZoomIn(1.f);
resetOrbitDiff();
// <FS:Chanayane> Camera roll (from Alchemy)
resetCameraRoll();
// </FS:Chanayane>
}
void LLAgentCamera::resetOrbitDiff()
@ -1356,6 +1382,9 @@ void LLAgentCamera::updateCamera()
const F32 ORBIT_OVER_RATE = 90.f * DEG_TO_RAD; // radians per second
const F32 ORBIT_AROUND_RATE = 90.f * DEG_TO_RAD; // radians per second
const F32 PAN_RATE = 5.f; // meters per second
// <FS:Chanayane> Camera roll (from Alchemy)
const F32 ROLL_RATE = 45.f * DEG_TO_RAD; // radians per second
// </FS:Chanayane>
if (gAgentCamera.getOrbitUpKey() || gAgentCamera.getOrbitDownKey())
{
@ -1397,6 +1426,14 @@ void LLAgentCamera::updateCamera()
cameraPanUp(input_rate * PAN_RATE / gFPSClamped );
}
// <FS:Chanayane> Camera roll (from Alchemy)
if (getRollLeftKey() || getRollRightKey())
{
F32 input_rate = getRollRightKey() - getRollLeftKey();
cameraRollOver(input_rate * ROLL_RATE / gFPSClamped);
}
// </FS:Chanayane>
// Clear camera keyboard keys.
gAgentCamera.clearOrbitKeys();
gAgentCamera.clearPanKeys();
@ -1641,7 +1678,20 @@ void LLAgentCamera::updateCamera()
torso_joint->setScale(torso_scale);
chest_joint->setScale(chest_scale);
}
// <FS:Chanayane> Camera roll (from Alchemy)
// We have do this at the very end to make sure it takes all previous calculations into
// account and then applies our roll on top of it, besides it wouldn't even work otherwise.
LLQuaternion rot_quat = LLViewerCamera::getInstance()->getQuaternion();
LLMatrix3 rot_mat(mRollAngle, 0.f, 0.f);
rot_quat = LLQuaternion(rot_mat)*rot_quat;
LLMatrix3 mat(rot_quat);
LLViewerCamera::getInstance()->mXAxis = LLVector3(mat.mMatrix[0]);
LLViewerCamera::getInstance()->mYAxis = LLVector3(mat.mMatrix[1]);
LLViewerCamera::getInstance()->mZAxis = LLVector3(mat.mMatrix[2]);
}
// </FS:Chanayane>
void LLAgentCamera::updateLastCamera()
{
@ -2756,6 +2806,9 @@ void LLAgentCamera::switchCameraPreset(ECameraPreset preset)
resetPanDiff();
resetOrbitDiff();
// <FS:Chanayane> Camera roll (from Alchemy)
resetCameraRoll();
// </FS:Chanayane>
gSavedSettings.setU32("CameraPresetType", mCameraPreset);
}
@ -3260,6 +3313,10 @@ void LLAgentCamera::clearOrbitKeys()
mOrbitDownKey = 0.f;
mOrbitInKey = 0.f;
mOrbitOutKey = 0.f;
// <FS:Chanayane> Camera roll (from Alchemy)
mRollLeftKey = 0.f;
mRollRightKey = 0.f;
// </FS:Chanayane>
}
void LLAgentCamera::clearPanKeys()
@ -3290,6 +3347,9 @@ void LLAgentCamera::storeCameraPosition()
// flycam mode and not repositioned after
LLVector3d forward = LLVector3d(1.0, 0.0, 0.0) * LLViewerCamera::getInstance()->getQuaternion() + getCameraPositionGlobal();
gSavedPerAccountSettings.setVector3d("FSStoredCameraFocus", forward);
// <FS:Chanayane> Camera roll (from Alchemy)
gSavedPerAccountSettings.setF32("ALStoredCameraRoll", mRollAngle);
// </FS:Chanayane>
LLUUID stored_camera_focus_object_id = LLUUID::null;
if (mFocusObject)
@ -3303,6 +3363,9 @@ void LLAgentCamera::loadCameraPosition()
{
LLVector3d stored_camera_pos = gSavedPerAccountSettings.getVector3d("FSStoredCameraPos");
LLVector3d stored_camera_focus = gSavedPerAccountSettings.getVector3d("FSStoredCameraFocus");
// <FS:Chanayane> Camera roll (from Alchemy)
F32 stored_camera_roll = gSavedPerAccountSettings.getF32("ALStoredCameraRoll");
// </FS:Chanayane>
LLUUID stored_camera_focus_object_id = LLUUID(gSavedPerAccountSettings.getString("FSStoredCameraFocusObjectId"));
F32 renderFarClip = gSavedSettings.getF32("RenderFarClip");
@ -3331,6 +3394,9 @@ void LLAgentCamera::loadCameraPosition()
unlockView();
setCameraPosAndFocusGlobal(stored_camera_pos, stored_camera_focus, stored_camera_focus_object_id);
// <FS:Chanayane> Camera roll (from Alchemy)
mRollAngle = stored_camera_roll;
// </FS:Chanayane>
}
// </FS:Ansariel> FIRE-7758: Save/load camera position feature

View File

@ -300,8 +300,14 @@ public:
void cameraOrbitAround(const F32 radians); // Rotate camera CCW radians about build focus point
void cameraOrbitOver(const F32 radians); // Rotate camera forward radians over build focus point
void cameraOrbitIn(const F32 meters); // Move camera in toward build focus point
// <FS:Chanayane> Camera roll (from Alchemy)
void cameraRollOver(const F32 radians); // Roll the camera
// </FS:Chanayane>
void resetCameraOrbit();
void resetOrbitDiff();
// <FS:Chanayane> Camera roll (from Alchemy)
void resetCameraRoll();
// </FS:Chanayane>
//--------------------------------------------------------------------
// Zoom
//--------------------------------------------------------------------
@ -409,6 +415,10 @@ public:
F32 getOrbitDownKey() const { return mOrbitDownKey; }
F32 getOrbitInKey() const { return mOrbitInKey; }
F32 getOrbitOutKey() const { return mOrbitOutKey; }
// <FS:Chanayane> Camera roll (from Alchemy)
F32 getRollLeftKey() const { return mRollLeftKey; }
F32 getRollRightKey() const { return mRollRightKey; }
// </FS:Chanayane>
void setOrbitLeftKey(F32 mag) { mOrbitLeftKey = mag; }
void setOrbitRightKey(F32 mag) { mOrbitRightKey = mag; }
@ -416,6 +426,10 @@ public:
void setOrbitDownKey(F32 mag) { mOrbitDownKey = mag; }
void setOrbitInKey(F32 mag) { mOrbitInKey = mag; }
void setOrbitOutKey(F32 mag) { mOrbitOutKey = mag; }
// <FS:Chanayane> Camera roll (from Alchemy)
void setRollLeftKey(F32 mag) { mRollLeftKey = mag; }
void setRollRightKey(F32 mag) { mRollRightKey = mag; }
// </FS:Chanayane>
void clearOrbitKeys();
private:
@ -429,6 +443,12 @@ private:
F32 mOrbitAroundRadians;
F32 mOrbitOverAngle;
// <FS:Chanayane> Camera roll (from Alchemy)
F32 mRollLeftKey;
F32 mRollRightKey;
F32 mRollAngle = 0.f;
// </FS:Chanayane>
//--------------------------------------------------------------------
// Pan
//--------------------------------------------------------------------

View File

@ -984,6 +984,7 @@ void AISAPI::InvokeAISCommandCoro(LLCoreHttpUtil::HttpCoroutineAdapter::ptr_t ht
id = result["linked_id"];
}
break;
case COPYINVENTORY: // <FS:Ansariel> Bring this back from Kitty's patch
case CREATEINVENTORY:
// CREATEINVENTORY can have multiple callbacks
if (result.has("_created_categories"))
@ -1009,6 +1010,25 @@ void AISAPI::InvokeAISCommandCoro(LLCoreHttpUtil::HttpCoroutineAdapter::ptr_t ht
}
}
break;
// <FS:Zi> FIRE-34169 - Fix #RLV ~Subfolder creation
case UPDATECATEGORY:
if (result.has("_updated_categories"))
{
LLSD& items = result["_updated_categories"];
LLSD::array_const_iterator item_iter;
for (item_iter = items.beginArray(); item_iter != items.endArray(); ++item_iter)
{
LLUUID item_id = *item_iter;
callback(item_id);
needs_callback = false;
}
}
else if (result.has("category_id"))
{
id = result["category_id"];
}
break;
// </FS:Zi>
default:
break;
}

View File

@ -88,11 +88,17 @@ protected:
void onCameraTrack();
void onCameraRotate();
F32 getOrbitRate(F32 time);
// <FS:Chanayane> Camera roll (from Alchemy)
void onRollLeftHeldDown();
void onRollRightHeldDown();
// </FS:Chanayane>
private:
LLButton* mPlusBtn { nullptr };
LLButton* mMinusBtn{ nullptr };
LLSlider* mSlider{ nullptr };
LLButton* mRollLeft{ nullptr };
LLButton* mRollRight{ nullptr };
friend class LLUICtrlFactory;
};
@ -177,6 +183,10 @@ void LLPanelCameraZoom::onCreate()
mCommitCallbackRegistrar.add("Slider.value_changed", boost::bind(&LLPanelCameraZoom::onSliderValueChanged, this));
mCommitCallbackRegistrar.add("Camera.track", boost::bind(&LLPanelCameraZoom::onCameraTrack, this));
mCommitCallbackRegistrar.add("Camera.rotate", boost::bind(&LLPanelCameraZoom::onCameraRotate, this));
// <FS:Chanayane> Camera roll (from Alchemy)
mCommitCallbackRegistrar.add("Camera.roll_left", boost::bind(&LLPanelCameraZoom::onRollLeftHeldDown, this));
mCommitCallbackRegistrar.add("Camera.roll_right", boost::bind(&LLPanelCameraZoom::onRollRightHeldDown, this));
// </FS:Chanayane>
}
bool LLPanelCameraZoom::postBuild()
@ -184,6 +194,10 @@ bool LLPanelCameraZoom::postBuild()
mPlusBtn = getChild<LLButton>("zoom_plus_btn");
mMinusBtn = getChild<LLButton>("zoom_minus_btn");
mSlider = getChild<LLSlider>("zoom_slider");
// <FS:Chanayane> Camera roll (from Alchemy)
mRollLeft = getChild<LLButton>("roll_left");
mRollRight = getChild<LLButton>("roll_right");
// </FS:Chanayane>
return LLPanel::postBuild();
}
@ -213,6 +227,22 @@ void LLPanelCameraZoom::onZoomMinusHeldDown()
gAgentCamera.setOrbitOutKey(getOrbitRate(time));
}
// <FS:Chanayane> Camera roll (from Alchemy)
void LLPanelCameraZoom::onRollLeftHeldDown()
{
F32 time = mRollLeft->getHeldDownTime();
gAgentCamera.unlockView();
gAgentCamera.setRollLeftKey(getOrbitRate(time));
}
void LLPanelCameraZoom::onRollRightHeldDown()
{
F32 time = mRollRight->getHeldDownTime();
gAgentCamera.unlockView();
gAgentCamera.setRollRightKey(getOrbitRate(time));
}
// </FS:Chanayane>
void LLPanelCameraZoom::onCameraTrack()
{
// EXP-202 when camera panning activated, remove the hint

View File

@ -685,6 +685,27 @@ void LLFloaterIMSessionTab::removeConversationViewParticipant(const LLUUID& part
LLFolderViewItem* widget = get_ptr_in_map(mConversationsWidgets,participant_id);
if (widget)
{
LLFolderViewModelItem* item_vmi = widget->getViewModelItem();
if (item_vmi && item_vmi->getNumRefs() == 1)
{
// This is the last pointer, remove participant from session
// before participant gets deleted on destroyView.
//
// Floater (widget) and participant's view can simultaneously
// co-own the model, in which case view is responsible for
// the deletion and floater is free to clear and recreate
// the list, yet there are cases where only widget owns
// the pointer so it should do the cleanup.
// See "add_participant".
//
// Todo: If it keeps causing issues turn participants
// into LLPointers in the session
LLParticipantList* session = getParticipantList();
if (session)
{
session->removeChild(item_vmi);
}
}
widget->destroyView();
}
mConversationsWidgets.erase(participant_id);

View File

@ -58,7 +58,10 @@ LLSnapshotFloaterView* gSnapshotFloaterView = NULL;
const F32 AUTO_SNAPSHOT_TIME_DELAY = 1.f;
const S32 MAX_POSTCARD_DATASIZE = 1572864; // 1.5 megabyte, similar to simulator limit
const S32 MAX_TEXTURE_SIZE = 512 ; //max upload texture size 512 * 512
// <FS:Chanayane> 2048x2048 snapshots upload to inventory
//const S32 MAX_TEXTURE_SIZE = 512 ; //max upload texture size 512 * 512
const S32 MAX_TEXTURE_SIZE = 2048 ; //max upload texture size 2048 * 2048
// <FS:Chanayane> 2048x2048 snapshots upload to inventory
static LLDefaultChildRegistry::Register<LLSnapshotFloaterView> r("snapshot_floater_view");

View File

@ -3903,11 +3903,11 @@ LLUUID LLIMMgr::addSession(
((IM_NOTHING_SPECIAL == dialog) || (IM_SESSION_P2P_INVITE == dialog) || (IM_SESSION_CONFERENCE_START == dialog)) &&
ids.size())
{
LLIMModel::LLIMSession* ad_hoc_found = LLIMModel::getInstance()->findAdHocIMSession(ids);
if (ad_hoc_found)
session = LLIMModel::getInstance()->findAdHocIMSession(ids);
if (session)
{
new_session = false;
session_id = ad_hoc_found->mSessionID;
session_id = session->mSessionID;
}
}
@ -4415,7 +4415,7 @@ bool LLIMMgr::startCall(const LLUUID& session_id, LLVoiceChannel::EDirection dir
{
LLVoiceChannel* voice_channel = LLIMModel::getInstance()->getVoiceChannel(session_id);
if (!voice_channel) return false;
if (!voice_channel_info.isUndefined())
if (voice_channel_info.isDefined() && voice_channel_info.isMap() && voice_channel_info.size() > 0)
{
voice_channel->setChannelInfo(voice_channel_info);
}

View File

@ -41,7 +41,10 @@
#include "llagentbenefits.h"
constexpr S32 MAX_TEXTURE_SIZE = 512 ; //max upload texture size 512 * 512
// <FS:Chanayane> 2048x2048 snapshots upload to inventory
//const S32 MAX_TEXTURE_SIZE = 512 ; //max upload texture size 512 * 512
const S32 MAX_TEXTURE_SIZE = 2048 ; //max upload texture size 2048 * 2048
// </FS:Chanayane>
S32 power_of_two(S32 sz, S32 upper)
{
@ -66,7 +69,12 @@ bool LLPanelSnapshot::postBuild()
LLUICtrl* save_btn = findChild<LLUICtrl>("save_btn");
if (save_btn)
{
save_btn->setLabelArg("[UPLOAD_COST]", std::to_string(LLAgentBenefitsMgr::current().getTextureUploadCost()));
// <FS:Chanayane> 2048x2048 snapshots upload to inventory
//save_btn->setLabelArg("[UPLOAD_COST]", std::to_string(LLAgentBenefitsMgr::current().getTextureUploadCost()));
S32 w = getTypedPreviewWidth();
S32 h = getTypedPreviewHeight();
save_btn->setLabelArg("[UPLOAD_COST]", std::to_string(LLAgentBenefitsMgr::current().getTextureUploadCost(w, h)));
// </FS:Chanayane>
}
// </FS:Ansariel>
getChild<LLUICtrl>(getImageSizeComboName())->setCommitCallback(boost::bind(&LLPanelSnapshot::onResolutionComboCommit, this, _1));

View File

@ -187,7 +187,23 @@ LLPanelSnapshotInventory::~LLPanelSnapshotInventory()
void LLPanelSnapshotInventoryBase::onSend()
{
S32 expected_upload_cost = LLAgentBenefitsMgr::current().getTextureUploadCost();
// <FS:Chanayane> 2048x2048 snapshots upload to inventory
//S32 expected_upload_cost = LLAgentBenefitsMgr::current().getTextureUploadCost();
S32 w = 0;
S32 h = 0;
if( mSnapshotFloater )
{
LLSnapshotLivePreview* preview = mSnapshotFloater->getPreviewView();
if( preview )
{
preview->getSize(w, h);
}
}
S32 expected_upload_cost = LLAgentBenefitsMgr::current().getTextureUploadCost(w, h);
// </FS:Chanayane>
if (can_afford_transaction(expected_upload_cost))
{
if (mSnapshotFloater)

View File

@ -30,6 +30,7 @@
#include "llsidetraypanelcontainer.h"
#include "llfloatersnapshot.h" // FIXME: create a snapshot model
#include "llsnapshotlivepreview.h" // <FS:Chanayane> 2048x2048 snapshots upload to inventory
#include "llfloaterreg.h"
#include "llfloaterflickr.h" // <FS:Ansariel> Share to Flickr
@ -92,7 +93,22 @@ void LLPanelSnapshotOptions::onOpen(const LLSD& key)
void LLPanelSnapshotOptions::updateUploadCost()
{
S32 upload_cost = LLAgentBenefitsMgr::current().getTextureUploadCost();
// <FS:Chanayane> 2048x2048 snapshots upload to inventory
//S32 upload_cost = LLAgentBenefitsMgr::current().getTextureUploadCost();
S32 w = 0;
S32 h = 0;
if( mSnapshotFloater )
{
LLSnapshotLivePreview* preview = mSnapshotFloater->getPreviewView();
if( preview )
{
preview->getSize(w, h);
}
}
S32 upload_cost = LLAgentBenefitsMgr::current().getTextureUploadCost(w, h);
// </FS:Chanayane>
getChild<LLUICtrl>("save_to_inventory_btn")->setLabelArg("[AMOUNT]", llformat("%d", upload_cost));
}

View File

@ -66,7 +66,10 @@ constexpr F32 FALL_TIME = 0.6f;
constexpr S32 BORDER_WIDTH = 6;
constexpr S32 TOP_PANEL_HEIGHT = 30;
constexpr S32 MAX_TEXTURE_SIZE = 512 ; //max upload texture size 512 * 512
// <FS:Chanayane> 2048x2048 snapshots upload to inventory
//const S32 MAX_TEXTURE_SIZE = 512 ; //max upload texture size 512 * 512
const S32 MAX_TEXTURE_SIZE = 2048 ; //max upload texture size 2048 * 2048
// <FS:Chanayane> 2048x2048 snapshots upload to inventory
std::set<LLSnapshotLivePreview*> LLSnapshotLivePreview::sList;
LLPointer<LLImageFormatted> LLSnapshotLivePreview::sSaveLocalImage = NULL;
@ -1137,7 +1140,10 @@ void LLSnapshotLivePreview::saveTexture(bool outfit_snapshot, std::string name)
LLAgentUI::buildLocationString(pos_string, LLAgentUI::LOCATION_FORMAT_FULL);
std::string who_took_it;
LLAgentUI::buildFullname(who_took_it);
S32 expected_upload_cost = LLAgentBenefitsMgr::current().getTextureUploadCost();
// <FS:Chanayane> 2048x2048 snapshots upload to inventory
//S32 expected_upload_cost = LLAgentBenefitsMgr::current().getTextureUploadCost();
S32 expected_upload_cost = LLAgentBenefitsMgr::current().getTextureUploadCost(scaled->getWidth(), scaled->getHeight());
// </FS:Chanayane>
std::string res_name = outfit_snapshot ? name : "Snapshot : " + pos_string;
std::string res_desc = outfit_snapshot ? "" : "Taken by " + who_took_it + " at " + pos_string;
LLFolderType::EType folder_type = outfit_snapshot ? LLFolderType::FT_NONE : LLFolderType::FT_SNAPSHOT_CATEGORY;

View File

@ -832,6 +832,7 @@ void LLIMSpeakerMgr::allowTextChat(const LLUUID& speaker_id, bool allow)
// chat muted at all anymore
// LLPointer<LLSpeaker> speakerp = findSpeaker(speaker_id);
// if (!speakerp || !mVoiceChannel) return;
if (!mVoiceChannel) return;
std::string url = gAgent.getRegionCapability("ChatSessionRequest");
LLSD data;

View File

@ -1814,6 +1814,7 @@ LLTextureCtrl::LLTextureCtrl(const LLTextureCtrl::Params& p)
mFallbackImage(p.fallback_image),
mTextEnabledColor(p.text_enabled_color), // <FS:Zi> Add label/caption colors
mTextDisabledColor(p.text_disabled_color), // <FS:Zi> Add label/caption colors
mLabel(p.label), // <FS:Zi> FIRE-34300 - Fix label not showing in texture picker floater title
// <FS:Ansariel> Mask texture if desired
mIsMasked(false)
{

View File

@ -12021,15 +12021,6 @@ class LLUpdateMembershipLabel : public view_listener_t
}
};
void handle_voice_morphing_subscribe()
{
LLWeb::loadURL(LLTrans::getString("voice_morphing_url"));
}
void handle_premium_voice_morphing_subscribe()
{
LLWeb::loadURL(LLTrans::getString("premium_voice_morphing_url"));
}
class LLToggleUIHints : public view_listener_t
{
@ -12452,16 +12443,6 @@ void initialize_menus()
// <FS:Ansariel> [FS Communication UI]
//view_listener_t::addMenu(new LLCommunicateNearbyChat(), "Communicate.NearbyChat");
// Communicate > Voice morphing > Subscribe...
commit.add("Communicate.VoiceMorphing.Subscribe", boost::bind(&handle_voice_morphing_subscribe));
// Communicate > Voice morphing > Premium perk...
commit.add("Communicate.VoiceMorphing.PremiumPerk", boost::bind(&handle_premium_voice_morphing_subscribe));
LLVivoxVoiceClient * voice_clientp = LLVivoxVoiceClient::getInstance();
enable.add("Communicate.VoiceMorphing.NoVoiceMorphing.Check"
, boost::bind(&LLVivoxVoiceClient::onCheckVoiceEffect, voice_clientp, "NoVoiceMorphing"));
commit.add("Communicate.VoiceMorphing.NoVoiceMorphing.Click"
, boost::bind(&LLVivoxVoiceClient::onClickVoiceEffect, voice_clientp, "NoVoiceMorphing"));
// World menu
view_listener_t::addMenu(new LLWorldAlwaysRun(), "World.AlwaysRun");
view_listener_t::addMenu(new LLWorldCreateLandmark(), "World.CreateLandmark");

View File

@ -96,7 +96,7 @@ void LLVoiceChannel::setChannelInfo(const LLSD &channelInfo)
if (mState == STATE_NO_CHANNEL_INFO)
{
if (mChannelInfo.isUndefined())
if (mChannelInfo.isUndefined() || !mChannelInfo.isMap() || mChannelInfo.size() == 0)
{
LLNotificationsUtil::add("VoiceChannelJoinFailed", mNotifyArgs);
LL_WARNS("Voice") << "Received empty channel info for channel " << mSessionName << LL_ENDL;
@ -122,7 +122,7 @@ void LLVoiceChannel::onChange(EStatusType type, const LLSD& channelInfo, bool pr
{
LL_DEBUGS("Voice") << "Incoming channel info: " << channelInfo << LL_ENDL;
LL_DEBUGS("Voice") << "Current channel info: " << mChannelInfo << LL_ENDL;
if (mChannelInfo.isUndefined())
if (mChannelInfo.isUndefined() || (mChannelInfo.isMap() && mChannelInfo.size() == 0))
{
mChannelInfo = channelInfo;
}
@ -477,7 +477,7 @@ void LLVoiceChannelGroup::setChannelInfo(const LLSD& channelInfo)
if (mState == STATE_NO_CHANNEL_INFO)
{
if(!mChannelInfo.isUndefined())
if(mChannelInfo.isDefined() && mChannelInfo.isMap())
{
setState(STATE_READY);
@ -676,9 +676,9 @@ void LLVoiceChannelProximal::activate()
// we're connected to a non-spatial channel, so disconnect.
LLVoiceClient::getInstance()->leaveNonSpatialChannel();
}
LLVoiceClient::getInstance()->activateSpatialChannel(true);
LLVoiceChannel::activate();
}
void LLVoiceChannelProximal::onChange(EStatusType type, const LLSD& channelInfo, bool proximal)
@ -751,7 +751,7 @@ void LLVoiceChannelProximal::deactivate()
{
setState(STATE_HUNG_UP);
}
LLVoiceClient::getInstance()->removeObserver(this);
LLVoiceClient::getInstance()->activateSpatialChannel(false);
}
@ -907,7 +907,7 @@ void LLVoiceChannelP2P::setChannelInfo(const LLSD& channel_info)
}
mReceivedCall = true;
if (!channel_info.isUndefined())
if (channel_info.isDefined() && channel_info.isMap())
{
mIncomingCallInterface = LLVoiceClient::getInstance()->getIncomingCallInterface(channel_info);
}

View File

@ -147,6 +147,7 @@ LLVoiceClient::LLVoiceClient(LLPumpIO *pump)
m_servicePump(NULL),
mVoiceEffectEnabled(LLCachedControl<bool>(gSavedSettings, "VoiceMorphingEnabled", true)),
mVoiceEffectDefault(LLCachedControl<std::string>(gSavedPerAccountSettings, "VoiceEffectDefault", "00000000-0000-0000-0000-000000000000")),
mVoiceEffectSupportNotified(false),
mPTTDirty(true),
mPTT(true),
mUsePTT(true),
@ -582,6 +583,26 @@ void LLVoiceClient::setMicGain(F32 gain)
//------------------------------------------
// enable/disable voice features
// static
bool LLVoiceClient::onVoiceEffectsNotSupported(const LLSD &notification, const LLSD &response)
{
S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
switch (option)
{
case 0: // "Okay"
gSavedPerAccountSettings.setString("VoiceEffectDefault", LLUUID::null.asString());
break;
case 1: // "Cancel"
break;
default:
llassert(0);
break;
}
return false;
}
// <FS:Ansariel> Bypass LLCachedControls for voice status update
//bool LLVoiceClient::voiceEnabled()
bool LLVoiceClient::voiceEnabled(bool no_cache)
@ -594,7 +615,13 @@ bool LLVoiceClient::voiceEnabled(bool no_cache)
static LLCachedControl<bool> enable_voice_chat(gSavedSettings, "EnableVoiceChat");
static LLCachedControl<bool> cmd_line_disable_voice(gSavedSettings, "CmdLineDisableVoice");
return enable_voice_chat && !cmd_line_disable_voice && !gNonInteractive;
bool enabled = enable_voice_chat && !cmd_line_disable_voice && !gNonInteractive;
if (enabled && !mVoiceEffectSupportNotified && getVoiceEffectEnabled() && !getVoiceEffectDefault().isNull())
{
LLNotificationsUtil::add("VoiceEffectsNotSupported", LLSD(), LLSD(), &LLVoiceClient::onVoiceEffectsNotSupported);
mVoiceEffectSupportNotified = true;
}
return enabled;
}
void LLVoiceClient::setVoiceEnabled(bool enabled)
@ -875,7 +902,7 @@ std::string LLVoiceClient::sipURIFromID(const LLUUID &id)
LLVoiceEffectInterface* LLVoiceClient::getVoiceEffectInterface() const
{
return getVoiceEffectEnabled() ? dynamic_cast<LLVoiceEffectInterface*>(mSpatialVoiceModule) : NULL;
return NULL;
}
///////////////////

View File

@ -539,6 +539,8 @@ public:
protected:
static bool onVoiceEffectsNotSupported(const LLSD &notification, const LLSD &response);
LLVoiceModuleInterface* mSpatialVoiceModule;
LLVoiceModuleInterface* mNonSpatialVoiceModule;
LLSD mSpatialCredentials; // used to store spatial credentials for vivox
@ -550,6 +552,7 @@ protected:
LLCachedControl<bool> mVoiceEffectEnabled;
LLCachedControl<std::string> mVoiceEffectDefault;
bool mVoiceEffectSupportNotified;
bool mPTTDirty;
bool mPTT;

View File

@ -2647,7 +2647,6 @@ void LLVivoxVoiceClient::sessionCreateSendMessage(const sessionStatePtr_t &sessi
stream
<< "<ConnectAudio>" << (startAudio?"true":"false") << "</ConnectAudio>"
<< "<ConnectText>" << (startText?"true":"false") << "</ConnectText>"
<< "<VoiceFontID>" << font_index << "</VoiceFontID>"
<< "<Name>" << mChannelName << "</Name>"
<< "</Request>\n\n\n";
LL_WARNS("Voice") << "Session.Create: " << stream.str() << LL_ENDL;
@ -2686,7 +2685,6 @@ void LLVivoxVoiceClient::sessionGroupAddSessionSendMessage(const sessionStatePtr
<< "<Name>" << mChannelName << "</Name>"
<< "<ConnectAudio>" << (startAudio?"true":"false") << "</ConnectAudio>"
<< "<ConnectText>" << (startText?"true":"false") << "</ConnectText>"
<< "<VoiceFontID>" << font_index << "</VoiceFontID>"
<< "<Password>" << password << "</Password>"
<< "<PasswordHashAlgorithm>SHA1UserName</PasswordHashAlgorithm>"
<< "</Request>\n\n\n"
@ -2710,7 +2708,6 @@ void LLVivoxVoiceClient::sessionMediaConnectSendMessage(const sessionStatePtr_t
<< "<Request requestId=\"" << session->mHandle << "\" action=\"Session.MediaConnect.1\">"
<< "<SessionGroupHandle>" << session->mGroupHandle << "</SessionGroupHandle>"
<< "<SessionHandle>" << session->mHandle << "</SessionHandle>"
<< "<VoiceFontID>" << font_index << "</VoiceFontID>"
<< "<Media>Audio</Media>"
<< "</Request>\n\n\n";
@ -5248,25 +5245,31 @@ void LLVivoxVoiceClient::processChannels(bool process)
bool LLVivoxVoiceClient::isCurrentChannel(const LLSD &channelInfo)
{
if (!mProcessChannels || (channelInfo["voice_server_type"].asString() != VIVOX_VOICE_SERVER_TYPE))
if (!mProcessChannels || (channelInfo.has("voice_server_type") && channelInfo["voice_server_type"].asString() != VIVOX_VOICE_SERVER_TYPE))
{
return false;
}
if (mAudioSession)
// favor the next audio session, as that's the one we're bringing up.
sessionStatePtr_t session = mNextAudioSession;
if (!session)
{
session = mAudioSession;
}
if (session)
{
if (!channelInfo["session_handle"].asString().empty())
{
return mAudioSession->mHandle == channelInfo["session_handle"].asString();
return session->mHandle == channelInfo["session_handle"].asString();
}
return channelInfo["channel_uri"].asString() == mAudioSession->mSIPURI;
return channelInfo["channel_uri"].asString() == session->mSIPURI;
}
return false;
}
bool LLVivoxVoiceClient::compareChannels(const LLSD& channelInfo1, const LLSD& channelInfo2)
{
return (channelInfo1["voice_server_type"] == VIVOX_VOICE_SERVER_TYPE) &&
(channelInfo1["voice_server_type"] == channelInfo2["voice_server_type"]) &&
return (!channelInfo1.has("voice_server_type") || (channelInfo1["voice_server_type"] == VIVOX_VOICE_SERVER_TYPE)) &&
(!channelInfo2.has("voice_server_type") || (channelInfo2["voice_server_type"] == VIVOX_VOICE_SERVER_TYPE)) &&
(channelInfo1["channel_uri"] == channelInfo2["channel_uri"]);
}

View File

@ -86,7 +86,7 @@ namespace {
const F32 VOLUME_SCALE_WEBRTC = 0.01f;
const F32 LEVEL_SCALE_WEBRTC = 0.008f;
const F32 SPEAKING_AUDIO_LEVEL = 0.35;
const F32 SPEAKING_AUDIO_LEVEL = 0.30;
static const std::string REPORTED_VOICE_SERVER_TYPE = "Secondlife WebRTC Gateway";
@ -1486,14 +1486,10 @@ void LLWebRTCVoiceClient::setMicGain(F32 gain)
if (gain != mMicGain)
{
mMicGain = gain;
sessionState::for_each(boost::bind(predSetMicGain, _1, gain));
mWebRTCDeviceInterface->setPeerConnectionGain(gain);
}
}
void LLWebRTCVoiceClient::predSetMicGain(const LLWebRTCVoiceClient::sessionStatePtr_t &session, F32 gain)
{
session->setMicGain(gain);
}
void LLWebRTCVoiceClient::setVoiceEnabled(bool enabled)
{
@ -1692,7 +1688,6 @@ std::map<std::string, LLWebRTCVoiceClient::sessionState::ptr_t> LLWebRTCVoiceCli
LLWebRTCVoiceClient::sessionState::sessionState() :
mHangupOnLastLeave(false),
mNotifyOnFirstJoin(false),
mMicGain(1.0),
mMuted(false),
mSpeakerVolume(1.0),
mShuttingDown(false)
@ -1737,15 +1732,6 @@ void LLWebRTCVoiceClient::sessionState::setMuteMic(bool muted)
}
}
void LLWebRTCVoiceClient::sessionState::setMicGain(F32 gain)
{
mMicGain = gain;
for (auto &connection : mWebRTCConnections)
{
connection->setMicGain(gain);
}
}
void LLWebRTCVoiceClient::sessionState::setSpeakerVolume(F32 volume)
{
mSpeakerVolume = volume;
@ -1850,7 +1836,6 @@ LLWebRTCVoiceClient::sessionStatePtr_t LLWebRTCVoiceClient::addSession(const std
LL_DEBUGS("Voice") << "adding new session with channel: " << channel_id << LL_ENDL;
session->setMuteMic(mMuteMic);
session->setMicGain(mMicGain);
session->setSpeakerVolume(mSpeakerVolume);
sessionState::addSession(channel_id, session);
@ -1976,7 +1961,6 @@ bool LLWebRTCVoiceClient::estateSessionState::processConnectionStates()
connectionPtr_t connection(new LLVoiceWebRTCSpatialConnection(neighbor, INVALID_PARCEL_ID, mChannelID));
mWebRTCConnections.push_back(connection);
connection->setMicGain(mMicGain);
connection->setMuteMic(mMuted);
connection->setSpeakerVolume(mSpeakerVolume);
}
@ -2106,7 +2090,6 @@ LLVoiceWebRTCConnection::LLVoiceWebRTCConnection(const LLUUID &regionID, const s
mShutDown(false),
mIceCompleted(false),
mSpeakerVolume(0.0),
mMicGain(0.0),
mOutstandingRequests(0),
mChannelID(channelID),
mRegionID(regionID),
@ -2369,15 +2352,6 @@ void LLVoiceWebRTCConnection::setMuteMic(bool muted)
}
}
void LLVoiceWebRTCConnection::setMicGain(F32 gain)
{
mMicGain = gain;
if (mWebRTCAudioInterface)
{
mWebRTCAudioInterface->setSendVolume(gain);
}
}
void LLVoiceWebRTCConnection::setSpeakerVolume(F32 volume)
{
mSpeakerVolume = volume;
@ -2679,7 +2653,6 @@ bool LLVoiceWebRTCConnection::connectionStateMachine()
// this connection.
mWebRTCAudioInterface->setMute(mMuted);
mWebRTCAudioInterface->setReceiveVolume(mSpeakerVolume);
mWebRTCAudioInterface->setSendVolume(mMicGain);
LLWebRTCVoiceClient::getInstance()->OnConnectionEstablished(mChannelID, mRegionID);
setVoiceConnectionState(VOICE_STATE_WAIT_FOR_DATA_CHANNEL);
break;

View File

@ -282,7 +282,6 @@ public:
virtual void sendData(const std::string &data);
void setMuteMic(bool muted);
void setMicGain(F32 volume);
void setSpeakerVolume(F32 volume);
void setUserVolume(const LLUUID& id, F32 volume);
@ -303,7 +302,6 @@ public:
std::string mName;
bool mMuted; // this session is muted.
F32 mMicGain; // gain for this session.
F32 mSpeakerVolume; // volume for this session.
bool mShuttingDown;
@ -382,7 +380,6 @@ public:
static void predSendData(const LLWebRTCVoiceClient::sessionStatePtr_t &session, const std::string& spatial_data);
static void predUpdateOwnVolume(const LLWebRTCVoiceClient::sessionStatePtr_t &session, F32 audio_level);
static void predSetMuteMic(const LLWebRTCVoiceClient::sessionStatePtr_t &session, bool mute);
static void predSetMicGain(const LLWebRTCVoiceClient::sessionStatePtr_t &session, F32 volume);
static void predSetSpeakerVolume(const LLWebRTCVoiceClient::sessionStatePtr_t &session, F32 volume);
static void predShutdownSession(const LLWebRTCVoiceClient::sessionStatePtr_t &session);
static void predSetUserMute(const LLWebRTCVoiceClient::sessionStatePtr_t &session, const LLUUID& id, bool mute);
@ -607,7 +604,6 @@ class LLVoiceWebRTCConnection :
void processIceUpdatesCoro();
virtual void setMuteMic(bool muted);
virtual void setMicGain(F32 volume);
virtual void setSpeakerVolume(F32 volume);
void setUserVolume(const LLUUID& id, F32 volume);
@ -686,7 +682,6 @@ class LLVoiceWebRTCConnection :
std::string mRemoteChannelSDP;
bool mMuted;
F32 mMicGain;
F32 mSpeakerVolume;
bool mShutDown;

View File

@ -575,42 +575,24 @@ void RlvGiveToRLVOffer::moveAndRename(const LLUUID& idFolder, const LLUUID& idDe
const LLViewerInventoryCategory* pFolder = gInventory.getCategory(idFolder);
if ( (idDestination.notNull()) && (pFolder) )
{
bool needsRename = (pFolder->getName() != strName);
gInventory.changeCategoryParent(gInventory.getCategory(idFolder), idDestination, false);
gInventory.addChangedMask(LLInventoryObserver::STRUCTURE, idFolder);
gInventory.notifyObservers();
gInventory.fetchDescendentsOf(idDestination);
LLPointer<LLInventoryCallback> cbMove;
if (idDestination != pFolder->getParentUUID())
// rename and restart this function if the folder doesn't have the correct name.
// This will also trigger another move above, but that should have no ill effects
// and might even help when the folder didn't move correctly the first time. -Zi
if (pFolder->getName() != strName)
{
// We have to move *after* the rename operation completes or AIS will drop it
if (!needsRename)
{
LLInventoryModel::update_list_t update;
LLInventoryModel::LLCategoryUpdate updOldParent(pFolder->getParentUUID(), -1);
update.push_back(updOldParent);
LLInventoryModel::LLCategoryUpdate updNewParent(idDestination, 1);
update.push_back(updNewParent);
gInventory.accountForUpdate(update);
LLPointer<LLViewerInventoryCategory> pNewFolder = new LLViewerInventoryCategory(pFolder);
pNewFolder->setParent(idDestination);
pNewFolder->updateParentOnServer(false);
gInventory.updateCategory(pNewFolder);
gInventory.notifyObservers();
if (cbFinal)
{
cbFinal.get()->fire(idFolder);
}
}
else
{
cbMove = new LLBoostFuncInventoryCallback(boost::bind(RlvGiveToRLVOffer::moveAndRename, _1, idDestination, strName, cbFinal));
}
LLPointer<LLInventoryCallback> cb = new LLBoostFuncInventoryCallback(boost::bind(RlvGiveToRLVOffer::moveAndRename, _1, idDestination, strName, cbFinal));
rename_category(&gInventory, idFolder, strName, cb);
return;
}
if (needsRename)
if (cbFinal)
{
rename_category(&gInventory, idFolder, strName, (cbMove) ? cbMove : cbFinal);
cbFinal.get()->fire(idFolder);
}
}
else if (cbFinal)

View File

@ -19,6 +19,8 @@
<panel name="controls">
<panel name="zoom">
<joystick_rotate name="cam_rotate_stick" tool_tip="Kamera um Fokus kreisen"/>
<button name="roll_left" tool_tip="Kamera nach links rollen" />
<button name="roll_right" tool_tip="Kamera nach rechts rollen" />
<slider_bar name="zoom_slider" tool_tip="Kamera auf Fokus zoomen"/>
<joystick_track name="cam_track_stick" tool_tip="Kamera nach oben, unten, links und rechts bewegen"/>
</panel>

View File

@ -71,6 +71,36 @@
tool_tip="Orbit camera around focus"
top="25"
width="78" />
<!-- <FS:Chanayane> Camera roll (from Alchemy) -->
<button
follows="bottom|left"
width="16"
height="16"
image_selected="VirtualTrackball_Rotate_Left_Active"
image_unselected="VirtualTrackball_Rotate_Left"
layout="topleft"
top="89"
left="2"
name="roll_left"
tool_tip="Roll camera Left">
<commit_callback function="Camera.roll_left" />
<mouse_held_callback function="Camera.roll_left" />
</button>
<button
follows="top|left"
width="16"
height="16"
image_selected="VirtualTrackball_Rotate_Right_Active"
image_unselected="VirtualTrackball_Rotate_Right"
layout="topleft"
top="89"
left="64"
name="roll_right"
tool_tip="Roll camera Right">
<commit_callback function="Camera.roll_right" />
<mouse_held_callback function="Camera.roll_right" />
</button>
<!-- </FS:Chanayane> -->
<button
follows="top|left"
height="18"

View File

@ -18,6 +18,8 @@
<panel name="controls">
<panel name="zoom">
<joystick_rotate name="cam_rotate_stick" tool_tip="Obróć kamerę wokół punktu skupienia"/>
<button name="roll_left" tool_tip="Przechyl kamerę w lewo" />
<button name="roll_right" tool_tip="Przechyl kamerę w prawo" />
<slider_bar name="zoom_slider" tool_tip="Przybliż kamerę do punktu skupienia"/>
<joystick_track name="cam_track_stick" tool_tip="Poruszaj kamerą w górę, w dół, w lewo i w prawo"/>
</panel>

View File

@ -19,6 +19,8 @@
<layout_stack name="camera_view_layout_stack">
<layout_panel name="camera_rotate_layout_panel">
<joystick_rotate name="cam_rotate_stick" tool_tip="Kamera um Fokus kreisen"/>
<button name="roll_left" tool_tip="Kamera nach links rollen" />
<button name="roll_right" tool_tip="Kamera nach rechts rollen" />
</layout_panel>
<layout_panel name="camera_zoom_layout_panel">
<slider_bar name="zoom_slider" tool_tip="Kamera auf Fokus zoomen"/>

View File

@ -17,6 +17,8 @@
<layout_stack name="camera_view_layout_stack">
<layout_panel name="camera_rotate_layout_panel">
<joystick_rotate name="cam_rotate_stick" tool_tip="Kamera um Fokus kreisen"/>
<button name="roll_left" tool_tip="Kamera nach links rollen" />
<button name="roll_right" tool_tip="Kamera nach rechts rollen" />
</layout_panel>
<layout_panel name="camera_zoom_layout_panel">
<slider_bar name="zoom_slider" tool_tip="Kamera auf Fokus zoomen"/>

View File

@ -103,13 +103,6 @@
<menu_item_check label="Gesten" name="Gestures"/>
<menu_item_call label="Twitter..." name="Twitter"/>
<menu_item_call label="Flickr..." name="Flickr"/>
<menu_item_call label="Discord..." name="Discord"/>
<menu label="Voice-Morphing" name="VoiceMorphing">
<menu_item_check label="Kein Voice-Morphing" name="NoVoiceMorphing"/>
<menu_item_check label="Vorschau..." name="Preview"/>
<menu_item_call label="Abonnieren..." name="Subscribe"/>
<menu_item_call label="Premium-Vorteil..." name="PremiumPerk"/>
</menu>
<menu_item_check label="Unterhaltungsprotokoll..." name="Conversation Log..."/>
<menu_item_check label="Stimmen in der Nähe" name="Nearby Voice"/>
<menu_item_call label="Blockierliste" name="Block List"/>

View File

@ -3624,6 +3624,10 @@ Wenn Sie Premium-Mitglied sind, [[PREMIUM_URL] klicken Sie hier], um Ihren Voice
<notification name="VoiceEffectsNew">
Neue Voice-Morph-Effekte sind erhältlich!
</notification>
<notification name="VoiceEffectsNotSupported">
Voice-Morph-Effekte werden von diesem Viewer nicht unterstützt.
<usetemplate notext="Abbrechen" name="okcancelbuttons" yestext="Voice-Morph deaktivieren"/>
</notification>
<notification name="Cannot enter parcel: not a group member">
Nur Mitglieder einer bestimmten Gruppe dürfen diesen Bereich betreten.
</notification>

View File

@ -155,6 +155,36 @@
tool_tip="Orbit camera around focus"
held_down_delay.seconds="0.0"
top="0" />
<!-- <FS:Chanayane> Camera roll (from Alchemy) -->
<button
follows="bottom|left"
width="12"
height="12"
image_selected="VirtualTrackball_Rotate_Left_Active"
image_unselected="VirtualTrackball_Rotate_Left"
layout="topleft"
top_delta="68"
left_delta="0"
name="roll_left"
tool_tip="Roll camera Left">
<commit_callback function="Camera.roll_left" />
<mouse_held_callback function="Camera.roll_left" />
</button>
<button
follows="bottom|right"
width="12"
height="12"
image_selected="VirtualTrackball_Rotate_Right_Active"
image_unselected="VirtualTrackball_Rotate_Right"
layout="topleft"
top_delta="0"
left_delta="68"
name="roll_right"
tool_tip="Roll camera Right">
<commit_callback function="Camera.roll_right" />
<mouse_held_callback function="Camera.roll_right" />
</button>
<!-- </FS:Chanayane> -->
</layout_panel>
<layout_panel

View File

@ -96,6 +96,36 @@ free_mode_title
tool_tip="Orbit camera around focus"
held_down_delay.seconds="0.0"
top="0" />
<!-- <FS:Chanayane> Camera roll (from Alchemy) -->
<button
follows="bottom|left"
width="12"
height="12"
image_selected="VirtualTrackball_Rotate_Left_Active"
image_unselected="VirtualTrackball_Rotate_Left"
layout="topleft"
top_delta="68"
left_delta="0"
name="roll_left"
tool_tip="Roll camera Left">
<commit_callback function="Camera.roll_left" />
<mouse_held_callback function="Camera.roll_left" />
</button>
<button
follows="bottom|right"
width="12"
height="12"
image_selected="VirtualTrackball_Rotate_Right_Active"
image_unselected="VirtualTrackball_Rotate_Right"
layout="topleft"
top_delta="0"
left_delta="68"
name="roll_right"
tool_tip="Roll camera Right">
<commit_callback function="Camera.roll_right" />
<mouse_held_callback function="Camera.roll_right" />
</button>
<!-- </FS:Chanayane> -->
</layout_panel>
<layout_panel

View File

@ -847,42 +847,6 @@
parameter="fs_discord"/>
</menu_item_call>
<menu_item_separator/>
<menu
label="Voice morphing"
name="VoiceMorphing"
visibility_control="VoiceMorphingEnabled">
<menu_item_check
label="No voice morphing"
name="NoVoiceMorphing">
<menu_item_check.on_check
function="Communicate.VoiceMorphing.NoVoiceMorphing.Check" />
<menu_item_check.on_click
function="Communicate.VoiceMorphing.NoVoiceMorphing.Click" />
</menu_item_check>
<menu_item_separator/>
<menu_item_check
label="Preview..."
name="Preview">
<menu_item_check.on_check
function="Floater.Visible"
parameter="voice_effect" />
<menu_item_check.on_click
function="Floater.Toggle"
parameter="voice_effect" />
</menu_item_check>
<menu_item_call
label="Subscribe..."
name="Subscribe">
<menu_item_call.on_click
function="Communicate.VoiceMorphing.Subscribe" />
</menu_item_call>
<menu_item_call
label="Premium perk..."
name="PremiumPerk">
<menu_item_call.on_click
function="Communicate.VoiceMorphing.PremiumPerk" />
</menu_item_call>
</menu>
<menu_item_check
name="Conversation Log..."
label="Conversation Log...">

View File

@ -9498,6 +9498,20 @@ New Voice Morphs are available!
<tag>voice</tag>
</notification>
<notification
icon="alertmodal.tga"
name="VoiceEffectsNotSupported"
sound="UISndAlert"
persist="true"
type="alertmodal">
Voice Morphs are not supported by this viewer.
<usetemplate
notext="Cancel"
name="okcancelbuttons"
yestext="Disable Voice Morphing"/>
<tag>voice</tag>
</notification>
<notification
icon="notifytip.tga"
name="Cannot enter parcel: not a group member"

View File

@ -1111,7 +1111,6 @@
</text>
<combo_box
control_name="VoiceNoiseSuppressionLevel"
enabled_control="AudioStreamingMedia"
layout="topleft"
height="23"
left_pad="10"

View File

@ -69,11 +69,6 @@
<menu_item_check label="Gente" name="People"/>
<menu_item_check label="Conversaciones" name="Conversations"/>
<menu_item_check label="Gestos" name="Gestures"/>
<menu label="Filtro de voz" name="VoiceMorphing">
<menu_item_check label="Sin filtro de voz" name="NoVoiceMorphing"/>
<menu_item_check label="Probar..." name="Preview"/>
<menu_item_call label="Suscribir..." name="Subscribe"/>
</menu>
<menu_item_check name="Conversation Log..." label="Registro de conversaciones..."/>
<menu_item_check label="Chat de voz" name="Nearby Voice"/>
<menu_item_call label="Lista de bloqueados" name="Block List"/>

View File

@ -92,12 +92,6 @@
<menu_item_check label="Persone" name="People"/>
<menu_item_check label="Conversazioni" name="Conversations"/>
<menu_item_check label="Gesti" name="Gestures"/>
<menu label="Modifica voce" name="VoiceMorphing">
<menu_item_check label="Nessuna modifica" name="NoVoiceMorphing"/>
<menu_item_check label="Anteprima..." name="Preview"/>
<menu_item_call label="Iscrizione..." name="Subscribe"/>
<menu_item_call label="Offerta Premium..." name="PremiumPerk"/>
</menu>
<menu_item_check label="Storico Conversazioni" name="Conversation Log..."/>
<menu_item_check label="Voce nelle vicinanze" name="Nearby Voice"/>
<menu_item_call label="Lista Bloccati" name="Block List"/>

View File

@ -108,14 +108,6 @@
<menu_item_call label="Twitter..." name="Twitter" />
<menu_item_call label="Flickr..." name="Flickr" />
<menu_item_call label="Discord..." name="Discord"/>
<menu_item_separator/>
<menu label="ボイスモーフィング" name="VoiceMorphing">
<menu_item_check label="ボイスモーフィングなし" name="NoVoiceMorphing" />
<menu_item_separator/>
<menu_item_check label="プレビュー..." name="Preview" />
<menu_item_call label="購入..." name="Subscribe" />
<menu_item_call label="プレミアム特典..." name="PremiumPerk" />
</menu>
<menu_item_check name="Conversation Log..." label="会話ログ..." />
<menu_item_check label="近くのボイス" name="Nearby Voice"/>
<menu_item_call label="ブロックリスト" name="Block List"/>

View File

@ -27,6 +27,8 @@
<layout_stack name="camera_view_layout_stack">
<layout_panel name="camera_rotate_layout_panel">
<joystick_rotate name="cam_rotate_stick" tool_tip="Obróć kamerę wokół punktu skupienia" />
<button name="roll_left" tool_tip="Przechyl kamerę w lewo" />
<button name="roll_right" tool_tip="Przechyl kamerę w prawo" />
</layout_panel>
<layout_panel name="camera_zoom_layout_panel">
<slider_bar name="zoom_slider" tool_tip="Przybliż kamerę do punktu skupienia" />

View File

@ -16,6 +16,8 @@
<layout_stack name="camera_view_layout_stack">
<layout_panel name="camera_rotate_layout_panel">
<joystick_rotate name="cam_rotate_stick" tool_tip="Obróć kamerę wokół punktu skupienia" />
<button name="roll_left" tool_tip="Przechyl kamerę w lewo" />
<button name="roll_right" tool_tip="Przechyl kamerę w prawo" />
</layout_panel>
<layout_panel name="camera_zoom_layout_panel">
<slider_bar name="zoom_slider" tool_tip="Przybliż kamerę do punktu skupienia" />

View File

@ -92,12 +92,6 @@
<menu_item_check label="Ludzie" name="People"/>
<menu_item_check label="Rozmowy" name="Conversations"/>
<menu_item_check label="Gesty" name="Gestures"/>
<menu label="Przekształcanie głosu" name="VoiceMorphing">
<menu_item_check label="Bez przekształcania" name="NoVoiceMorphing"/>
<menu_item_check label="Podgląd..." name="Preview"/>
<menu_item_call label="Subskrybuj..." name="Subscribe"/>
<menu_item_call label="Korzyści premium..." name="PremiumPerk" />
</menu>
<menu_item_check name="Conversation Log..." label="Dziennik rozmów..."/>
<menu_item_check label="Głos w pobliżu" name="Nearby Voice"/>
<menu_item_call label="Lista zablokowanych" name="Block List"/>

View File

@ -43,12 +43,6 @@
<menu_item_check label="Bate-papo local..." name="Nearby Chat"/>
<menu_item_check label="Falar" name="Speak"/>
<menu_item_check label="Registro de conversas..." name="Conversation Log..."/>
<menu label="Distorção de voz" name="VoiceMorphing">
<menu_item_check label="Não distorcer voz" name="NoVoiceMorphing"/>
<menu_item_check label="Visualizar..." name="Preview"/>
<menu_item_call label="Assinar..." name="Subscribe"/>
<menu_item_call label="Benefício Premium..." name="PremiumPerk"/>
</menu>
<menu_item_check label="Gestos..." name="Gestures"/>
<menu_item_check label="Amigos" name="My Friends"/>
<menu_item_check label="Grupos" name="My Groups"/>

View File

@ -103,12 +103,6 @@
<menu_item_check label="Люди" name="People"/>
<menu_item_check label="Разговоры" name="Conversations"/>
<menu_item_check label="Жесты" name="Gestures"/>
<menu label="Изменение голоса" name="VoiceMorphing">
<menu_item_check label="Нет изменений голоса" name="NoVoiceMorphing"/>
<menu_item_check label="Предварительный просмотр..." name="Preview"/>
<menu_item_call label="Подписаться..." name="Subscribe"/>
<menu_item_call label="Премиум привилегия..." name="PremiumPerk"/>
</menu>
<menu_item_check name="Conversation Log..." label="Журнал разговоров..."/>
<menu_item_check label="Ближайшие голоса" name="Nearby Voice"/>
<menu_item_call label="Список заблокированных" name="Block List"/>

View File

@ -37,12 +37,6 @@
<menu_item_check label="Yakındaki Sohbet..." name="Nearby Chat"/>
<menu_item_check label="Konuş" name="Speak"/>
<menu_item_check label="Sohbet Günlüğü..." name="Conversation Log..."/>
<menu label="Ses şekillendirme" name="VoiceMorphing">
<menu_item_check label="Ses şekillendirme yok" name="NoVoiceMorphing"/>
<menu_item_check label="Önizleme..." name="Preview"/>
<menu_item_call label="Abone ol..." name="Subscribe"/>
<menu_item_call label="Özel üye avantajı..." name="PremiumPerk"/>
</menu>
<menu_item_check label="Mimikler..." name="Gestures"/>
<menu_item_check label="Arkadaşlar" name="My Friends"/>
<menu_item_check label="Gruplar" name="My Groups"/>

View File

@ -37,12 +37,6 @@
<menu_item_check label="附近的聊天……" name="Nearby Chat"/>
<menu_item_check label="說話" name="Speak"/>
<menu_item_check label="交談記錄…" name="Conversation Log..."/>
<menu label="語音變聲" name="VoiceMorphing">
<menu_item_check label="沒有變聲效果" name="NoVoiceMorphing"/>
<menu_item_check label="預覽……" name="Preview"/>
<menu_item_call label="訂閱……" name="Subscribe"/>
<menu_item_call label="付費會員獨享…" name="PremiumPerk"/>
</menu>
<menu_item_check label="姿勢…" name="Gestures"/>
<menu_item_check label="朋友" name="My Friends"/>
<menu_item_check label="群組" name="My Groups"/>