Viadeo Twitter Google Bookmarks ! Facebook Digg del.icio.us MySpace Yahoo MyWeb Blinklist Netvouz Reddit Simpy StumbleUpon Bookmarks Windows Live Favorites 
Logo Documentation Qt ·  Page d'accueil  ·  Toutes les classes  ·  Classes principales  ·  Annotées  ·  Classes groupées  ·  Modules  ·  Fonctions  · 

CameraRecorder

The CameraRecorder type controls video recording with the Camera. More...

Inherits QtObject

Properties

Methods

Detailed Description

CameraRecorder allows recording camera streams to files, and adjusting recording settings and metadata for videos.

It should not be constructed separately, instead the videRecorder property of a Camera should be used.

 Camera {
     videoRecorder.audioEncodingMode: CameraRecorder.ConstantBitrateEncoding;
     videoRecorder.audioBitRate: 128000
     videoRecorder.mediaContainer: "mp4"
     // ...
 }

There are many different settings for each part of the recording process (audio, video, and output formats), as well as control over muting and where to store the output file.

See also QAudioEncoderSettings and QVideoEncoderSettings.

Property Documentation

audioBitRate : int

The audio bit rate to use when recording video, in bits per second.


audioChannels : int

The number of audio channels to encode when recording video (1 is mono, 2 is stereo).


audioCodec : string

The audio codec to use for recording video. Typically this is something like aac or amr-wb.

See also whileBalanceMode.


audioEncodingMode : enumeration

The type of encoding method to use when recording audio.

ValueDescription
ConstantQualityEncodingEncoding will aim to have a constant quality, adjusting bitrate to fit. This is the default. The bitrate setting will be ignored.
ConstantBitRateEncodingEncoding will use a constant bit rate, adjust quality to fit. This is appropriate if you are trying to optimize for space.
AverageBitRateEncodingEncoding will try to keep an average bitrate setting, but will use more or less as needed.

audioSampleRate : int

The audio sample rate to encode audio at, when recording video.


captureResolution : size

The video frame dimensions to use when capturing video.


read-onlyerrorCode : enumeration

The current error code, if any.

ValueDescription
NoErrorNo Errors
ResourceErrorDevice is not ready or not available.
FormatErrorCurrent format is not supported.
OutOfSpaceErrorNo space left on device.

frameRate : qreal

The video framerate to use when recording video, in frames per second.


mediaContainer : string

The media container to use for recording video. Typically this is something like mp4.


recorderState : enumeration

The current state of the camera recorder object.

ValueDescription
StoppedStateThe camera is not recording video.
RecordingStateThe camera is recording video.

read-onlyrecorderStatus : enumeration

The actual current status of media recording.

ValueDescription
UnavailableStatusRecording is not supported by the camera.
UnloadedStatusThe recorder is available but not loaded.
LoadingStatusThe recorder is initializing.
LoadedStatusThe recorder is initialized and ready to record media.
StartingStatusRecording is requested but not active yet.
RecordingStatusRecording is active.
PausedStatusRecording is paused.
FinalizingStatusRecording is stopped with media being finalized.

videoBitRate : int

The video bit rate to use when recording video, in bits per second.


videoCodec : string

The video codec to use for recording video. Typically this is something like h264.


videoEncodingMode : enumeration

The type of encoding method to use when recording video.

ValueDescription
ConstantQualityEncodingEncoding will aim to have a constant quality, adjusting bitrate to fit. This is the default. The bitrate setting will be ignored.
ConstantBitRateEncodingEncoding will use a constant bit rate, adjust quality to fit. This is appropriate if you are trying to optimize for space.
AverageBitRateEncodingEncoding will try to keep an average bitrate setting, but will use more or less as needed.

Method Documentation

CameraRecorder::record()

Starts recording.


CameraRecorder::setMetadata(key, value)

Sets metadata for the next video to be recorder, with the given key being associated with value.


CameraRecorder::stop()

Stops recording.


Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. Qt 5.0-snapshot
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD.
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP !
 
 
 
 
Partenaires

Hébergement Web