Skip to content

🎥 Make videos programmatically with React

document scale parameters

Jonny Burger50d78c5c7f23
diff --git a/packages/docs/docs/lambda/rendermediaonlambda.md b/packages/docs/docs/lambda/rendermediaonlambda.md
index 3a855d663a..780b2d5c91 100644
--- a/packages/docs/docs/lambda/rendermediaonlambda.md
+++ b/packages/docs/docs/lambda/rendermediaonlambda.md
@@ -121,6 +121,12 @@ _optional, default `1`_
How often a chunk may be retried to render in case the render fails.
If a rendering of a chunk is failed, the error will be reported in the [`getRenderProgress()`](/docs/lambda/getrenderprogress) object and retried up to as many times as you specify using this option.
+### `scale`
+
+_optional_
+
+Scales the output dimensions by a factor. See [Scaling](/docs/scaling) to learn more about this feature.
+
### `outName`
_optional_
diff --git a/packages/docs/docs/lambda/renderstillonlambda.md b/packages/docs/docs/lambda/renderstillonlambda.md
index c0cf0c5bc9..9eced5afc4 100644
--- a/packages/docs/docs/lambda/renderstillonlambda.md
+++ b/packages/docs/docs/lambda/renderstillonlambda.md
@@ -98,6 +98,12 @@ _optional - default `{}`_
See [`renderMedia() -> envVariables`](/docs/renderer/render-media#envvariables).
+### `scale`
+
+_optional_
+
+Scales the output dimensions by a factor. See [Scaling](/docs/scaling) to learn more about this feature.
+
### `outName`
_optional_
diff --git a/packages/docs/docs/renderer/render-media.md b/packages/docs/docs/renderer/render-media.md
index dc267cb2ca..5ba3e0c065 100644
--- a/packages/docs/docs/renderer/render-media.md
+++ b/packages/docs/docs/renderer/render-media.md
@@ -146,6 +146,12 @@ _puppeteer.Browser - optional_
An already open Puppeteer [`Browser`](https://pptr.dev/#?product=Puppeteer&version=main&show=api-class-browser) instance. Use [`openBrowser()`](/docs/renderer/open-browser) to create a new instance. Reusing a browser across multiple function calls can speed up the rendering process. You are responsible for opening and closing the browser yourself. If you don't specify this option, a new browser will be opened and closed at the end.
+### `scale`
+
+_optional_
+
+Scales the output dimensions by a factor. See [Scaling](/docs/scaling) to learn more about this feature.
+
### `overwrite`
_boolean - optional_
diff --git a/packages/docs/docs/renderer/render-still.md b/packages/docs/docs/renderer/render-still.md
index dcc2aa64c4..9d57a62e15 100644
--- a/packages/docs/docs/renderer/render-still.md
+++ b/packages/docs/docs/renderer/render-still.md
@@ -85,9 +85,9 @@ Which output format the image should have, either `png` or `jpeg`.
### `scale?`
-_number - default: 1 - available from v2.6.7_
+_optional_
-[Scales the output frames by the factor you pass in.](/docs/scaling) For example, a 1280x720px frame will become a 1920x1080px frame with a scale factor of `1.5`. Vector elements like fonts and HTML markups will be rendered with extra details.
+Scales the output dimensions by a factor. See [Scaling](/docs/scaling) to learn more about this feature.
### `quality?`
diff --git a/packages/docs/docs/scaling.md b/packages/docs/docs/scaling.md
index 580ec389e7..ab841f403f 100644
--- a/packages/docs/docs/scaling.md
+++ b/packages/docs/docs/scaling.md
@@ -31,7 +31,9 @@ The highest scale possible is `16` (sixteen times higher dimensions on each size
Positive values below 1 are allowed. For example, `0.5` will half each dimension.
-The scale must result in a value that will result in even pixels. A value of `1.00000001` for a composition with a width of `1920` pixels is not allowed.
+The scale must result in a value that will result in integer pixels. A value of `1.00000001` for a composition with a width of `1920` pixels is not allowed.
+
+For MP4 videos, the scale must resolve in a value where both dimensions are divisible by 2, since the codec does not support odd numbers.
If you would like to downscale a composition from `1920` to `1280` pixels, pass a scale of `2/3` to avoid rounding errors. This does not currently work as a CLI flag.