fix odd numbers
All checks were successful
Build Images and Deploy / Update-PROD-Stack (push) Successful in 1m7s
All checks were successful
Build Images and Deploy / Update-PROD-Stack (push) Successful in 1m7s
This commit is contained in:
@@ -845,8 +845,9 @@
|
||||
const cropWidth = parseInt(document.getElementById('crop-width').value) || videoInfo.width;
|
||||
const cropHeight = parseInt(document.getElementById('crop-height').value) || videoInfo.height;
|
||||
|
||||
const outputWidth = Math.round((cropWidth * scalePercentage) / 100);
|
||||
const outputHeight = Math.round((cropHeight * scalePercentage) / 100);
|
||||
// Round to nearest even number for H.264 compatibility
|
||||
const outputWidth = Math.round((cropWidth * scalePercentage) / 100 / 2) * 2;
|
||||
const outputHeight = Math.round((cropHeight * scalePercentage) / 100 / 2) * 2;
|
||||
|
||||
outputResolution.textContent = `${outputWidth}x${outputHeight}`;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user