fix(gui): only send outscale when needed
This commit is contained in:
parent
9f9736c30c
commit
35445ff0f6
|
@ -297,8 +297,6 @@ export function appendModelToURL(url: URL, params: ModelParams) {
|
|||
* Append the upscale parameters to an existing URL.
|
||||
*/
|
||||
export function appendUpscaleToURL(url: URL, upscale: UpscaleParams) {
|
||||
url.searchParams.append('outscale', upscale.outscale.toFixed(FIXED_INTEGER));
|
||||
|
||||
if (upscale.enabled) {
|
||||
url.searchParams.append('denoise', upscale.denoise.toFixed(FIXED_FLOAT));
|
||||
url.searchParams.append('scale', upscale.scale.toFixed(FIXED_INTEGER));
|
||||
|
@ -308,6 +306,10 @@ export function appendUpscaleToURL(url: URL, upscale: UpscaleParams) {
|
|||
url.searchParams.append('faces', String(upscale.faces));
|
||||
url.searchParams.append('faceStrength', upscale.faceStrength.toFixed(FIXED_FLOAT));
|
||||
}
|
||||
|
||||
if (upscale.enabled || upscale.faces) {
|
||||
url.searchParams.append('outscale', upscale.outscale.toFixed(FIXED_INTEGER));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue