このページでは

QCameraFormat Class

QCameraFormat クラスは、カメラデバイスがサポートする動画フォーマットを定義します。詳細...

ヘッダー: #include <QCameraFormat>
CMake: find_package(Qt6 REQUIRED COMPONENTS Multimedia)
target_link_libraries(mytarget PRIVATE Qt6::Multimedia)
qmake: QT += multimedia
QML内では: cameraFormat

プロパティ

公開関数

QCameraFormat()
QCameraFormat(const QCameraFormat &other)
~QCameraFormat()
bool isNull() const
float maxFrameRate() const
float minFrameRate() const
QVideoFrameFormat::PixelFormat pixelFormat() const
QSize resolution() const
bool operator!=(const QCameraFormat &other) const
QCameraFormat &operator=(const QCameraFormat &other)
bool operator==(const QCameraFormat &other) const

詳細な説明

QCameraFormat は、カメラデバイスがサポートする特定のビデオフォーマットを表します。

このフォーマットは、pixel format 、解像度、およびフレームレートの範囲の組み合わせで構成されます。

QCameraFormat オブジェクトは、QCameraDevice から照会して、サポートされているビデオフォーマットのセットを確認することができます。

「 QCameraDevice 」および「QCamera 」も参照してください 。

プロパティのドキュメント

[read-only] maxFrameRate : const float

このフォーマットで定義されている最高のフレームレートを返します。

カメラは、特定のビデオフォーマットでサポートされているフレームレートのうち、常に最高のものを使用しようとします。

アクセス関数:

float maxFrameRate() const

[read-only] minFrameRate : const float

このフォーマットで定義されている最低フレームレートを返します。

アクセス関数:

float minFrameRate() const

[read-only] pixelFormat : const QVideoFrameFormat::PixelFormat

ピクセル形式を返します。

通常、これはQVideoFrameFormat::Format_Jpeg またはQVideoFrameFormat::Format_YUVYのいずれかですが、カメラによっては他のフォーマットもサポートされている場合があります。

アクセス関数:

QVideoFrameFormat::PixelFormat pixelFormat() const

QVideoFrameFormat::PixelFormatも参照してください 。

[read-only] resolution : const QSize

解像度を返します。

関数へのアクセス:

QSize resolution() const

メンバ関数のドキュメント

[noexcept] QCameraFormat::QCameraFormat()

nullカメラフォーマットを構築します。

isNull()も参照してください 。

[noexcept] QCameraFormat::QCameraFormat(const QCameraFormat &other)

Copyは、other 形式からカメラ形式を生成します。

[noexcept] QCameraFormat::~QCameraFormat()

カメラフォーマットオブジェクトを破棄します。

[noexcept] bool QCameraFormat::isNull() const

これがデフォルト構築されたQCameraFormat である場合、trueを返します。

bool QCameraFormat::operator!=(const QCameraFormat &other) const

other のフォーマットがこのカメラのフォーマットと一致する場合はfalse を返し、一致しない場合はtrue を返します。

[noexcept] QCameraFormat &QCameraFormat::operator=(const QCameraFormat &other)

これをother に割り当ててください。

bool QCameraFormat::operator==(const QCameraFormat &other) const

other のフォーマットがこのカメラのフォーマットと一致する場合はtrue を返し、一致しない場合はfalse を返します。

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.