// This Source Code Form is subject to the terms of the Mozilla Public
// License, v2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/
export const glColor = (r, g, b, a) => ({
    r: r / 255, g: g / 255, b: b / 255, a
});
export const DEFAULT_WIDTH = 1920;
export const DEFAULT_HEIGHT = 1080;
function interpolate(width, height, base) {
    const widthScale = width / DEFAULT_WIDTH;
    const heightScale = height / DEFAULT_HEIGHT;
    const scale = (widthScale + heightScale) / 2;
    return base * scale;
}
export const DEFAULT_SIZE = 42;
export const DEFAULT_THICKNESS = 10;
export const getTextSize = (width, height) => interpolate(width, height, DEFAULT_SIZE);
export const getBorderThickness = (width, height) => interpolate(width, height, DEFAULT_THICKNESS);
//# sourceMappingURL=utils.js.map