<?php

declare(strict_types=1);

namespace App\Enum;

enum DeviceModel: string
{
    case V1 = 'v1'; // Waveshare 7.3" 800×480

    public function width(Orientation $orientation): int
    {
        return $orientation === Orientation::Portrait ? 480 : 800;
    }

    public function height(Orientation $orientation): int
    {
        return $orientation === Orientation::Portrait ? 800 : 480;
    }

    /** EPD's hardware scan-row width — independent of user orientation. */
    public function nativeWidth(): int
    {
        return 800;
    }

    /** EPD's hardware scan-row count — independent of user orientation. */
    public function nativeHeight(): int
    {
        return 480;
    }
}
