Flatten image edit controls and let CFG/steps be typed past the old slider caps.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -3,6 +3,7 @@ import { join } from 'node:path'
|
||||
import { composeShotPrompt } from '~/utils/globalLocks'
|
||||
import { parsePostedLoraStack, listStudioLoras, persistLoraFields } from '~/server/utils/loras'
|
||||
import { readLoraStack } from '~/utils/loras'
|
||||
import { clampVideoCfg } from '~/utils/generationPresets'
|
||||
import { defaultVideoSteps, isLtxWorkflow, LTX_DISABLED_MESSAGE, ltxWorkflowEnabled, parseVideoWorkflow } from '~/utils/videoModels'
|
||||
|
||||
const SAMPLERS = new Set(['res_multistep', 'euler', 'dpmpp_2m'])
|
||||
@@ -24,11 +25,7 @@ function parseFps(raw: unknown) {
|
||||
}
|
||||
|
||||
function parseCfg(raw: unknown, turbo: boolean) {
|
||||
const fallback = turbo ? 1.5 : 4
|
||||
const value = Number(raw)
|
||||
if (!Number.isFinite(value)) return fallback
|
||||
const snapped = Math.round(value * 2) / 2
|
||||
return Math.min(10, Math.max(1, snapped))
|
||||
return clampVideoCfg(raw, turbo ? 1.5 : 4)
|
||||
}
|
||||
|
||||
function parseSampler(raw: unknown) {
|
||||
|
||||
Reference in New Issue
Block a user