KasmVNC/common/rfb/encoders/KasmVideoConstants.h

37 lines
1.4 KiB
C++

/* Copyright (C) 2025 Kasm. All Rights Reserved.
*
* This is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This software is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this software; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
* USA.
*/
#pragma once
#include <array>
#include <cassert>
namespace rfb {
static constexpr unsigned int SupportedEncoderCount = 3;
// Compression control
static constexpr unsigned int kasmVideoH264 = 0x01 << 4; // H.264 encoding
static constexpr unsigned int kasmVideoH265 = 0x02 << 4; // H.265 encoding
static constexpr unsigned int kasmVideoAV1 = 0x03 << 4; // AV1 encoding
static constexpr unsigned int kasmVideoSkip = 0x00 << 4; // Skip frame
static constexpr auto drm_device_paths = std::to_array<const char *>({
"/dev/dri/renderD128",
"/dev/dri/card0",
"/dev/dri/renderD129",
"/dev/dri/card1"
});
} // namespace rfb