mirror of
https://gitcode.com/GitHub_Trending/ji/jitsi-meet.git
synced 2026-05-18 11:07:46 +00:00
rn,flags: add ability to override resolution using a flag
Also, use the configured resolution to set it as the max received frame size.
This commit is contained in:
committed by
Saúl Ibarra Corretgé
parent
8d1bde3cb1
commit
7d513738d2
@@ -460,7 +460,10 @@ function _sendTones({ getState }, next, action) {
|
||||
*/
|
||||
function _setReceiverVideoConstraint(conference, preferred, max) {
|
||||
if (conference) {
|
||||
conference.setReceiverVideoConstraint(Math.min(preferred, max));
|
||||
const value = Math.min(preferred, max);
|
||||
|
||||
conference.setReceiverVideoConstraint(value);
|
||||
logger.info(`setReceiverVideoConstraint: ${value}`);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
import { jitsiLocalStorage } from 'js-utils';
|
||||
|
||||
import { APP_WILL_MOUNT } from '../app';
|
||||
import { getFeatureFlag } from '../flags/functions';
|
||||
import { addKnownDomains } from '../known-domains';
|
||||
import { MiddlewareRegistry } from '../redux';
|
||||
import { parseURIString } from '../util';
|
||||
@@ -107,6 +108,12 @@ function _setConfig({ dispatch, getState }, next, action) {
|
||||
config.p2p = { enabled: !settings.disableP2P };
|
||||
}
|
||||
|
||||
const resolutionFlag = getFeatureFlag(state, 'resolution');
|
||||
|
||||
if (typeof resolutionFlag !== 'undefined') {
|
||||
config.resolution = resolutionFlag;
|
||||
}
|
||||
|
||||
dispatch({
|
||||
type: _UPDATE_CONFIG,
|
||||
config
|
||||
|
||||
@@ -81,6 +81,13 @@ export const RAISE_HAND_ENABLED = 'raise-hand.enabled';
|
||||
*/
|
||||
export const RECORDING_ENABLED = 'recording.enabled';
|
||||
|
||||
/**
|
||||
* Flag indicating the local and (maximum) remote video resolution. Overrides
|
||||
* the server configuration.
|
||||
* Default: (unset).
|
||||
*/
|
||||
export const RESOLUTION = 'resolution';
|
||||
|
||||
/**
|
||||
* Flag indicating if server URL change is enabled.
|
||||
* Default: enabled (true)
|
||||
|
||||
Reference in New Issue
Block a user