# Dynamic Scaling

<details>

<summary>Explanation</summary>

Your players will most likely have different screen sizes (their devices, from mobile to monitors etc.) which means that moving a letter of "50 pixels" might seem too much or too low, while as a designer you'll want an uniform experience/result for everyone, exactly as you intended. This is why we strongly advise to keep "Use Dynamic Scaling" enabled, and edit values based on your current computer font size (so whatever changes later, it'll keep the same uniform ratio).

</details>

{% hint style="danger" %}
In Godot (up to version 4.1.1 included), TextAnimator does not, by default, produce uniform effect results across different screen resolutions (see [Documentation](https://docs.godotengine.org/en/stable/tutorials/rendering/multiple_resolutions.html)). To address this, you have two option:
{% endhint %}

## Use a font scaler with Dynamic Scaling

{% hint style="info" %}
*This is suggested mainly for **3D Scenes**.*

if you need to adapt to (almost) every screen resolutions, you may want to use our `Font Scaler Node` in combination with TextAnimator's `Dynamic Scaling`.
{% endhint %}

<figure><img src="/files/4tcstcpwmhOLqqOfgpgV" alt=""><figcaption></figcaption></figure>

{% hint style="danger" %}
2D Scenes are not automatically scaled to fit the scree like the 3D camera viewport. \
The solution is [#using-canvas-item-stretch-mode](#using-canvas-item-stretch-mode "mention").
{% endhint %}

* `Reference Font Size`: represents the size where objects behave as expected. As a reference, you can pick the font size in your Godot editor while you’re testing things.

<figure><img src="/files/2jks95nFPUCWYr8kQh0Y" alt="" width="464"><figcaption></figcaption></figure>

## Using Canvas Item Stretch Mode

{% hint style="info" %}
*This is suggested mainly for **2D Scenes**.*&#x20;
{% endhint %}

{% hint style="danger" %}
3D Scenes are uneffectd by Canvas Item Strech Mode (see [Documentation](https://docs.godotengine.org/en/stable/tutorials/rendering/multiple_resolutions.html#:~:text=Stretch%20Mode%20%3D%20Canvas,in%20scaling%20artifacts.)). [#use-a-font-scaler-with-dynamic-scaling](#use-a-font-scaler-with-dynamic-scaling "mention").
{% endhint %}

You can force a consistent pixel scale by changing the viewport mode:

* How to enable: Navigate to `Project Settings -> Display -> Window` and set `Stretch mode = Canvas Item`.
* Effect: This maintains your project's base resolution (e.g. `300x200`) and stretches it to fit the screen. This method may create **black bars** on the sides of the screen if the monitor's aspect ratio is different from your base resolution.

{% hint style="info" %}
Why not using Viewport Stretch Mode?

Although viewport stretch mode resizes the image after the viewport has been drawn on the screen (even for 3D scenes), it can generate aliasing and sub-pixel artifacts.
{% endhint %}

{% columns %}
{% column %}

<figure><img src="/files/Rp2BbvTqILV2G8uvYMo7" alt="" width="359"><figcaption><p>Base resolution of 300x200</p></figcaption></figure>
{% endcolumn %}

{% column %}

<figure><img src="/files/Manm3YFsxmsLc2Rl03Pf" alt="" width="365"><figcaption><p>Base resolution of 300x200</p></figcaption></figure>
{% endcolumn %}
{% endcolumns %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.febucci.com/text-animator-godot/effects/edit-effects/dynamic-scaling.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
