Clamp controlnet images to multiples of 8

This commit is contained in:
cmdr2 2023-08-03 15:51:39 +05:30
parent b97c906128
commit 83a5b5b46f

View File

@ -2245,6 +2245,9 @@ controlImageSelector.addEventListener("change", loadControlnetImageFromFile)
function controlImageLoad() {
let w = controlImagePreview.naturalWidth
let h = controlImagePreview.naturalHeight
w = w - (w % 8)
h = h - (h % 8)
addImageSizeOption(w)
addImageSizeOption(h)