Minor doc fixes for QML
renaming QML element to QML type removing some \fn tags that were making the docs not build some rewording some new signal docs Change-Id: I9b350dad1780276959aef4105e53b91082a6083e Reviewed-by: Dmytro Poplavskiy <dmytro.poplavskiy@nokia.com>
This commit is contained in:
committed by
Qt by Nokia
parent
fdb5c419c4
commit
9e6d03584a
@@ -39,10 +39,10 @@ QtAudioEngine enables developers to organize wave files into discrete \l Sound w
|
|||||||
\l {PlayVariation}{play variations}, group sound controls by \l {AudioCategory} categories and
|
\l {PlayVariation}{play variations}, group sound controls by \l {AudioCategory} categories and
|
||||||
define \l {AttenuationModelLinear}{attenuation models} and various 3d audio settings all in one
|
define \l {AttenuationModelLinear}{attenuation models} and various 3d audio settings all in one
|
||||||
place. Playback of \l {SoundInstance}{sound instances} can be conveniently activated by in-app
|
place. Playback of \l {SoundInstance}{sound instances} can be conveniently activated by in-app
|
||||||
events and managed by QtAudioEngine or controlled by explicitly defining a \l SoundInstance elment
|
events and managed by QtAudioEngine or controlled by explicitly defining \l SoundInstance
|
||||||
for easier qml bindings.
|
for easier QML bindings.
|
||||||
|
|
||||||
QtAudioEngine elements can be accessed through importing the
|
To access these QML types import the
|
||||||
\b{QtAudioEngine 1.0} module.
|
\b{QtAudioEngine 1.0} module.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
@@ -61,7 +61,7 @@ AudioEngine {
|
|||||||
|
|
||||||
\section1 Reference Documentation
|
\section1 Reference Documentation
|
||||||
|
|
||||||
\section2 QML Elements
|
\section2 QML Types
|
||||||
|
|
||||||
\list
|
\list
|
||||||
\li \l AudioEngine
|
\li \l AudioEngine
|
||||||
|
|||||||
@@ -68,10 +68,10 @@ code but more buffering, which may affect latency.
|
|||||||
\section2 Low latency sound effects
|
\section2 Low latency sound effects
|
||||||
|
|
||||||
In addition to the raw access to sound devices described above, the QSoundEffect class (and
|
In addition to the raw access to sound devices described above, the QSoundEffect class (and
|
||||||
\l {SoundEffect} QML element) offers a slightly higher level way to play
|
\l {SoundEffect} QML type) offers a slightly higher level way to play
|
||||||
sounds. These classes allow you to specify a WAV format file which can
|
sounds. These classes allow you to specify a WAV format file which can
|
||||||
then be played with low latency when necessary. Both QSoundEffect and the
|
then be played with low latency when necessary. Both QSoundEffect and
|
||||||
SoundEffect element have essentially the same API.
|
SoundEffect have essentially the same API.
|
||||||
|
|
||||||
You can adjust the number of \l {QSoundEffect::loops}{loops} a sound effect is played, as well as
|
You can adjust the number of \l {QSoundEffect::loops}{loops} a sound effect is played, as well as
|
||||||
the \l {QSoundEffect::setVolume()}{volume} (or \l {QSoundEffect::setMuted()}{muting}) of the effect.
|
the \l {QSoundEffect::setVolume()}{volume} (or \l {QSoundEffect::setMuted()}{muting}) of the effect.
|
||||||
@@ -81,8 +81,8 @@ are recommended to use QSoundEffect where possible.
|
|||||||
|
|
||||||
\section2 Playing compressed audio
|
\section2 Playing compressed audio
|
||||||
For playing media or audio files that are not simple, raw audio, you can
|
For playing media or audio files that are not simple, raw audio, you can
|
||||||
use the \l QMediaPlayer C++ class, or the \l {Audio} and \l {MediaPlayer} QML elements.
|
use the \l QMediaPlayer C++ class, or the \l {Audio} and \l {MediaPlayer} QML types.
|
||||||
The QMediaPlayer class (and MediaPlayer element) is also capable of playing
|
The QMediaPlayer class and associated QML types are also capable of playing
|
||||||
\l{multimedia-playing-video}{video}, if required. The compressed audio formats supported does depend
|
\l{multimedia-playing-video}{video}, if required. The compressed audio formats supported does depend
|
||||||
on the operating system environment, and also what media plugins the user
|
on the operating system environment, and also what media plugins the user
|
||||||
may have installed.
|
may have installed.
|
||||||
@@ -146,7 +146,7 @@ There are both C++ and QML examples available.
|
|||||||
|
|
||||||
\annotatedlist multimedia_audio
|
\annotatedlist multimedia_audio
|
||||||
|
|
||||||
\section2 QML Elements
|
\section2 QML Types
|
||||||
|
|
||||||
\annotatedlist multimedia_audio_qml
|
\annotatedlist multimedia_audio_qml
|
||||||
|
|
||||||
|
|||||||
@@ -104,7 +104,7 @@ a photo or video, and then switch to a slower but higher resolution
|
|||||||
mode for capturing the image.
|
mode for capturing the image.
|
||||||
|
|
||||||
Depending on whether you're using QML or C++, you can do this in multiple ways.
|
Depending on whether you're using QML or C++, you can do this in multiple ways.
|
||||||
In QML, you can use the Camera and VideoOutput elements together to show a
|
In QML, you can use \l Camera and \l VideoOutput together to show a
|
||||||
simple viewfinder:
|
simple viewfinder:
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
@@ -210,7 +210,7 @@ and then use this point so that the image exposure is best at that point.
|
|||||||
|
|
||||||
Finally, you can control the flash hardware (if present) using this class. In some cases
|
Finally, you can control the flash hardware (if present) using this class. In some cases
|
||||||
the hardware may also double as a torch (typically when the flash is LED based, rather than
|
the hardware may also double as a torch (typically when the flash is LED based, rather than
|
||||||
a xenon or other bulb). See also the \l {Torch} QML element for an easy to use API for
|
a xenon or other bulb). See also \l {Torch} for an easy to use API for
|
||||||
torch functionality.
|
torch functionality.
|
||||||
|
|
||||||
\target camera_image_processing
|
\target camera_image_processing
|
||||||
@@ -255,7 +255,7 @@ There are both C++ and QML examples available.
|
|||||||
|
|
||||||
\annotatedlist multimedia_camera
|
\annotatedlist multimedia_camera
|
||||||
|
|
||||||
\section2 QML Elements
|
\section2 QML Types
|
||||||
|
|
||||||
\annotatedlist camera_qml
|
\annotatedlist camera_qml
|
||||||
|
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ There are a number of new features in Qt Multimedia 5.0:
|
|||||||
\li QML \l Torch class
|
\li QML \l Torch class
|
||||||
\li QSound moved from QtGui to QtMultimedia
|
\li QSound moved from QtGui to QtMultimedia
|
||||||
\li QSoundEffect available to C++ now, as well as QML
|
\li QSoundEffect available to C++ now, as well as QML
|
||||||
\li FM Radio Data System classes and elements now available (\l QRadioData, \l RadioData)
|
\li FM Radio Data System classes and types now available (\l QRadioData, \l RadioData)
|
||||||
\li Various other API improvements and bugfixes
|
\li Various other API improvements and bugfixes
|
||||||
\endlist
|
\endlist
|
||||||
|
|
||||||
@@ -133,14 +133,14 @@ they are documented elsewhere.
|
|||||||
QVariants. If you've previously added Q_DECLARE_METATYPE macros for any
|
QVariants. If you've previously added Q_DECLARE_METATYPE macros for any
|
||||||
Qt Multimedia class you will probably need to remove them.
|
Qt Multimedia class you will probably need to remove them.
|
||||||
\row
|
\row
|
||||||
\li Video QML element
|
\li Video QML type
|
||||||
\li If you've previously used the Video QML element you may be excited
|
\li If you've previously used \l Video you may be excited
|
||||||
to learn that it should still work as expected, but you also have
|
to learn that it should still work as expected, but you also have
|
||||||
the choice of using the new MediaPlayer and VideoOutput elements
|
the choice of using \l MediaPlayer and \l VideoOutput
|
||||||
together for more flexible and advanced use cases.
|
together for more flexible and advanced use cases.
|
||||||
\row
|
\row
|
||||||
\li QSoundEffect
|
\li QSoundEffect
|
||||||
\li The SoundEffect QML element was public and accessible in Qt Multimeda Kit,
|
\li The SoundEffect QML type was public and accessible in Qt Multimeda Kit,
|
||||||
and now the C++ version is also available. If you managed to use the
|
and now the C++ version is also available. If you managed to use the
|
||||||
private class previously, you'll need to update your code.
|
private class previously, you'll need to update your code.
|
||||||
\row
|
\row
|
||||||
|
|||||||
@@ -35,24 +35,24 @@ or video.
|
|||||||
|
|
||||||
\image qml-camera.png
|
\image qml-camera.png
|
||||||
|
|
||||||
This example demonstrates the basic use of the Camera QML Plugin elements. The
|
This example demonstrates the basic use of the Camera QML Plugin types. The
|
||||||
plugin provides access to the API functionality for camera settings and
|
plugin provides access to the API functionality for camera settings and
|
||||||
capturing an image.
|
capturing an image.
|
||||||
|
|
||||||
Most of the QML code supports the user interface for this application with the
|
Most of the QML code supports the user interface for this application with the
|
||||||
Camera elements being mostly found in \e {declarative-camera.qml} and
|
camera types being mostly found in \e {declarative-camera.qml} and
|
||||||
\e {CaptureControls.qml}.
|
\e {CaptureControls.qml}.
|
||||||
|
|
||||||
In \e {declarative-camera.qml} the Camera element is initialized with an id
|
In \e {declarative-camera.qml} the \l Camera is initialized with an id
|
||||||
of \e {camera}, a photo preview is setup, states are implemented for image
|
of \e {camera}, a photo preview is setup, states are implemented for image
|
||||||
preview or capture and a CaptureControls element is initialized. The initial
|
preview or capture and \l CaptureControls is initialized. The initial
|
||||||
\e state is \e PhotoCapture. The camera element includes a handler, \e onImageCaptured,
|
\e state is \e PhotoCapture. \l CameraCapture includes a handler, \e onImageCaptured,
|
||||||
for the \l {imageCaptured} signal. The handler sets up the application to process
|
for the \l {imageCaptured} signal. The handler sets up the application to process
|
||||||
the preview including a change in the user interface state. The PhotoPreview
|
the preview including a change in the user interface state. The \l PhotoPreview
|
||||||
element now becomes visible with any key press being picked up by the handler
|
becomes visible with any key press being picked up by the handler
|
||||||
in PhotoPreview and returning the state to \e PhotoCapture.
|
in PhotoPreview and returning the state to \e PhotoCapture.
|
||||||
|
|
||||||
The \e CaptureControls element, which is implemented in \e {CaptureControls.qml},
|
\e CaptureControls, which is implemented in \e {CaptureControls.qml},
|
||||||
generates a column on the right hand side of the screen which includes control
|
generates a column on the right hand side of the screen which includes control
|
||||||
buttons for \e focus (not initially visible), \e {capture}, \e {flash modes},
|
buttons for \e focus (not initially visible), \e {capture}, \e {flash modes},
|
||||||
\e {white balance}, \e {exposure compensation}, and if a preview is
|
\e {white balance}, \e {exposure compensation}, and if a preview is
|
||||||
|
|||||||
@@ -53,10 +53,10 @@ which moves across the \l{VideoOutput} item.
|
|||||||
\section1 Application structure
|
\section1 Application structure
|
||||||
|
|
||||||
The \l{video/qmlvideo/qml/qmlvideo/main.qml} file creates a UI which includes
|
The \l{video/qmlvideo/qml/qmlvideo/main.qml} file creates a UI which includes
|
||||||
the following elements:
|
the following items:
|
||||||
|
|
||||||
\list
|
\list
|
||||||
\li Two \l{video/qmlvideo/qml/qmlvideo/Button.qml}{Button} elements, each
|
\li Two \l{video/qmlvideo/qml/qmlvideo/Button.qml}{Button} instances, each
|
||||||
of which displays a filename, and can be used to launch a
|
of which displays a filename, and can be used to launch a
|
||||||
\l{video/qmlvideo/qml/qmlvideo/FileBrowser.qml}{FileBrowser}
|
\l{video/qmlvideo/qml/qmlvideo/FileBrowser.qml}{FileBrowser}
|
||||||
\li An exit \l{video/qmlvideo/qml/qmlvideo/Button.qml}{Button}
|
\li An exit \l{video/qmlvideo/qml/qmlvideo/Button.qml}{Button}
|
||||||
@@ -70,11 +70,11 @@ the following elements:
|
|||||||
\image qmlvideo-menu.png
|
\image qmlvideo-menu.png
|
||||||
|
|
||||||
Each scene in the flickable list is implemented in its own QML file - for
|
Each scene in the flickable list is implemented in its own QML file - for
|
||||||
example the video-basic scene (which just displays a static \l{VideoOutput} element
|
example the video-basic scene (which just displays a static \l{VideoOutput}
|
||||||
in the center of the screen) is implemented in the
|
in the center of the screen) is implemented in the
|
||||||
\l{video/qmlvideo/qml/qmlvideo/VideoBasic.qml}{VideoBasic.qml} file. As you
|
\l{video/qmlvideo/qml/qmlvideo/VideoBasic.qml}{VideoBasic.qml} file. As you
|
||||||
can see from the code, this makes use of a type of inheritance: a
|
can see from the code, this makes use of a type of inheritance: a
|
||||||
\l{video/qmlvideo/qml/qmlvideo/VideoBasic.qml}{VideoBasic} element ...
|
\l{video/qmlvideo/qml/qmlvideo/VideoBasic.qml}{VideoBasic} item ...
|
||||||
|
|
||||||
\quotefromfile video/qmlvideo/qml/qmlvideo/VideoBasic.qml
|
\quotefromfile video/qmlvideo/qml/qmlvideo/VideoBasic.qml
|
||||||
\skipto import
|
\skipto import
|
||||||
@@ -108,8 +108,8 @@ can see from the code, this makes use of a type of inheritance: a
|
|||||||
|
|
||||||
\l{video/qmlvideo/qml/qmlvideo/SceneBasic.qml}{SceneBasic} describes the
|
\l{video/qmlvideo/qml/qmlvideo/SceneBasic.qml}{SceneBasic} describes the
|
||||||
structure and behaviour of the scene, but is agnostic of the type of content
|
structure and behaviour of the scene, but is agnostic of the type of content
|
||||||
which will be displayed - this is abstracted by the
|
which will be displayed - this is abstracted by
|
||||||
\l{video/qmlvideo/qml/qmlvideo/Content.qml}{Content} element.
|
\l{video/qmlvideo/qml/qmlvideo/Content.qml}{Content}.
|
||||||
|
|
||||||
This pattern allows us to define a particular use case (in this case, simply
|
This pattern allows us to define a particular use case (in this case, simply
|
||||||
display a static piece of content), and then instantiate that use case for
|
display a static piece of content), and then instantiate that use case for
|
||||||
@@ -123,7 +123,7 @@ the content from left to right and back again" is implemented by
|
|||||||
\l{video/qmlvideo/qml/qmlvideo/CameraMove.qml}{CameraMove} are based.
|
\l{video/qmlvideo/qml/qmlvideo/CameraMove.qml}{CameraMove} are based.
|
||||||
|
|
||||||
Depending on the value of the contentType property in the top-level scene
|
Depending on the value of the contentType property in the top-level scene
|
||||||
element, the embedded
|
instance, the embedded
|
||||||
\l{video/qmlvideo/qml/qmlvideo/Content.qml}{Content} item creates either a
|
\l{video/qmlvideo/qml/qmlvideo/Content.qml}{Content} item creates either a
|
||||||
\l{MediaPlayer} or a \l{Camera} item.
|
\l{MediaPlayer} or a \l{Camera} item.
|
||||||
|
|
||||||
|
|||||||
@@ -31,13 +31,13 @@
|
|||||||
\ingroup video_examples_qml
|
\ingroup video_examples_qml
|
||||||
\ingroup camera_examples_qml
|
\ingroup camera_examples_qml
|
||||||
|
|
||||||
\brief The QML Video Shader Effects Example shows how the \l {ShaderEffect}
|
\brief The QML Video Shader Effects Example shows how \l {ShaderEffect}
|
||||||
element can be used to apply postprocessing effects, expressed in \c GLSL, to video
|
can be used to apply postprocessing effects, expressed in \c GLSL, to video
|
||||||
and camera viewfinder content.
|
and camera viewfinder content.
|
||||||
|
|
||||||
\section1 Overview
|
\section1 Overview
|
||||||
|
|
||||||
This example shows how the \l {ShaderEffectItem} element can be used to apply
|
This example shows how a \l {ShaderEffectItem} can be used to apply
|
||||||
postprocessing effects, expressed in GLSL, to QML \l {VideoOutput} items.
|
postprocessing effects, expressed in GLSL, to QML \l {VideoOutput} items.
|
||||||
|
|
||||||
It also shows how native code can be combined with QML to implement more
|
It also shows how native code can be combined with QML to implement more
|
||||||
@@ -73,8 +73,8 @@ for Effect*.qml files in the list above to see the full range.
|
|||||||
|
|
||||||
\section1 Application structure
|
\section1 Application structure
|
||||||
|
|
||||||
Shader effects can be applied to video or viewfinder content using the
|
Shader effects can be applied to video or viewfinder content using
|
||||||
\l{ShaderEffectItem} element, as shown in the following example, which applies
|
\l{ShaderEffectItem}, as shown in the following example, which applies
|
||||||
a wiggly effect to the content:
|
a wiggly effect to the content:
|
||||||
|
|
||||||
\code
|
\code
|
||||||
@@ -119,7 +119,7 @@ Rectangle {
|
|||||||
\endcode
|
\endcode
|
||||||
|
|
||||||
In this application, the usage of the \l{ShaderEffect} and \l{VideoOutput}
|
In this application, the usage of the \l{ShaderEffect} and \l{VideoOutput}
|
||||||
elements is a bit more complicated, for the following reasons:
|
types is a bit more complicated, for the following reasons:
|
||||||
|
|
||||||
\list
|
\list
|
||||||
\li Each effect can be applied to either a \l{VideoOutput} or an
|
\li Each effect can be applied to either a \l{VideoOutput} or an
|
||||||
@@ -135,8 +135,8 @@ elements is a bit more complicated, for the following reasons:
|
|||||||
\endlist
|
\endlist
|
||||||
|
|
||||||
The abstraction of source item type is achieved by the
|
The abstraction of source item type is achieved by the
|
||||||
\l{video/qmlvideofx/qml/qmlvideofx/Content.qml}{Content} element, which uses a
|
\l{video/qmlvideofx/qml/qmlvideofx/Content.qml}{Content}, which uses a
|
||||||
\l{Loader} to create either a \l{MediaPlayer}, \l{Camera} or \l{Image} element:
|
\l{Loader} to create either a \l{MediaPlayer}, \l{Camera} or \l{Image}:
|
||||||
|
|
||||||
\quotefromfile video/qmlvideofx/qml/qmlvideofx/Content.qml
|
\quotefromfile video/qmlvideofx/qml/qmlvideofx/Content.qml
|
||||||
\skipto import
|
\skipto import
|
||||||
@@ -165,14 +165,14 @@ The abstraction of source item type is achieved by the
|
|||||||
\printuntil }
|
\printuntil }
|
||||||
|
|
||||||
Each effect is implemented as a QML item which is based on the
|
Each effect is implemented as a QML item which is based on the
|
||||||
\l{video/qmlvideofx/qml/qmlvideofx/Effect.qml}{Effect} element, which in turn
|
\l{video/qmlvideofx/qml/qmlvideofx/Effect.qml}{Effect}, which in turn
|
||||||
is based on the \l{ShaderEffect} element:
|
is based on the \l{ShaderEffect}:
|
||||||
|
|
||||||
\quotefromfile video/qmlvideofx/qml/qmlvideofx/Effect.qml
|
\quotefromfile video/qmlvideofx/qml/qmlvideofx/Effect.qml
|
||||||
\skipto import
|
\skipto import
|
||||||
\printuntil /^\}/
|
\printuntil /^\}/
|
||||||
|
|
||||||
The interface of the Effect element allows for derived effects to specify the
|
The interface of the \l Effect allows for derived effects to specify the
|
||||||
number of parameters which they support (and therefore the number of sliders
|
number of parameters which they support (and therefore the number of sliders
|
||||||
which should be displayed), and whether a vertical dividing line should be drawn
|
which should be displayed), and whether a vertical dividing line should be drawn
|
||||||
between transformed and untransformed image regions. As an example, here is the
|
between transformed and untransformed image regions. As an example, here is the
|
||||||
@@ -185,12 +185,12 @@ that the divider should be displayed.
|
|||||||
\printuntil /^\}/
|
\printuntil /^\}/
|
||||||
|
|
||||||
The main.qml file shows a
|
The main.qml file shows a
|
||||||
\l{video/qmlvideofx/qml/qmlvideofx/FileOpen.qml}{FileOpen} element which allows
|
\l{video/qmlvideofx/qml/qmlvideofx/FileOpen.qml}{FileOpen}, which allows
|
||||||
the user to select the input source and an
|
the user to select the input source and an
|
||||||
\l{video/qmlvideofx/qml/qmlvideofx/EffectSelectionPanel.qml}{EffectSelectionPanel}
|
\l{video/qmlvideofx/qml/qmlvideofx/EffectSelectionPanel.qml}{EffectSelectionPanel}
|
||||||
item, which lists each of the available shader effects. As described above, a
|
item, which lists each of the available shader effects. As described above, a
|
||||||
\l{video/qmlvideofx/qml/qmlvideofx/Content.qml}{Content} item is used to load the
|
\l{video/qmlvideofx/qml/qmlvideofx/Content.qml}{Content} item is used to load the
|
||||||
appropriate input and effect element. A
|
appropriate input and effect type. A
|
||||||
\l{video/qmlvideofx/qml/qmlvideofx/Divider.qml}{Divider} item draws the
|
\l{video/qmlvideofx/qml/qmlvideofx/Divider.qml}{Divider} item draws the
|
||||||
vertical dividing line, which can be dragged left / right by the user. Finally,
|
vertical dividing line, which can be dragged left / right by the user. Finally,
|
||||||
a \l{video/qmlvideofx/qml/qmlvideofx/ParameterPanel.qml}{ParameterPanel} item
|
a \l{video/qmlvideofx/qml/qmlvideofx/ParameterPanel.qml}{ParameterPanel} item
|
||||||
|
|||||||
@@ -164,13 +164,13 @@ change when porting code.
|
|||||||
|
|
||||||
\section1 Reference Documentation
|
\section1 Reference Documentation
|
||||||
|
|
||||||
\section2 QML Elements
|
\section2 QML Types
|
||||||
The following elements are accessed by using:
|
The following types are accessed by using:
|
||||||
\qml
|
\qml
|
||||||
import QtMultimedia 5.0
|
import QtMultimedia 5.0
|
||||||
\endqml
|
\endqml
|
||||||
\annotatedlist multimedia_qml
|
\annotatedlist multimedia_qml
|
||||||
The following elements are accessed by using \l {Positional Audio} {QtAudioEngine}:
|
The following types are accessed by using \l {Positional Audio} {QtAudioEngine}:
|
||||||
\qml
|
\qml
|
||||||
import QtAudioEngine 1.0
|
import QtAudioEngine 1.0
|
||||||
\endqml
|
\endqml
|
||||||
|
|||||||
@@ -43,14 +43,14 @@
|
|||||||
|
|
||||||
The Qt Multimedia API gives developers a simplified way to use audio and video playback, and access camera functionality. The Multimedia QML Plugin provides a QML friendly interface to these features.
|
The Qt Multimedia API gives developers a simplified way to use audio and video playback, and access camera functionality. The Multimedia QML Plugin provides a QML friendly interface to these features.
|
||||||
|
|
||||||
\section1 Elements
|
\section1 Types
|
||||||
|
|
||||||
\section2 Audio
|
\section2 Audio
|
||||||
|
|
||||||
The \l Audio element is an easy way to add audio playback to a Qt Quick
|
\l Audio is an easy way to add audio playback to a Qt Quick
|
||||||
scene. QtMultimedia provides properties for control, methods (functions) and signals.
|
scene. QtMultimedia provides properties for control, methods (functions) and signals.
|
||||||
|
|
||||||
The code extract below shows the creation and use of an audio element.
|
The code extract below shows the creation and use of an Audio instance.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
|
|
||||||
@@ -76,7 +76,7 @@
|
|||||||
|
|
||||||
\endqml
|
\endqml
|
||||||
|
|
||||||
The snippet above shows how the inclusion of \e playMusic enables audio features on the element that contains it. So that when the parent's MouseArea is clicked the \l {Audio::play()}{play()} method of the audio element is run. Other typical audio control methods are available such as \l {Audio::pause}{pause()} and \l {Audio::stop()}{stop()}.
|
The snippet above shows how the inclusion of \e playMusic enables audio features on the type that contains it. So that when the parent's MouseArea is clicked the \l {Audio::play()}{play()} method of Audio is run. Other typical audio control methods are available such as \l {Audio::pause}{pause()} and \l {Audio::stop()}{stop()}.
|
||||||
|
|
||||||
Much of the getting / setting of \l Audio parameters is done through properties. These include
|
Much of the getting / setting of \l Audio parameters is done through properties. These include
|
||||||
\table 70%
|
\table 70%
|
||||||
@@ -149,15 +149,15 @@
|
|||||||
|
|
||||||
\section2 Camera
|
\section2 Camera
|
||||||
|
|
||||||
The \l Camera element enables still image and video capture using
|
\l Camera enables still image and video capture using
|
||||||
QML. The element has a number of properties that help setting it up.
|
QML. It has a number of properties that help setting it up.
|
||||||
|
|
||||||
The details of using the Camera element are described in further details
|
The details of using a \l Camera are described in further depth
|
||||||
in the \l {Camera Overview} and in the corresponding reference documentation.
|
in the \l {Camera Overview} and in the corresponding reference documentation.
|
||||||
|
|
||||||
\section2 Video
|
\section2 Video
|
||||||
|
|
||||||
Adding video playback, with sound, to a Qt Quick scene is also easy. The process is very similar to that of Audio above, in fact \l {Video} shares many of the property names, methods and signals. Here is the equivalent sample code to implement a video playback element in a scene
|
Adding video playback, with sound, to a Qt Quick scene is also easy. The process is very similar to that of Audio above, in fact \l {Video} shares many of the property names, methods and signals. Here is the equivalent sample code to implement video playback in a scene
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
|
|
||||||
@@ -185,14 +185,14 @@
|
|||||||
There are similar features like \l {Video::play()}{play()} with new
|
There are similar features like \l {Video::play()}{play()} with new
|
||||||
features specific to video.
|
features specific to video.
|
||||||
|
|
||||||
In the above sample when the parent of MouseArea is clicked, an area of 800x600 pixels with an id of 'video', the source "video.avi" will play in that area. Notice also that signals for the Keys element have been defined so that a spacebar will toggle the pause button; the left arrow will move the current position in the video to 5 seconds previously; and the right arrow will advance the current position in the video by 5 seconds.
|
In the above sample when the parent of MouseArea is clicked, an area of 800x600 pixels with an id of 'video', the source "video.avi" will play in that area. Notice also that signals for the \l Keys have been defined so that a spacebar will toggle the pause button; the left arrow will move the current position in the video to 5 seconds previously; and the right arrow will advance the current position in the video by 5 seconds.
|
||||||
|
|
||||||
Most of the differences will obviously be about video control and information. There are many properties associated with the \l {Video} element, most of them deal with meta-data, control of the video media and aspects of presentation.
|
Most of the differences will obviously be about video control and information. There are many properties associated with \l {Video}, most of them deal with meta-data, control of the video media and aspects of presentation.
|
||||||
|
|
||||||
\section2 SoundEffect
|
\section2 SoundEffect
|
||||||
|
|
||||||
The \l SoundEffect element provides a way to play short sound effects, like in video games. Multiple sound effect instances can be played simultaneously.
|
\l SoundEffect provides a way to play short sound effects, like in video games. Multiple sound effect instances can be played simultaneously.
|
||||||
You should use the \l Audio element for music playback.
|
You should use \l Audio for music playback.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
|
|
||||||
@@ -219,9 +219,9 @@
|
|||||||
|
|
||||||
In the above sample the sound effect will be played when the MouseArea is clicked.
|
In the above sample the sound effect will be played when the MouseArea is clicked.
|
||||||
|
|
||||||
For a complete description of this element, see \l SoundEffect
|
For a complete description of this type, see \l SoundEffect
|
||||||
|
|
||||||
\section1 Multimedia QML Elements
|
\section1 Multimedia QML Types
|
||||||
|
|
||||||
\annotatedlist multimedia_qml
|
\annotatedlist multimedia_qml
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -28,13 +28,13 @@
|
|||||||
/*!
|
/*!
|
||||||
\qmlmodule QtMultimedia 5
|
\qmlmodule QtMultimedia 5
|
||||||
\title QML import for multimedia
|
\title QML import for multimedia
|
||||||
\brief The import for the QML elements in the Qt Multimedia module
|
\brief The import for the QML types in the Qt Multimedia module
|
||||||
|
|
||||||
\section1 Overview
|
\section1 Overview
|
||||||
|
|
||||||
The identifying string for this component is \e QtMultimedia. Use this in the QML \e import statement.
|
The identifying string for this component is \e QtMultimedia. Use this in the QML \e import statement.
|
||||||
|
|
||||||
\section1 QML Elements
|
\section1 QML types
|
||||||
|
|
||||||
\annotatedlist multimedia_qml
|
\annotatedlist multimedia_qml
|
||||||
|
|
||||||
|
|||||||
@@ -38,9 +38,9 @@ over the radio tuner of the system, and gives access to Radio Data System
|
|||||||
\section1 Radio Features
|
\section1 Radio Features
|
||||||
|
|
||||||
The Radio API consists of two separate components. The radio tuner,
|
The Radio API consists of two separate components. The radio tuner,
|
||||||
\l QRadioTuner or the \l Radio QML element, which handles control of
|
\l QRadioTuner or the \l Radio QML type, which handles control of
|
||||||
the radio hardware as well as tuning. The other is the radio data
|
the radio hardware as well as tuning. The other is the radio data
|
||||||
component, either \l QRadioData or the \l RadioData QML element, which
|
component, either \l QRadioData or the \l RadioData QML type, which
|
||||||
gives access to RDS information.
|
gives access to RDS information.
|
||||||
|
|
||||||
\section1 Radio Implementation Details
|
\section1 Radio Implementation Details
|
||||||
@@ -53,7 +53,7 @@ data component will only be populated if the system radio tuner supports RDS.
|
|||||||
|
|
||||||
There are two examples showing the usage of the Radio API. One shows how to use
|
There are two examples showing the usage of the Radio API. One shows how to use
|
||||||
the QRadioTuner class from C++. The other shows how to implement a similar
|
the QRadioTuner class from C++. The other shows how to implement a similar
|
||||||
application using QML and the Radio element.
|
application using QML and \l Radio.
|
||||||
|
|
||||||
\section2 Radio Example
|
\section2 Radio Example
|
||||||
|
|
||||||
@@ -82,7 +82,7 @@ current frequency inside the band.
|
|||||||
|
|
||||||
\annotatedlist multimedia_radio
|
\annotatedlist multimedia_radio
|
||||||
|
|
||||||
\section2 QML Elements
|
\section2 QML Types
|
||||||
|
|
||||||
\annotatedlist multimedia_radio_qml
|
\annotatedlist multimedia_radio_qml
|
||||||
|
|
||||||
|
|||||||
@@ -34,7 +34,7 @@
|
|||||||
\section1 Video Features
|
\section1 Video Features
|
||||||
|
|
||||||
Qt Multimedia offers both high and low level C++ classes for playing and
|
Qt Multimedia offers both high and low level C++ classes for playing and
|
||||||
manipulating video data, and QML elements for playback and control. Some
|
manipulating video data, and QML types for playback and control. Some
|
||||||
of these classes also overlap with both \l {Camera Overview}{camera} and
|
of these classes also overlap with both \l {Camera Overview}{camera} and
|
||||||
\l {Audio Overview}{audio} classes, which can be useful.
|
\l {Audio Overview}{audio} classes, which can be useful.
|
||||||
|
|
||||||
@@ -54,14 +54,13 @@ And an example with QGraphicsVideoItem:
|
|||||||
|
|
||||||
\section2 Playing video in QML
|
\section2 Playing video in QML
|
||||||
|
|
||||||
You can use the \l VideoOutput QML element to render content that is
|
You can use \l VideoOutput to render content that is
|
||||||
provided by either a \l MediaPlayer element or a \l Camera element.
|
provided by either a \l MediaPlayer or a \l Camera.
|
||||||
The VideoOutput element is a visual element that can be transformed
|
The VideoOutput is a visual component that can be transformed
|
||||||
or acted upon by shaders (as the \l {QML Video Shader Effects Example} shows), while
|
or acted upon by shaders (as the \l {QML Video Shader Effects Example} shows), while
|
||||||
all media decoding and playback control is handled by the MediaPlayer
|
all media decoding and playback control is handled by the \l MediaPlayer.
|
||||||
element.
|
|
||||||
|
|
||||||
Alternatively there is also a higher level \l Video element that
|
Alternatively there is also a higher level \l Video type that
|
||||||
acts as a single, visual element to play video and control playback.
|
acts as a single, visual element to play video and control playback.
|
||||||
|
|
||||||
\section2 Working with low level video frames
|
\section2 Working with low level video frames
|
||||||
@@ -88,8 +87,8 @@ the surface as the \l {QMediaPlayer::setVideoOutput()}{video output} for QMediaP
|
|||||||
Several of the built in Qt classes offer this functionality
|
Several of the built in Qt classes offer this functionality
|
||||||
as well, so if you decode video in your application, you can present
|
as well, so if you decode video in your application, you can present
|
||||||
it to classes that offer a \l QVideoRendererControl class, and in QML
|
it to classes that offer a \l QVideoRendererControl class, and in QML
|
||||||
you can set a custom object for the source of the \l VideoOutput element
|
you can set a custom object for the source of a \l VideoOutput
|
||||||
with either a writable \c videoSurface property (that the element will
|
with either a writable \c videoSurface property (that the instance will
|
||||||
set it's internal video surface to) or a readable \c mediaObject property
|
set it's internal video surface to) or a readable \c mediaObject property
|
||||||
with a QMediaObject derived class that implements the \l QVideoRendererControl
|
with a QMediaObject derived class that implements the \l QVideoRendererControl
|
||||||
interface.
|
interface.
|
||||||
@@ -137,7 +136,7 @@ There are both C++ and QML examples available.
|
|||||||
|
|
||||||
\annotatedlist multimedia_video
|
\annotatedlist multimedia_video
|
||||||
|
|
||||||
\section2 QML Elements
|
\section2 QML Types
|
||||||
|
|
||||||
\annotatedlist multimedia_video_qml
|
\annotatedlist multimedia_video_qml
|
||||||
|
|
||||||
|
|||||||
@@ -92,16 +92,15 @@ void QDeclarativeAttenuationModel::setName(const QString& name)
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass AttenuationModelLinear QDeclarativeAttenuationModelLinear
|
\qmlclass AttenuationModelLinear QDeclarativeAttenuationModelLinear
|
||||||
\since 5.0
|
\since 5.0
|
||||||
\brief The AttenuationModelLinear element allows you to define a linear attenuation curve for
|
\brief Defines a linear attenuation curve for a \l Sound.
|
||||||
Sound element.
|
|
||||||
\inqmlmodule QtAudioEngine 1
|
\inqmlmodule QtAudioEngine 1
|
||||||
\ingroup multimedia_audioengine
|
\ingroup multimedia_audioengine
|
||||||
\inherits Item
|
\inherits Item
|
||||||
\preliminary
|
\preliminary
|
||||||
|
|
||||||
This element is part of the \b{QtAudioEngine 1.0} module.
|
This type is part of the \b{QtAudioEngine 1.0} module.
|
||||||
|
|
||||||
AttenuationModelLinear must be defined inside AudioEngine.
|
AttenuationModelLinear must be defined inside \l AudioEngine.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -224,14 +223,13 @@ qreal QDeclarativeAttenuationModelLinear::calculateGain(const QVector3D &listene
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass AttenuationModelInverse QDeclarativeAttenuationModelInverse
|
\qmlclass AttenuationModelInverse QDeclarativeAttenuationModelInverse
|
||||||
\since 5.0
|
\since 5.0
|
||||||
\brief The AttenuationModelInverse element allows you to define a non-linear attenuation curve
|
\brief Defines a non-linear attenuation curve for a \l Sound.
|
||||||
for Sound element.
|
|
||||||
\inmodule QtMultimedia
|
\inmodule QtMultimedia
|
||||||
\ingroup multimedia_audioengine
|
\ingroup multimedia_audioengine
|
||||||
\inherits Item
|
\inherits Item
|
||||||
\preliminary
|
\preliminary
|
||||||
|
|
||||||
This element is part of the \b{QtAudioEngine 1.0} module.
|
This type is part of the \b{QtAudioEngine 1.0} module.
|
||||||
|
|
||||||
AttenuationModelInverse must be defined inside AudioEngine.
|
AttenuationModelInverse must be defined inside AudioEngine.
|
||||||
|
|
||||||
|
|||||||
@@ -49,15 +49,15 @@ QT_USE_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass AudioCategory QDeclarativeAudioCategory
|
\qmlclass AudioCategory QDeclarativeAudioCategory
|
||||||
\since 5.0
|
\since 5.0
|
||||||
\brief The AudioCategory element allows you to control all active sound instances by group
|
\brief Control all active sound instances by group.
|
||||||
\inqmlmodule QtAudioEngine 1
|
\inqmlmodule QtAudioEngine 1
|
||||||
\ingroup multimedia_audioengine
|
\ingroup multimedia_audioengine
|
||||||
\inherits Item
|
\inherits Item
|
||||||
\preliminary
|
\preliminary
|
||||||
|
|
||||||
This element is part of the \b{QtAudioEngine 1.0} module.
|
This type is part of the \b{QtAudioEngine 1.0} module.
|
||||||
|
|
||||||
AudioCategory element can be accessed through QtAudioEngine1::AudioEngine::categories with its
|
An instance of AudioCategory can be accessed through QtAudioEngine1::AudioEngine::categories with its
|
||||||
unique name and must be defined inside AudioEngine.
|
unique name and must be defined inside AudioEngine.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
@@ -100,11 +100,11 @@ QT_USE_NAMESPACE
|
|||||||
}
|
}
|
||||||
\endqml
|
\endqml
|
||||||
|
|
||||||
Sound elements can be grouped togather by specifying the category property. When you change the
|
\l Sound instances can be grouped together by specifying the category property. When you change the
|
||||||
volume of a category, all audio output from related elements will be affected as well.
|
volume of a category, all audio output from related instances will be affected as well.
|
||||||
|
|
||||||
Note: there will always be an AudioCategory named \c default whether you explicitly define it or
|
Note: there will always be an AudioCategory named \c default whether you explicitly define it or
|
||||||
not. If you do not specify any category for a Sound element, it will be grouped into the \c default
|
not. If you do not specify any category for a \l Sound, it will be grouped into the \c default
|
||||||
category.
|
category.
|
||||||
|
|
||||||
*/
|
*/
|
||||||
@@ -140,7 +140,7 @@ void QDeclarativeAudioCategory::componentComplete()
|
|||||||
\qmlproperty real QtAudioEngine1::AudioCategory::volume
|
\qmlproperty real QtAudioEngine1::AudioCategory::volume
|
||||||
|
|
||||||
This property holds the volume of the category and will modulate all audio output from the
|
This property holds the volume of the category and will modulate all audio output from the
|
||||||
element which belongs to this category.
|
instances which belong to this category.
|
||||||
*/
|
*/
|
||||||
qreal QDeclarativeAudioCategory::volume() const
|
qreal QDeclarativeAudioCategory::volume() const
|
||||||
{
|
{
|
||||||
@@ -162,7 +162,7 @@ void QDeclarativeAudioCategory::setVolume(qreal volume)
|
|||||||
\qmlproperty string QtAudioEngine1::AudioCategory::name
|
\qmlproperty string QtAudioEngine1::AudioCategory::name
|
||||||
|
|
||||||
This property holds the name of AudioCategory. The name must be unique among all categories and only
|
This property holds the name of AudioCategory. The name must be unique among all categories and only
|
||||||
defined once.
|
defined once. The name cannot be changed after the instance has been initialized.
|
||||||
*/
|
*/
|
||||||
void QDeclarativeAudioCategory::setName(const QString& name)
|
void QDeclarativeAudioCategory::setName(const QString& name)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -58,13 +58,13 @@ QT_USE_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass AudioEngine QDeclarativeAudioEngine
|
\qmlclass AudioEngine QDeclarativeAudioEngine
|
||||||
\since 5.0
|
\since 5.0
|
||||||
\brief The AudioEngine element allows you to organize all your 3d audio content in one place.
|
\brief The AudioEngine type allows you to organize all your 3d audio content in one place.
|
||||||
\inqmlmodule QtAudioEngine 1
|
\inqmlmodule QtAudioEngine 1
|
||||||
\ingroup multimedia_audioengine
|
\ingroup multimedia_audioengine
|
||||||
\inherits Item
|
\inherits Item
|
||||||
\preliminary
|
\preliminary
|
||||||
|
|
||||||
This element is part of the \b{QtAudioEngine 1.0} module.
|
\c AudioEngine is part of the \b{QtAudioEngine 1.0} module.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -91,7 +91,7 @@ QT_USE_NAMESPACE
|
|||||||
}
|
}
|
||||||
|
|
||||||
dopplerFactor: 1
|
dopplerFactor: 1
|
||||||
speedOfSound: 343.33
|
speedOfSound: 343.33 // Approximate speed of sound in air at 20 degrees Celsius
|
||||||
|
|
||||||
listener.up:"0,0,1"
|
listener.up:"0,0,1"
|
||||||
listener.position:"0,0,0"
|
listener.position:"0,0,0"
|
||||||
@@ -108,10 +108,10 @@ QT_USE_NAMESPACE
|
|||||||
}
|
}
|
||||||
\endqml
|
\endqml
|
||||||
|
|
||||||
The \c AudioEngine element acts as a central library for configuring all 3d audio content in an
|
\c AudioEngine acts as a central library for configuring all 3d audio content in an
|
||||||
app, so you should define only one such element in your app.
|
app, so you should define only one in your app.
|
||||||
|
|
||||||
It is mostly used as a container to access other elements such as AudioCategory, AudioSample and
|
It is mostly used as a container to access other types such as AudioCategory, AudioSample and
|
||||||
Sound.
|
Sound.
|
||||||
|
|
||||||
\sa AudioCategory, AudioSample, Sound, SoundInstance, AttenuationModelLinear, AttenuationModelInverse
|
\sa AudioCategory, AudioSample, Sound, SoundInstance, AttenuationModelLinear, AttenuationModelInverse
|
||||||
@@ -409,7 +409,7 @@ QQmlListProperty<QObject> QDeclarativeAudioEngine::bank()
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty map QtAudioEngine1::AudioEngine::categories
|
\qmlproperty map QtAudioEngine1::AudioEngine::categories
|
||||||
|
|
||||||
Container of all AudioCategory elements.
|
Container of all AudioCategory instances.
|
||||||
*/
|
*/
|
||||||
QObject* QDeclarativeAudioEngine::categories()
|
QObject* QDeclarativeAudioEngine::categories()
|
||||||
{
|
{
|
||||||
@@ -419,7 +419,7 @@ QObject* QDeclarativeAudioEngine::categories()
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty map QtAudioEngine1::AudioEngine::samples
|
\qmlproperty map QtAudioEngine1::AudioEngine::samples
|
||||||
|
|
||||||
Container of all AudioSample elements.
|
Container of all AudioSample instances.
|
||||||
*/
|
*/
|
||||||
QObject* QDeclarativeAudioEngine::samples()
|
QObject* QDeclarativeAudioEngine::samples()
|
||||||
{
|
{
|
||||||
@@ -429,7 +429,7 @@ QObject* QDeclarativeAudioEngine::samples()
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty map QtAudioEngine1::AudioEngine::sounds
|
\qmlproperty map QtAudioEngine1::AudioEngine::sounds
|
||||||
|
|
||||||
Container of all Sound elements.
|
Container of all Sound instances.
|
||||||
*/
|
*/
|
||||||
QObject* QDeclarativeAudioEngine::sounds()
|
QObject* QDeclarativeAudioEngine::sounds()
|
||||||
{
|
{
|
||||||
@@ -467,8 +467,11 @@ void QDeclarativeAudioEngine::setDopplerFactor(qreal dopplerFactor)
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty real QtAudioEngine1::AudioEngine::speedOfSound
|
\qmlproperty real QtAudioEngine1::AudioEngine::speedOfSound
|
||||||
|
|
||||||
This property holds the reference value of the sound speed which will be used in doppler shift
|
This property holds the reference value of the sound speed (in meters per second)
|
||||||
calculation.
|
which will be used in doppler shift calculation. The doppler shift calculation is
|
||||||
|
used to emulate the change in frequency in sound that is perceived by an observer when
|
||||||
|
the sound source is travelling towards or away from the observer. The speed of sound
|
||||||
|
depends on the medium the sound is propagating through.
|
||||||
*/
|
*/
|
||||||
qreal QDeclarativeAudioEngine::speedOfSound() const
|
qreal QDeclarativeAudioEngine::speedOfSound() const
|
||||||
{
|
{
|
||||||
@@ -481,7 +484,7 @@ void QDeclarativeAudioEngine::setSpeedOfSound(qreal speedOfSound)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlproperty real QtAudioEngine1::AudioEngine::loading
|
\qmlproperty bool QtAudioEngine1::AudioEngine::loading
|
||||||
|
|
||||||
This property indicates if the audio engine is loading any audio sample at the moment. This may
|
This property indicates if the audio engine is loading any audio sample at the moment. This may
|
||||||
be useful if you specified the preloaded property in AudioSample and would like to show a loading screen
|
be useful if you specified the preloaded property in AudioSample and would like to show a loading screen
|
||||||
@@ -500,22 +503,39 @@ void QDeclarativeAudioEngine::handleLoadingChanged()
|
|||||||
emit finishedLoading();
|
emit finishedLoading();
|
||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
|
||||||
\qmlsignal QtAudioEngine1::AudioEngine::onLiveInstancesChanged()
|
|
||||||
|
|
||||||
This handler is called when \l liveInstances is changed
|
|
||||||
*/
|
|
||||||
|
|
||||||
/*!
|
|
||||||
\qmlsignal QtAudioEngine1::AudioEngine::onLoadingChanged()
|
|
||||||
|
|
||||||
This handler is called when \l loading is changed
|
|
||||||
*/
|
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtAudioEngine1::AudioEngine::finishedLoading()
|
\qmlsignal QtAudioEngine1::AudioEngine::finishedLoading()
|
||||||
|
|
||||||
This handler is called when \l loading is finished
|
This signal is emitted when \l loading has completed.
|
||||||
|
|
||||||
|
The corresponding handler is \c onFinishedLoading.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/*!
|
||||||
|
\qmlsignal QtAudioEngine1::AudioEngine::ready()
|
||||||
|
|
||||||
|
This signal is emitted when the AudioEngine is ready to use.
|
||||||
|
|
||||||
|
The corresponding handler is \c onReady.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*!
|
||||||
|
\qmlsignal QtAudioEngine1::AudioEngine::liveInstanceCountChanged()
|
||||||
|
|
||||||
|
This signal is emitted when the number of live instances managed by the
|
||||||
|
AudioEngine is changed.
|
||||||
|
|
||||||
|
The corresponding handler is \c onLiveInstanceCountChanged.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*!
|
||||||
|
\qmlsignal QtAudioEngine1::AudioEngine::isLoadingChanged()
|
||||||
|
|
||||||
|
This signal is emitted when the \l loading property changes.
|
||||||
|
|
||||||
|
The corresponding handler is \c onIsLoadingChanged.
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
|
|||||||
@@ -50,13 +50,13 @@ QT_USE_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass AudioListener QDeclarativeAudioListener
|
\qmlclass AudioListener QDeclarativeAudioListener
|
||||||
\since 5.0
|
\since 5.0
|
||||||
\brief The AudioListener element allows you to control global listener parameters.
|
\brief The AudioListener type allows you to control global listener parameters.
|
||||||
\inqmlmodule QtAudioEngine 1
|
\inqmlmodule QtAudioEngine 1
|
||||||
\ingroup multimedia_audioengine
|
\ingroup multimedia_audioengine
|
||||||
\inherits Item
|
\inherits Item
|
||||||
\preliminary
|
\preliminary
|
||||||
|
|
||||||
This element is part of the \b{QtAudioEngine 1.0} module.
|
This type is part of the \b{QtAudioEngine 1.0} module.
|
||||||
|
|
||||||
AudioListener will have only one global instance and you can either access it through the
|
AudioListener will have only one global instance and you can either access it through the
|
||||||
listener property of AudioEngine:
|
listener property of AudioEngine:
|
||||||
@@ -97,7 +97,7 @@ QT_USE_NAMESPACE
|
|||||||
}
|
}
|
||||||
\endqml
|
\endqml
|
||||||
|
|
||||||
or alternatively, by defining an AudioListener element outside AudioEngine:
|
or alternatively, by defining an AudioListener outside AudioEngine:
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -248,7 +248,7 @@ void QDeclarativeAudioListener::setUp(const QVector3D &up)
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty real QtAudioEngine1::AudioListener::gain
|
\qmlproperty real QtAudioEngine1::AudioListener::gain
|
||||||
|
|
||||||
This property will modulate all audio output from audio engine elements.
|
This property will modulate all audio output from audio engine instances.
|
||||||
*/
|
*/
|
||||||
qreal QDeclarativeAudioListener::gain() const
|
qreal QDeclarativeAudioListener::gain() const
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -52,15 +52,15 @@ QT_USE_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass AudioSample QDeclarativeAudioSample
|
\qmlclass AudioSample QDeclarativeAudioSample
|
||||||
\since 5.0
|
\since 5.0
|
||||||
\brief The AudioSample element allows you to load audio samples, mostly wav file.
|
\brief The AudioSample type allows you to load audio samples, mostly wav file.
|
||||||
\inqmlmodule QtAudioEngine 1
|
\inqmlmodule QtAudioEngine 1
|
||||||
\ingroup multimedia_audioengine
|
\ingroup multimedia_audioengine
|
||||||
\inherits Item
|
\inherits Item
|
||||||
\preliminary
|
\preliminary
|
||||||
|
|
||||||
This element is part of the \b{QtAudioEngine 1.0} module.
|
\c AudioSample is part of the \b{QtAudioEngine 1.0} module.
|
||||||
|
|
||||||
AudioSample element can be accessed through QtAudioEngine1::AudioEngine::samples with its unique
|
It can be accessed through QtAudioEngine1::AudioEngine::samples with its unique
|
||||||
name and must be defined inside AudioEngine.
|
name and must be defined inside AudioEngine.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
@@ -135,9 +135,9 @@ bool QDeclarativeAudioSample::isStreaming() const
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty bool QtAudioEngine1::AudioSample::preloaded
|
\qmlproperty bool QtAudioEngine1::AudioSample::preloaded
|
||||||
|
|
||||||
This property holds indicates whether this sample needs to be preloaded or not.
|
This property indicates whether this sample needs to be preloaded or not.
|
||||||
If true, the audio engine will start loading the sample file immediately when the app started,
|
If true, the audio engine will start loading the sample file immediately when the app started,
|
||||||
otherwise the sample will not be loaded untill be used by other element.
|
otherwise the sample will not be loaded until explicitly requested.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
bool QDeclarativeAudioSample::isPreloaded() const
|
bool QDeclarativeAudioSample::isPreloaded() const
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ QT_USE_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass PlayVariation QDeclarativePlayVariation
|
\qmlclass PlayVariation QDeclarativePlayVariation
|
||||||
\since 5.0
|
\since 5.0
|
||||||
\brief The PlayVariation element allows you to define a playback variation for \l Sound element.
|
\brief The PlayVariation type allows you to define a playback variation for \l {Sound} {sounds}.
|
||||||
So each time the playback of the same sound can be a slightly different even with the same
|
So each time the playback of the same sound can be a slightly different even with the same
|
||||||
AudioSample.
|
AudioSample.
|
||||||
|
|
||||||
@@ -60,9 +60,9 @@ QT_USE_NAMESPACE
|
|||||||
\inherits Item
|
\inherits Item
|
||||||
\preliminary
|
\preliminary
|
||||||
|
|
||||||
This element is part of the \b{QtAudioEngine 1.0} module.
|
This type is part of the \b{QtAudioEngine 1.0} module.
|
||||||
|
|
||||||
PlayVariation must be defined inside \l Sound element.
|
PlayVariation must be defined inside a \l Sound.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
|
|||||||
@@ -140,16 +140,16 @@ void QDeclarativeSoundCone::componentComplete()
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass Sound QDeclarativeSound
|
\qmlclass Sound QDeclarativeSound
|
||||||
\since 5.0
|
\since 5.0
|
||||||
\brief The Sound element allows you to define a variety of samples and parameters to be used for
|
\brief The Sound type allows you to define a variety of samples and parameters to be used for
|
||||||
SoundInstance.
|
SoundInstance.
|
||||||
\inqmlmodule QtAudioEngine 1
|
\inqmlmodule QtAudioEngine 1
|
||||||
\ingroup multimedia_audioengine
|
\ingroup multimedia_audioengine
|
||||||
\inherits Item
|
\inherits Item
|
||||||
\preliminary
|
\preliminary
|
||||||
|
|
||||||
This element is part of the \b{QtAudioEngine 1.0} module.
|
This type is part of the \b{QtAudioEngine 1.0} module.
|
||||||
|
|
||||||
Sound element can be accessed through QtAudioEngine1::AudioEngine::sounds with its unique name
|
Sound can be accessed through QtAudioEngine1::AudioEngine::sounds with its unique name
|
||||||
and must be defined inside AudioEngine.
|
and must be defined inside AudioEngine.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
@@ -227,7 +227,7 @@ void QDeclarativeSound::componentComplete()
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlproperty enueration QtAudioEngine1::Sound::playType
|
\qmlproperty enumeration QtAudioEngine1::Sound::playType
|
||||||
|
|
||||||
This property holds the playType. It can be one of:
|
This property holds the playType. It can be one of:
|
||||||
|
|
||||||
|
|||||||
@@ -53,16 +53,16 @@ QT_USE_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass SoundInstance QDeclarativeSoundInstance
|
\qmlclass SoundInstance QDeclarativeSoundInstance
|
||||||
\since 5.0
|
\since 5.0
|
||||||
\brief The SoundInstance element allows you to play 3d audio content.
|
\brief The SoundInstance type allows you to play 3d audio content.
|
||||||
\inqmlmodule QtAudioEngine 1
|
\inqmlmodule QtAudioEngine 1
|
||||||
\ingroup multimedia_audioengine
|
\ingroup multimedia_audioengine
|
||||||
\inherits Item
|
\inherits Item
|
||||||
\preliminary
|
\preliminary
|
||||||
|
|
||||||
This element is part of the \b{QtAudioEngine 1.0} module.
|
This type is part of the \b{QtAudioEngine 1.0} module.
|
||||||
|
|
||||||
There are two ways to create SoundInstance objects. You can obtain it by calling newInstance
|
There are two ways to create SoundInstance objects. You can obtain it by calling newInstance
|
||||||
method of Sound element:
|
method of a \l Sound:
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -101,7 +101,7 @@ QT_USE_NAMESPACE
|
|||||||
}
|
}
|
||||||
\endqml
|
\endqml
|
||||||
|
|
||||||
Or alternatively, you can explicitly define SoundInstance element outside of AudioEngine for
|
Or alternatively, you can explicitly define SoundInstance outside of AudioEngine for
|
||||||
easier qml bindings:
|
easier qml bindings:
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
@@ -236,7 +236,7 @@ QDeclarativeSoundInstance::~QDeclarativeSoundInstance()
|
|||||||
\qmlproperty string QtAudioEngine1::SoundInstance::sound
|
\qmlproperty string QtAudioEngine1::SoundInstance::sound
|
||||||
|
|
||||||
This property specifies which Sound this SoundInstance will use. Unlike some properties in
|
This property specifies which Sound this SoundInstance will use. Unlike some properties in
|
||||||
other elements, this property can be changed dynamically.
|
other types, this property can be changed dynamically.
|
||||||
*/
|
*/
|
||||||
QString QDeclarativeSoundInstance::sound() const
|
QString QDeclarativeSoundInstance::sound() const
|
||||||
{
|
{
|
||||||
@@ -258,7 +258,7 @@ void QDeclarativeSoundInstance::setSound(const QString& sound)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifdef DEBUG_AUDIOENGINE
|
#ifdef DEBUG_AUDIOENGINE
|
||||||
qDebug() << "SoundInstance Element switch sound from [" << m_sound << "] to [" << sound << "]";
|
qDebug() << "SoundInstance switch sound from [" << m_sound << "] to [" << sound << "]";
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
stop();
|
stop();
|
||||||
@@ -297,11 +297,17 @@ void QDeclarativeSoundInstance::dropInstance()
|
|||||||
|
|
||||||
This property holds the current playback state. It can be one of:
|
This property holds the current playback state. It can be one of:
|
||||||
|
|
||||||
\list
|
\table
|
||||||
\li StopppedState
|
\header \li Value \li Description
|
||||||
\li PlayingState
|
\row \li StopppedState
|
||||||
\li PausedState
|
\li The SoundInstance is not playing, and when playback begins next it
|
||||||
\endlist
|
will play from position zero.
|
||||||
|
\row \li PlayingState
|
||||||
|
\li The SoundInstance is playing the media.
|
||||||
|
\row \li PausedState
|
||||||
|
\li The SoundInstance is not playing, and when playback begins next it
|
||||||
|
will play from the position that it was paused at.
|
||||||
|
\endtable
|
||||||
*/
|
*/
|
||||||
QDeclarativeSoundInstance::State QDeclarativeSoundInstance::state() const
|
QDeclarativeSoundInstance::State QDeclarativeSoundInstance::state() const
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -47,12 +47,12 @@ import QtMultimedia 5.0
|
|||||||
\inherits Item
|
\inherits Item
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup multimedia_video_qml
|
\ingroup multimedia_video_qml
|
||||||
\brief A convenience element for showing a specified video
|
\brief A convenience type for showing a specified video
|
||||||
|
|
||||||
The \c Video element is a convenience element combining the functionality
|
\c Video is a convenience type combining the functionality
|
||||||
of the \l MediaPlayer and \l VideoOutput elements into one. It provides
|
of a \l MediaPlayer and a \l VideoOutput into one. It provides
|
||||||
simple video playback functionality without having to specify multiple
|
simple video playback functionality without having to declare multiple
|
||||||
elements.
|
types.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -78,7 +78,7 @@ import QtMultimedia 5.0
|
|||||||
}
|
}
|
||||||
\endqml
|
\endqml
|
||||||
|
|
||||||
The Video element supports untransformed, stretched, and uniformly scaled
|
\c Video supports untransformed, stretched, and uniformly scaled
|
||||||
video presentation. For a description of stretched uniformly scaled
|
video presentation. For a description of stretched uniformly scaled
|
||||||
presentation, see the \l fillMode property description.
|
presentation, see the \l fillMode property description.
|
||||||
|
|
||||||
@@ -87,8 +87,8 @@ import QtMultimedia 5.0
|
|||||||
\section1 Screen Saver
|
\section1 Screen Saver
|
||||||
|
|
||||||
If it is likely that an application will be playing video for an extended
|
If it is likely that an application will be playing video for an extended
|
||||||
period of time without user interaction it may be necessary to disable
|
period of time without user interaction, it may be necessary to disable
|
||||||
the platform's screen saver. The \l ScreenSaver element (from \l QtSystemInfo)
|
the platform's screen saver. The \l ScreenSaver (from \l QtSystemInfo)
|
||||||
may be used to disable the screensaver in this fashion:
|
may be used to disable the screensaver in this fashion:
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
@@ -116,8 +116,8 @@ Item {
|
|||||||
if necessary
|
if necessary
|
||||||
\endlist
|
\endlist
|
||||||
|
|
||||||
Because this element is a convenience element in QML, it does not
|
Because this type is for convenience in QML, it does not
|
||||||
support enumerations directly, so enumerations from VideoOuput are
|
support enumerations directly, so enumerations from \c VideoOuput are
|
||||||
used to access the available fill modes.
|
used to access the available fill modes.
|
||||||
|
|
||||||
The default fill mode is preserveAspectFit.
|
The default fill mode is preserveAspectFit.
|
||||||
@@ -127,7 +127,7 @@ Item {
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty int Video::orientation
|
\qmlproperty int Video::orientation
|
||||||
|
|
||||||
The orientation of the Video element in degrees. Only multiples of 90
|
The orientation of the \c Video in degrees. Only multiples of 90
|
||||||
degrees is supported, that is 0, 90, 180, 270, 360, etc.
|
degrees is supported, that is 0, 90, 180, 270, 360, etc.
|
||||||
*/
|
*/
|
||||||
property alias orientation: videoOut.orientation
|
property alias orientation: videoOut.orientation
|
||||||
@@ -209,7 +209,7 @@ Item {
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty enumeration Video::availability
|
\qmlproperty enumeration Video::availability
|
||||||
|
|
||||||
Returns the availability state of the video element.
|
Returns the availability state of the video instance.
|
||||||
|
|
||||||
This is one of:
|
This is one of:
|
||||||
\table
|
\table
|
||||||
|
|||||||
@@ -82,17 +82,17 @@ public:
|
|||||||
qmlRegisterType<QDeclarativeRadioData>(uri, 4, 0, "RadioData");
|
qmlRegisterType<QDeclarativeRadioData>(uri, 4, 0, "RadioData");
|
||||||
qmlRegisterType<QDeclarativeCamera>(uri, 4, 0, "Camera");
|
qmlRegisterType<QDeclarativeCamera>(uri, 4, 0, "Camera");
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraCapture>(uri, 4, 0, "CameraCapture",
|
qmlRegisterUncreatableType<QDeclarativeCameraCapture>(uri, 4, 0, "CameraCapture",
|
||||||
trUtf8("CameraCapture is only provided by Camera element"));
|
trUtf8("CameraCapture is provided by Camera"));
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraRecorder>(uri, 4, 0, "CameraRecorder",
|
qmlRegisterUncreatableType<QDeclarativeCameraRecorder>(uri, 4, 0, "CameraRecorder",
|
||||||
trUtf8("CameraRecorder is only provided by Camera element"));
|
trUtf8("CameraRecorder is provided by Camera"));
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraExposure>(uri, 4, 0, "CameraExposure",
|
qmlRegisterUncreatableType<QDeclarativeCameraExposure>(uri, 4, 0, "CameraExposure",
|
||||||
trUtf8("CameraExposure is only provided by Camera element"));
|
trUtf8("CameraExposure is provided by Camera"));
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraFocus>(uri, 4, 0, "CameraFocus",
|
qmlRegisterUncreatableType<QDeclarativeCameraFocus>(uri, 4, 0, "CameraFocus",
|
||||||
trUtf8("CameraFocus is only provided by Camera element"));
|
trUtf8("CameraFocus is provided by Camera"));
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraFlash>(uri, 4, 0, "CameraFlash",
|
qmlRegisterUncreatableType<QDeclarativeCameraFlash>(uri, 4, 0, "CameraFlash",
|
||||||
trUtf8("CameraFlash is only provided by Camera element"));
|
trUtf8("CameraFlash is provided by Camera"));
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraImageProcessing>(uri, 4, 0, "CameraImageProcessing",
|
qmlRegisterUncreatableType<QDeclarativeCameraImageProcessing>(uri, 4, 0, "CameraImageProcessing",
|
||||||
trUtf8("CameraImageProcessing is only provided by Camera element"));
|
trUtf8("CameraImageProcessing is only provided by Camera type"));
|
||||||
|
|
||||||
// Introduced to help transition from QtMultimedia 4.0 to 5.0 (official for Qt 5)
|
// Introduced to help transition from QtMultimedia 4.0 to 5.0 (official for Qt 5)
|
||||||
// the 4.0 versioned types will be removed once all clients have made the transition.
|
// the 4.0 versioned types will be removed once all clients have made the transition.
|
||||||
@@ -105,17 +105,17 @@ public:
|
|||||||
qmlRegisterType<QDeclarativeCamera>(uri, 5, 0, "Camera");
|
qmlRegisterType<QDeclarativeCamera>(uri, 5, 0, "Camera");
|
||||||
qmlRegisterType<QDeclarativeTorch>(uri, 5, 0, "Torch");
|
qmlRegisterType<QDeclarativeTorch>(uri, 5, 0, "Torch");
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraCapture>(uri, 5, 0, "CameraCapture",
|
qmlRegisterUncreatableType<QDeclarativeCameraCapture>(uri, 5, 0, "CameraCapture",
|
||||||
trUtf8("CameraCapture is only provided by Camera element"));
|
trUtf8("CameraCapture is provided by Camera"));
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraRecorder>(uri, 5, 0, "CameraRecorder",
|
qmlRegisterUncreatableType<QDeclarativeCameraRecorder>(uri, 5, 0, "CameraRecorder",
|
||||||
trUtf8("CameraRecorder is only provided by Camera element"));
|
trUtf8("CameraRecorder is provided by Camera"));
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraExposure>(uri, 5, 0, "CameraExposure",
|
qmlRegisterUncreatableType<QDeclarativeCameraExposure>(uri, 5, 0, "CameraExposure",
|
||||||
trUtf8("CameraExposure is only provided by Camera element"));
|
trUtf8("CameraExposure is provided by Camera"));
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraFocus>(uri, 5, 0, "CameraFocus",
|
qmlRegisterUncreatableType<QDeclarativeCameraFocus>(uri, 5, 0, "CameraFocus",
|
||||||
trUtf8("CameraFocus is only provided by Camera element"));
|
trUtf8("CameraFocus is provided by Camera"));
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraFlash>(uri, 5, 0, "CameraFlash",
|
qmlRegisterUncreatableType<QDeclarativeCameraFlash>(uri, 5, 0, "CameraFlash",
|
||||||
trUtf8("CameraFlash is only provided by Camera element"));
|
trUtf8("CameraFlash is provided by Camera"));
|
||||||
qmlRegisterUncreatableType<QDeclarativeCameraImageProcessing>(uri, 5, 0, "CameraImageProcessing",
|
qmlRegisterUncreatableType<QDeclarativeCameraImageProcessing>(uri, 5, 0, "CameraImageProcessing",
|
||||||
trUtf8("CameraImageProcessing is only provided by Camera element"));
|
trUtf8("CameraImageProcessing is provided by Camera"));
|
||||||
|
|
||||||
qmlRegisterType<QDeclarativeMediaMetaData>();
|
qmlRegisterType<QDeclarativeMediaMetaData>();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -58,14 +58,14 @@ QT_BEGIN_NAMESPACE
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlclass MediaPlayer
|
\qmlclass MediaPlayer
|
||||||
\brief The MediaPlayer element allows you to add media playback to a scene.
|
\brief The MediaPlayer type allows you to add media playback to a scene.
|
||||||
|
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup multimedia_audio_qml
|
\ingroup multimedia_audio_qml
|
||||||
\ingroup multimedia_video_qml
|
\ingroup multimedia_video_qml
|
||||||
|
|
||||||
This element is part of the \b{QtMultimedia 5.0} module.
|
MediaPlayer is part of the \b{QtMultimedia 5.0} module.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -88,8 +88,8 @@ QT_BEGIN_NAMESPACE
|
|||||||
}
|
}
|
||||||
\endqml
|
\endqml
|
||||||
|
|
||||||
You can use MediaPlayer by itself to play audio content (like the \l Audio element),
|
You can use MediaPlayer by itself to play audio content (like \l Audio),
|
||||||
or you can use it in conjunction with a \l VideoOutput element for rendering video.
|
or you can use it in conjunction with a \l VideoOutput for rendering video.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -119,13 +119,13 @@ QT_BEGIN_NAMESPACE
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlclass Audio QDeclarativeAudio
|
\qmlclass Audio QDeclarativeAudio
|
||||||
\brief The Audio element allows you to add audio playback to a scene.
|
\brief The Audio type allows you to add audio playback to a scene.
|
||||||
|
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup multimedia_audio_qml
|
\ingroup multimedia_audio_qml
|
||||||
|
|
||||||
This element is part of the \b{QtMultimedia 5.0} module.
|
This type is part of the \b{QtMultimedia 5.0} module.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -495,7 +495,7 @@ void QDeclarativeAudio::stop()
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlproperty url QtMultimedia5::Audio::autoLoad
|
\qmlproperty bool QtMultimedia5::Audio::autoLoad
|
||||||
|
|
||||||
This property indicates if loading of media should begin immediately.
|
This property indicates if loading of media should begin immediately.
|
||||||
|
|
||||||
@@ -569,7 +569,7 @@ QDeclarativeAudio::PlaybackState QDeclarativeAudio::playbackState() const
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlproperty int QtMultimedia5::Audio::autoPlay
|
\qmlproperty bool QtMultimedia5::Audio::autoPlay
|
||||||
|
|
||||||
This property controls whether the media will begin to play on start up.
|
This property controls whether the media will begin to play on start up.
|
||||||
|
|
||||||
@@ -596,12 +596,16 @@ QDeclarativeAudio::PlaybackState QDeclarativeAudio::playbackState() const
|
|||||||
\qmlproperty real QtMultimedia5::Audio::volume
|
\qmlproperty real QtMultimedia5::Audio::volume
|
||||||
|
|
||||||
This property holds the volume of the audio output, from 0.0 (silent) to 1.0 (maximum volume).
|
This property holds the volume of the audio output, from 0.0 (silent) to 1.0 (maximum volume).
|
||||||
|
|
||||||
|
Defaults to 1.0.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlproperty bool QtMultimedia5::Audio::muted
|
\qmlproperty bool QtMultimedia5::Audio::muted
|
||||||
|
|
||||||
This property holds whether the audio output is muted.
|
This property holds whether the audio output is muted.
|
||||||
|
|
||||||
|
Defaults to false.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@@ -645,6 +649,8 @@ bool QDeclarativeAudio::hasVideo() const
|
|||||||
\qmlproperty real QtMultimedia5::Audio::playbackRate
|
\qmlproperty real QtMultimedia5::Audio::playbackRate
|
||||||
|
|
||||||
This property holds the rate at which audio is played at as a multiple of the normal rate.
|
This property holds the rate at which audio is played at as a multiple of the normal rate.
|
||||||
|
|
||||||
|
Defaults to 1.0.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@@ -652,15 +658,22 @@ bool QDeclarativeAudio::hasVideo() const
|
|||||||
|
|
||||||
This property holds the error state of the audio. It can be one of:
|
This property holds the error state of the audio. It can be one of:
|
||||||
|
|
||||||
\list
|
\table
|
||||||
\li NoError - there is no current error.
|
\header \li Value \li Description
|
||||||
\li ResourceError - the audio cannot be played due to a problem allocating resources.
|
\row \li NoError
|
||||||
\li FormatError - the audio format is not supported.
|
\li There is no current error.
|
||||||
\li NetworkError - the audio cannot be played due to network issues.
|
\row \li ResourceError
|
||||||
\li AccessDenied - the audio cannot be played due to insufficient permissions.
|
\li The audio cannot be played due to a problem allocating resources.
|
||||||
\li ServiceMissing - the audio cannot be played because the media service could not be
|
\row \li FormatError
|
||||||
|
\li The audio format is not supported.
|
||||||
|
\row \li NetworkError
|
||||||
|
\li The audio cannot be played due to network issues.
|
||||||
|
\row \li AccessDenied
|
||||||
|
\li The audio cannot be played due to insufficient permissions.
|
||||||
|
\row \li ServiceMissing
|
||||||
|
\li The audio cannot be played because the media service could not be
|
||||||
instantiated.
|
instantiated.
|
||||||
\endlist
|
\endtable
|
||||||
*/
|
*/
|
||||||
|
|
||||||
QDeclarativeAudio::Error QDeclarativeAudio::error() const
|
QDeclarativeAudio::Error QDeclarativeAudio::error() const
|
||||||
@@ -940,7 +953,7 @@ void QDeclarativeAudio::_q_statusChanged()
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty variant QtMultimedia5::Audio::metaData.audioBitRate
|
\qmlproperty variant QtMultimedia5::Audio::metaData.audioBitRate
|
||||||
|
|
||||||
This property holds the bit rate of the media's audio stream ni bits per
|
This property holds the bit rate of the media's audio stream in bits per
|
||||||
second.
|
second.
|
||||||
|
|
||||||
\sa {QtMultimedia::MetaData::AudioBitRate}
|
\sa {QtMultimedia::MetaData::AudioBitRate}
|
||||||
@@ -1054,7 +1067,7 @@ void QDeclarativeAudio::_q_statusChanged()
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty variant QtMultimedia5::Audio::metaData.trackCount
|
\qmlproperty variant QtMultimedia5::Audio::metaData.trackCount
|
||||||
|
|
||||||
This property holds the number of track on the album containing the media.
|
This property holds the number of tracks on the album containing the media.
|
||||||
|
|
||||||
\sa {QtMultimedia::MetaData::TrackNumber}
|
\sa {QtMultimedia::MetaData::TrackNumber}
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -75,18 +75,18 @@ void QDeclarativeCamera::_q_availabilityChanged(QtMultimedia::AvailabilityError
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlclass Camera QDeclarativeCamera
|
\qmlclass Camera QDeclarativeCamera
|
||||||
\brief The Camera element allows you to access viewfinder frames, and take photos and movies.
|
\brief The Camera type allows you to access viewfinder frames, and take photos and movies.
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup camera_qml
|
\ingroup camera_qml
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
|
|
||||||
\inherits Item
|
\inherits Item
|
||||||
|
|
||||||
This element is part of the \b{QtMultimedia 5.0} module.
|
Camera is part of the \b{QtMultimedia 5.0} module.
|
||||||
|
|
||||||
You can use the \c Camera element to capture images and movies from a camera, and manipulate
|
You can use \c Camera to capture images and movies from a camera, and manipulate
|
||||||
the capture and processing settings that get applied to the images. To display the
|
the capture and processing settings that get applied to the images. To display the
|
||||||
viewfinder you can use a \l VideoOutput element with the Camera element set as the source.
|
viewfinder you can use \l VideoOutput with the Camera set as the source.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
|
|
||||||
@@ -111,7 +111,7 @@ void QDeclarativeCamera::_q_availabilityChanged(QtMultimedia::AvailabilityError
|
|||||||
|
|
||||||
imageCapture {
|
imageCapture {
|
||||||
onImageCaptured: {
|
onImageCaptured: {
|
||||||
photoPreview.source = preview // Show the preview in an Image element
|
photoPreview.source = preview // Show the preview in an Image
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -148,15 +148,15 @@ void QDeclarativeCamera::_q_availabilityChanged(QtMultimedia::AvailabilityError
|
|||||||
\endtable
|
\endtable
|
||||||
|
|
||||||
Basic camera state management, error reporting, and simple zoom properties are
|
Basic camera state management, error reporting, and simple zoom properties are
|
||||||
available in the Camera element itself. For integration with C++ code, the
|
available in the Camera itself. For integration with C++ code, the
|
||||||
\l mediaObject property allows you to
|
\l mediaObject property allows you to
|
||||||
access the standard QtMultimedia camera controls.
|
access the standard QtMultimedia camera controls.
|
||||||
|
|
||||||
Many of the camera settings may take some time to apply, and might be limited
|
Many of the camera settings may take some time to apply, and might be limited
|
||||||
to certain supported values depending on the hardware. Several camera settings
|
to certain supported values depending on the hardware. Some camera settings may be
|
||||||
support both automatic and manual modes, with the current actual setting being
|
set manually or automatically. These settings properties contain the current set value.
|
||||||
used being exposed.
|
For example, when autofocus is enabled the focus zones are exposed in the
|
||||||
|
\l {CameraFocus}{focus} property.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@@ -267,10 +267,10 @@ QDeclarativeCamera::Availability QDeclarativeCamera::availability() const
|
|||||||
\table
|
\table
|
||||||
\header \li Value \li Description
|
\header \li Value \li Description
|
||||||
\row \li CaptureStillImage
|
\row \li CaptureStillImage
|
||||||
\li Prepares the camera element for capturing still images.
|
\li Prepares the Camera for capturing still images.
|
||||||
|
|
||||||
\row \li CaptureVideo
|
\row \li CaptureVideo
|
||||||
\li Prepares the camera element for capturing video.
|
\li Prepares the Camera for capturing video.
|
||||||
|
|
||||||
\endtable
|
\endtable
|
||||||
|
|
||||||
@@ -345,7 +345,6 @@ void QDeclarativeCamera::setCameraState(QDeclarativeCamera::State state)
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlmethod QtMultimedia5::Camera::start()
|
\qmlmethod QtMultimedia5::Camera::start()
|
||||||
\fn QDeclarativeCamera::start()
|
|
||||||
|
|
||||||
Starts the camera. Viewfinder frames will
|
Starts the camera. Viewfinder frames will
|
||||||
be available and image or movie capture will
|
be available and image or movie capture will
|
||||||
@@ -358,7 +357,6 @@ void QDeclarativeCamera::start()
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlmethod QtMultimedia5::Camera::stop()
|
\qmlmethod QtMultimedia5::Camera::stop()
|
||||||
\fn QDeclarativeCamera::stop()
|
|
||||||
|
|
||||||
Stops the camera, but leaves the camera
|
Stops the camera, but leaves the camera
|
||||||
stack loaded.
|
stack loaded.
|
||||||
@@ -392,7 +390,7 @@ void QDeclarativeCamera::stop()
|
|||||||
The locked state usually means the requested parameter stays the same,
|
The locked state usually means the requested parameter stays the same,
|
||||||
except in the cases when the parameter is requested to be constantly updated.
|
except in the cases when the parameter is requested to be constantly updated.
|
||||||
For example in continuous focusing mode, the focus is considered locked as long
|
For example in continuous focusing mode, the focus is considered locked as long
|
||||||
and the object is in focus, even while the actual focusing distance may be constantly changing.
|
as the object is in focus, even while the actual focusing distance may be constantly changing.
|
||||||
\endtable
|
\endtable
|
||||||
*/
|
*/
|
||||||
/*!
|
/*!
|
||||||
@@ -428,7 +426,6 @@ QDeclarativeCamera::LockStatus QDeclarativeCamera::lockStatus() const
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlmethod QtMultimedia5::Camera::searchAndLock()
|
\qmlmethod QtMultimedia5::Camera::searchAndLock()
|
||||||
\fn QDeclarativeCamera::searchAndLock()
|
|
||||||
|
|
||||||
Start focusing, exposure and white balance calculation.
|
Start focusing, exposure and white balance calculation.
|
||||||
|
|
||||||
@@ -444,7 +441,6 @@ void QDeclarativeCamera::searchAndLock()
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlmethod QtMultimedia5::Camera::unlock()
|
\qmlmethod QtMultimedia5::Camera::unlock()
|
||||||
\fn QDeclarativeCamera::unlock()
|
|
||||||
|
|
||||||
Unlock focus, exposure and white balance locks.
|
Unlock focus, exposure and white balance locks.
|
||||||
*/
|
*/
|
||||||
@@ -510,7 +506,7 @@ void QDeclarativeCamera::setDigitalZoom(qreal value)
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty variant QtMultimedia5::Camera::mediaObject
|
\qmlproperty variant QtMultimedia5::Camera::mediaObject
|
||||||
|
|
||||||
The media object for the Camera element.
|
The media object for the Camera.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@@ -547,8 +543,6 @@ void QDeclarativeCamera::setDigitalZoom(qreal value)
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\fn void QDeclarativeCamera::lockStatusChanged()
|
|
||||||
|
|
||||||
\qmlsignal Camera::lockStatusChanged()
|
\qmlsignal Camera::lockStatusChanged()
|
||||||
|
|
||||||
This signal is emitted when the lock status (focus, exposure etc) changes.
|
This signal is emitted when the lock status (focus, exposure etc) changes.
|
||||||
@@ -556,7 +550,6 @@ void QDeclarativeCamera::setDigitalZoom(qreal value)
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\fn void QDeclarativeCamera::stateChanged(QDeclarativeCamera::State state)
|
|
||||||
\qmlsignal Camera::stateChanged(state)
|
\qmlsignal Camera::stateChanged(state)
|
||||||
|
|
||||||
This signal is emitted when the camera state has changed to \a state. Since the
|
This signal is emitted when the camera state has changed to \a state. Since the
|
||||||
|
|||||||
@@ -51,16 +51,16 @@ QT_BEGIN_NAMESPACE
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlclass CameraCapture QDeclarativeCameraCapture
|
\qmlclass CameraCapture QDeclarativeCameraCapture
|
||||||
\brief The CameraCapture element provides an interface for capturing camera images
|
\brief The CameraCapture type provides an interface for capturing camera images
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
\ingroup camera_qml
|
\ingroup camera_qml
|
||||||
|
|
||||||
This element allows you to capture still images and be notified when they
|
This type allows you to capture still images and be notified when they
|
||||||
are available or saved to disk. You can adjust the resolution of the captured
|
are available or saved to disk. You can adjust the resolution of the captured
|
||||||
image and where the saved image should go.
|
image and where the saved image should go.
|
||||||
|
|
||||||
This element is a child of a \l Camera element (as the \c imageCapture property)
|
CameraCapture is a child of a \l Camera (as the \c imageCapture property)
|
||||||
and cannot be created directly.
|
and cannot be created directly.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
@@ -76,7 +76,7 @@ QT_BEGIN_NAMESPACE
|
|||||||
|
|
||||||
imageCapture {
|
imageCapture {
|
||||||
onImageCaptured: {
|
onImageCaptured: {
|
||||||
// Show the preview in an Image element
|
// Show the preview in an Image
|
||||||
photoPreview.source = preview
|
photoPreview.source = preview
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -143,12 +143,14 @@ bool QDeclarativeCameraCapture::isReadyForCapture() const
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlmethod QtMultimedia5::CameraCapture::capture()
|
\qmlmethod QtMultimedia5::CameraCapture::capture()
|
||||||
\fn QDeclarativeCameraCapture::capture()
|
|
||||||
|
|
||||||
Start image capture. The \l onImageCaptured() and \l onImageSaved() signals will
|
Start image capture. The \l onImageCaptured() and \l onImageSaved() signals will
|
||||||
be emitted when the capture is complete.
|
be emitted when the capture is complete.
|
||||||
|
|
||||||
The image will be captured to the default system location.
|
The image will be captured to the default system location, typically
|
||||||
|
QStandardPaths::writableLocation(QStandardPaths::PicturesLocation) for
|
||||||
|
still imaged or QStandardPaths::writableLocation(QStandardPaths::MoviesLocation)
|
||||||
|
for video.
|
||||||
|
|
||||||
Camera saves all the capture parameters like exposure settings or
|
Camera saves all the capture parameters like exposure settings or
|
||||||
image processing parameters, so changes to camera paramaters after
|
image processing parameters, so changes to camera paramaters after
|
||||||
@@ -164,13 +166,17 @@ int QDeclarativeCameraCapture::capture()
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlmethod QtMultimedia5::CameraCapture::captureToLocation(location)
|
\qmlmethod QtMultimedia5::CameraCapture::captureToLocation(location)
|
||||||
\fn QDeclarativeCameraCapture::captureToLocation(const QString &location)
|
|
||||||
|
|
||||||
Start image capture to specified \a location. The \l onImageCaptured() and \l onImageSaved() signals will
|
Start image capture to specified \a location. The \l onImageCaptured() and \l onImageSaved() signals will
|
||||||
be emitted when the capture is complete.
|
be emitted when the capture is complete.
|
||||||
|
|
||||||
CameraCapture::captureToLocation returns the capture requestId parameter, used with
|
CameraCapture::captureToLocation returns the capture requestId parameter, used with
|
||||||
imageExposed(), imageCaptured(), imageMetadataAvailable() and imageSaved() signals.
|
imageExposed(), imageCaptured(), imageMetadataAvailable() and imageSaved() signals.
|
||||||
|
|
||||||
|
If the application is unable to write to the location specified by \c location
|
||||||
|
the CameraCapture will emit an error. The most likely reasons for the application
|
||||||
|
to be unable to write to a location is that the path is wrong and the location does not exists,
|
||||||
|
or the application does not have write permission for that location.
|
||||||
*/
|
*/
|
||||||
int QDeclarativeCameraCapture::captureToLocation(const QString &location)
|
int QDeclarativeCameraCapture::captureToLocation(const QString &location)
|
||||||
{
|
{
|
||||||
@@ -179,7 +185,6 @@ int QDeclarativeCameraCapture::captureToLocation(const QString &location)
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlmethod QtMultimedia5::CameraCapture::cancelCapture()
|
\qmlmethod QtMultimedia5::CameraCapture::cancelCapture()
|
||||||
\fn QDeclarativeCameraCapture::cancelCapture()
|
|
||||||
|
|
||||||
Cancel pending image capture requests.
|
Cancel pending image capture requests.
|
||||||
*/
|
*/
|
||||||
@@ -268,9 +273,11 @@ QString QDeclarativeCameraCapture::errorString() const
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlmethod QtMultimedia5::CameraCapture::setMetadata(key, value)
|
\qmlmethod QtMultimedia5::CameraCapture::setMetadata(key, value)
|
||||||
\fn QDeclarativeCameraCapture::setMetadata(const QString &key, const QVariant &value)
|
|
||||||
|
|
||||||
Sets a particular metadata \a key to \a value for the subsequent image captures.
|
Sets a particular metadata \a key to \a value for the subsequent image captures.
|
||||||
|
|
||||||
|
\sa QtMultimedia::MetaData
|
||||||
*/
|
*/
|
||||||
void QDeclarativeCameraCapture::setMetadata(const QString &key, const QVariant &value)
|
void QDeclarativeCameraCapture::setMetadata(const QString &key, const QVariant &value)
|
||||||
{
|
{
|
||||||
@@ -280,7 +287,6 @@ void QDeclarativeCameraCapture::setMetadata(const QString &key, const QVariant &
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::CameraCapture::onCaptureFailed(requestId, message)
|
\qmlsignal QtMultimedia5::CameraCapture::onCaptureFailed(requestId, message)
|
||||||
\fn QDeclarativeCameraCapture::captureFailed(int requestId, const QString &message)
|
|
||||||
|
|
||||||
This handler is called when an error occurs during capture with \a requestId.
|
This handler is called when an error occurs during capture with \a requestId.
|
||||||
A descriptive message is available in \a message.
|
A descriptive message is available in \a message.
|
||||||
@@ -288,18 +294,16 @@ void QDeclarativeCameraCapture::setMetadata(const QString &key, const QVariant &
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::CameraCapture::onImageCaptured(requestId, preview)
|
\qmlsignal QtMultimedia5::CameraCapture::onImageCaptured(requestId, preview)
|
||||||
\fn QDeclarativeCameraCapture::imageCaptured(int requestId, const QString &preview)
|
|
||||||
|
|
||||||
This handler is called when an image with \a requestId has been captured
|
This handler is called when an image with \a requestId has been captured
|
||||||
but not yet saved to the filesystem. The \a preview
|
but not yet saved to the filesystem. The \a preview
|
||||||
parameter can be used as the URL supplied to an Image element.
|
parameter can be used as the URL supplied to an \l Image.
|
||||||
|
|
||||||
\sa onImageSaved
|
\sa onImageSaved
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::CameraCapture::onImageSaved(requestId, path)
|
\qmlsignal QtMultimedia5::CameraCapture::onImageSaved(requestId, path)
|
||||||
\fn QDeclarativeCameraCapture::imageSaved(int requestId, const QString &path)
|
|
||||||
|
|
||||||
This handler is called after the image with \a requestId has been written to the filesystem.
|
This handler is called after the image with \a requestId has been written to the filesystem.
|
||||||
The \a path is a local file path, not a URL.
|
The \a path is a local file path, not a URL.
|
||||||
@@ -310,7 +314,6 @@ void QDeclarativeCameraCapture::setMetadata(const QString &key, const QVariant &
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::CameraCapture::onImageMetadataAvailable(requestId, key, value)
|
\qmlsignal QtMultimedia5::CameraCapture::onImageMetadataAvailable(requestId, key, value)
|
||||||
\fn QDeclarativeCameraCapture::imageMetadataAvailable(int requestId, const QString &key, const QVariant &value);
|
|
||||||
|
|
||||||
This handler is called when the image with \a requestId has new metadata
|
This handler is called when the image with \a requestId has new metadata
|
||||||
available with the key \a key and value \a value.
|
available with the key \a key and value \a value.
|
||||||
|
|||||||
@@ -46,18 +46,18 @@ QT_BEGIN_NAMESPACE
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlclass CameraExposure QDeclarativeCameraExposure
|
\qmlclass CameraExposure QDeclarativeCameraExposure
|
||||||
\brief The CameraExposure element provides interface for exposure related camera settings.
|
\brief The CameraExposure type provides interface for exposure related camera settings.
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup camera_qml
|
\ingroup camera_qml
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
|
|
||||||
This element is part of the \b{QtMultimedia 5.0} module.
|
This type is part of the \b{QtMultimedia 5.0} module.
|
||||||
|
|
||||||
This element allows you to adjust exposure related settings
|
CameraExposure allows you to adjust exposure related settings
|
||||||
like aperture and shutter speed, metering and ISO speed.
|
like aperture and shutter speed, metering and ISO speed.
|
||||||
|
|
||||||
It should not be constructed separately but provided by the
|
It should not be constructed separately, instead the
|
||||||
\l Camera element's \c exposure property.
|
\c exposure property of the a \l Camera should be used.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -95,7 +95,7 @@ QT_BEGIN_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\internal
|
\internal
|
||||||
\class QDeclarativeCameraExposure
|
\class QDeclarativeCameraExposure
|
||||||
\brief The CameraExposure element provides interface for exposure related camera settings.
|
\brief The CameraExposure provides interface for exposure related camera settings.
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|||||||
@@ -47,19 +47,19 @@ QT_BEGIN_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass CameraFlash QDeclarativeCameraFlash
|
\qmlclass CameraFlash QDeclarativeCameraFlash
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
\brief The CameraFlash element provides interface for flash related camera settings.
|
\brief The CameraFlash type provides interface for flash related camera settings.
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup camera_qml
|
\ingroup camera_qml
|
||||||
|
|
||||||
This element is part of the \b{QtMultimedia 5.0} module.
|
CameraFlash is part of the \b{QtMultimedia 5.0} module.
|
||||||
|
|
||||||
The CameraFlash element allows you to operate the camera flash
|
This type allows you to operate the camera flash
|
||||||
hardware and control the flash mode used. Not all cameras have
|
hardware and control the flash mode used. Not all cameras have
|
||||||
flash hardware (and in some cases it is shared with the
|
flash hardware (and in some cases it is shared with the
|
||||||
\l {Torch}{torch} hardware).
|
\l {Torch}{torch} hardware).
|
||||||
|
|
||||||
It should not be constructed separately but provided by the
|
It should not be constructed separately, instead the
|
||||||
\l Camera element's \c flash property.
|
\c flash property of a \l Camera should be used.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -78,7 +78,7 @@ QT_BEGIN_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\class QDeclarativeCameraFlash
|
\class QDeclarativeCameraFlash
|
||||||
\internal
|
\internal
|
||||||
\brief The CameraFlash element provides interface for flash related camera settings.
|
\brief The CameraFlash provides interface for flash related camera settings.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@@ -142,12 +142,15 @@ void QDeclarativeCameraFlash::setFlashMode(int mode)
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::CameraExposure::flashModeChanged(int)
|
\qmlsignal QtMultimedia5::CameraExposure::flashModeChanged(int)
|
||||||
\fn void QDeclarativeCameraFlash::flashModeChanged(int)
|
This signal is emitted when the \c flashMode property is changed.
|
||||||
|
The corresponding handler is \c onFlashModeChanged.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::CameraExposure::flashReady(bool)
|
\qmlsignal QtMultimedia5::CameraExposure::flashReady(bool)
|
||||||
\fn void QDeclarativeCameraFlash::flashReady(bool)
|
This signal is emitted when QCameraExposure indicates that
|
||||||
|
the flash is ready to use.
|
||||||
|
The corresponsing handler is \c onFlashReadyChanged.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|||||||
@@ -47,18 +47,18 @@ QT_BEGIN_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass CameraFocus QDeclarativeCameraFocus
|
\qmlclass CameraFocus QDeclarativeCameraFocus
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
\brief The CameraFocus element provides interface for focus related camera settings.
|
\brief The CameraFocus type provides interface for focus related camera settings.
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup camera_qml
|
\ingroup camera_qml
|
||||||
|
|
||||||
This element is part of the \b{QtMultimedia 5.0} module.
|
CameraFocus is part of the \b{QtMultimedia 5.0} module.
|
||||||
|
|
||||||
The CameraFocus element allows control over manual and automatic
|
This type allows control over manual and automatic
|
||||||
focus settings, including information about any parts of the
|
focus settings, including information about any parts of the
|
||||||
camera frame that are selected for autofocusing.
|
camera frame that are selected for autofocusing.
|
||||||
|
|
||||||
It is not constructed separately but is provided by the
|
It should not be constructed separately, instead the
|
||||||
\l Camera element's \c focus property.
|
\c focus property of a \l Camera should be used.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -74,7 +74,7 @@ QT_BEGIN_NAMESPACE
|
|||||||
focus {
|
focus {
|
||||||
focusMode: Camera.FocusMacro
|
focusMode: Camera.FocusMacro
|
||||||
focusPointMode: Camera.FocusPointCustom
|
focusPointMode: Camera.FocusPointCustom
|
||||||
customFocusPoint: Qt.point(0.2, 0.2) //focus to top-left corner
|
customFocusPoint: Qt.point(0.2, 0.2) // Focus relative to top-left corner
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -90,7 +90,7 @@ QT_BEGIN_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\class QDeclarativeCameraFocus
|
\class QDeclarativeCameraFocus
|
||||||
\internal
|
\internal
|
||||||
\brief The CameraFocus element provides interface for focus related camera settings.
|
\brief The CameraFocus provides interface for focus related camera settings.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@@ -133,7 +133,6 @@ QDeclarativeCamera::FocusMode QDeclarativeCameraFocus::focusMode() const
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlmethod bool QtMultimedia5::CameraFocus::isFocusModeSupported(mode) const
|
\qmlmethod bool QtMultimedia5::CameraFocus::isFocusModeSupported(mode) const
|
||||||
\fn QDeclarativeCameraFocus::isFocusModeSupported(QDeclarativeCamera::FocusMode mode) const
|
|
||||||
|
|
||||||
Returns true if the supplied \a mode is a supported focus mode, and
|
Returns true if the supplied \a mode is a supported focus mode, and
|
||||||
false otherwise.
|
false otherwise.
|
||||||
@@ -174,7 +173,6 @@ void QDeclarativeCameraFocus::setFocusPointMode(QDeclarativeCamera::FocusPointMo
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlmethod bool QtMultimedia5::CameraFocus::isFocusPointModeSupported(mode) const
|
\qmlmethod bool QtMultimedia5::CameraFocus::isFocusPointModeSupported(mode) const
|
||||||
\fn QDeclarativeCameraFocus::isFocusPointModeSupported(QDeclarativeCamera::FocusPointMode mode) const
|
|
||||||
|
|
||||||
Returns true if the supplied \a mode is a supported focus point mode, and
|
Returns true if the supplied \a mode is a supported focus point mode, and
|
||||||
false otherwise.
|
false otherwise.
|
||||||
|
|||||||
@@ -47,16 +47,16 @@ QT_BEGIN_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass CameraImageProcessing QDeclarativeCameraImageProcessing
|
\qmlclass CameraImageProcessing QDeclarativeCameraImageProcessing
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
\brief The CameraCapture element provides an interface for camera capture related settings
|
\brief The CameraImageProcessing type provides an interface for camera capture related settings
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup camera_qml
|
\ingroup camera_qml
|
||||||
|
|
||||||
The CameraImageProcessing element provides control over post-processing
|
CameraImageProcessing provides control over post-processing
|
||||||
done by the camera middleware, including white balance adjustments,
|
done by the camera middleware, including white balance adjustments,
|
||||||
contrast, saturation, sharpening, and denoising
|
contrast, saturation, sharpening, and denoising
|
||||||
|
|
||||||
It is not constructed separately but is provided by the \a Camera element's
|
It should not be constructed separately, instead the
|
||||||
\c imageProcessing property.
|
\c imageProcessing property of a \l Camera should be used.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -79,7 +79,7 @@ QT_BEGIN_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\class QDeclarativeCameraImageProcessing
|
\class QDeclarativeCameraImageProcessing
|
||||||
\internal
|
\internal
|
||||||
\brief The CameraCapture element provides an interface for camera capture related settings
|
\brief The CameraCapture provides an interface for camera capture related settings
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
@@ -233,10 +233,12 @@ void QDeclarativeCameraImageProcessing::setDenoisingLevel(qreal value)
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::Camera::whiteBalanceModeChanged(Camera::WhiteBalanceMode)
|
\qmlsignal QtMultimedia5::Camera::whiteBalanceModeChanged(Camera::WhiteBalanceMode)
|
||||||
|
This signal is emitted when the \c whiteBalanceMode property is changed.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::Camera::manualWhiteBalanceChanged(qreal)
|
\qmlsignal QtMultimedia5::Camera::manualWhiteBalanceChanged(qreal)
|
||||||
|
This signal is emitted when the \c manualWhiteBalance property is changed.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|||||||
@@ -49,15 +49,15 @@ QT_BEGIN_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass CameraRecorder QDeclarativeCameraRecorder
|
\qmlclass CameraRecorder QDeclarativeCameraRecorder
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
\brief The CameraRecorder element controls video recording with the Camera.
|
\brief The CameraRecorder type controls video recording with the Camera.
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup camera_qml
|
\ingroup camera_qml
|
||||||
|
|
||||||
This element allows recording camera streams to files, and adjusting recording
|
CameraRecorder allows recording camera streams to files, and adjusting recording
|
||||||
settings and metadata for videos.
|
settings and metadata for videos.
|
||||||
|
|
||||||
This element is a child of a \l Camera element (as the \c videoRecorder property)
|
It should not be constructed separately, instead the
|
||||||
and cannot be created directly.
|
\c videRecorder property of a \l Camera should be used.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
Camera {
|
Camera {
|
||||||
@@ -237,7 +237,7 @@ int QDeclarativeCameraRecorder::audioSampleRate() const
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty enumeration QtMultimedia5::CameraRecorder::videoEncodingMode
|
\qmlproperty enumeration QtMultimedia5::CameraRecorder::videoEncodingMode
|
||||||
|
|
||||||
The type of encoding method to use when recording audio.
|
The type of encoding method to use when recording video.
|
||||||
|
|
||||||
\table
|
\table
|
||||||
\header \li Value \li Description
|
\header \li Value \li Description
|
||||||
|
|||||||
@@ -47,12 +47,12 @@ QT_BEGIN_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass Radio QDeclarativeRadio
|
\qmlclass Radio QDeclarativeRadio
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
\brief The Radio element allows you to access radio functionality from a QML application.
|
\brief The Radio type allows you to access radio functionality from a QML application.
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup multimedia_radio_qml
|
\ingroup multimedia_radio_qml
|
||||||
\inherits Item
|
\inherits Item
|
||||||
|
|
||||||
This element is part of the \b{QtMultimedia 5.0} module.
|
Radio is part of the \b{QtMultimedia 5.0} module.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -85,12 +85,12 @@ QT_BEGIN_NAMESPACE
|
|||||||
}
|
}
|
||||||
\endqml
|
\endqml
|
||||||
|
|
||||||
You can use the \c Radio element to tune the radio and get information about the signal.
|
You can use \c Radio to tune the radio and get information about the signal.
|
||||||
You can also use the Radio element to get information about tuning, for instance the
|
You can also use the Radio to get information about tuning, for instance the
|
||||||
frequency steps supported for tuning.
|
frequency steps supported for tuning.
|
||||||
|
|
||||||
The corresponding \l RadioData element gives RDS information about the
|
The corresponding \l RadioData gives RDS information about the
|
||||||
current radio station. The best way to access the RadioData element for
|
current radio station. The best way to access the RadioData for
|
||||||
the current Radio is to use the \c radioData property.
|
the current Radio is to use the \c radioData property.
|
||||||
|
|
||||||
\sa {Radio Overview}
|
\sa {Radio Overview}
|
||||||
@@ -129,7 +129,7 @@ QDeclarativeRadio::~QDeclarativeRadio()
|
|||||||
/*!
|
/*!
|
||||||
\qmlproperty enumeration QtMultimedia5::Radio::state
|
\qmlproperty enumeration QtMultimedia5::Radio::state
|
||||||
|
|
||||||
This property holds the current state of the Radio element.
|
This property holds the current state of the Radio.
|
||||||
|
|
||||||
\table
|
\table
|
||||||
\header \li Value \li Description
|
\header \li Value \li Description
|
||||||
@@ -540,7 +540,7 @@ void QDeclarativeRadio::_q_availabilityChanged(QtMultimedia::AvailabilityError e
|
|||||||
if \l searchAllStations is called with \c SearchGetStationId.
|
if \l searchAllStations is called with \c SearchGetStationId.
|
||||||
|
|
||||||
The \a frequency is returned in Hertz, and the \a stationId corresponds to the station Id
|
The \a frequency is returned in Hertz, and the \a stationId corresponds to the station Id
|
||||||
in the \l RadioData element for this radio station.
|
in the \l RadioData for this radio station.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|||||||
@@ -46,16 +46,16 @@ QT_BEGIN_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass RadioData QDeclarativeRadioData
|
\qmlclass RadioData QDeclarativeRadioData
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
\brief The RadioData element allows you to access RDS data from a QML application.
|
\brief The RadioData type allows you to access RDS data from a QML application.
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup multimedia_radio_qml
|
\ingroup multimedia_radio_qml
|
||||||
\inherits Item
|
\inherits Item
|
||||||
|
|
||||||
This element is part of the \b{QtMultimedia 5.0} module.
|
This type is part of the \b{QtMultimedia 5.0} module.
|
||||||
|
|
||||||
The \c RadioData element is your gateway to all the data available through RDS. RDS is the Radio Data System
|
\c RadioData is your gateway to all the data available through RDS. RDS is the Radio Data System
|
||||||
which allows radio stations to broadcast information like the \l stationId, \l programType, \l programTypeName,
|
which allows radio stations to broadcast information like the \l stationId, \l programType, \l programTypeName,
|
||||||
\l stationName, and \l radioText. This information can be read from the \c RadioData element. It also allows
|
\l stationName, and \l radioText. This information can be read from the \c RadioData. It also allows
|
||||||
you to set whether the radio should tune to alternative frequencies if the current signal strength falls too much.
|
you to set whether the radio should tune to alternative frequencies if the current signal strength falls too much.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
@@ -88,11 +88,11 @@ QT_BEGIN_NAMESPACE
|
|||||||
|
|
||||||
\endqml
|
\endqml
|
||||||
|
|
||||||
You use \c RadioData together with the \l Radio element, either by
|
You use \c RadioData together with a \l Radio, either by
|
||||||
accessing the \c radioData property of the Radio element, or
|
accessing the \c radioData property of the Radio, or
|
||||||
creating a separate RadioData element. The properties of the
|
creating a separate RadioData. The properties of the
|
||||||
RadioData element will reflect the information broadcast by the
|
RadioData type will reflect the information broadcast by the
|
||||||
radio station the Radio element is currently tuned to.
|
radio station the Radio is currently tuned to.
|
||||||
|
|
||||||
\sa {Radio Overview}
|
\sa {Radio Overview}
|
||||||
*/
|
*/
|
||||||
@@ -299,7 +299,7 @@ void QDeclarativeRadioData::connectSignals()
|
|||||||
SIGNAL(alternativeFrequenciesEnabledChanged(bool)));
|
SIGNAL(alternativeFrequenciesEnabledChanged(bool)));
|
||||||
|
|
||||||
// Note we map availabilityError->availability
|
// Note we map availabilityError->availability
|
||||||
// Since the radio data element depends on the service for the tuner, the availability is also dictated from the tuner
|
// Since the radio data type depends on the service for the tuner, the availability is also dictated from the tuner
|
||||||
connect(m_radioTuner, SIGNAL(availabilityErrorChanged(QtMultimedia::AvailabilityError)), this, SLOT(_q_availabilityChanged(QtMultimedia::AvailabilityError)));
|
connect(m_radioTuner, SIGNAL(availabilityErrorChanged(QtMultimedia::AvailabilityError)), this, SLOT(_q_availabilityChanged(QtMultimedia::AvailabilityError)));
|
||||||
|
|
||||||
connect(m_radioData, SIGNAL(error(QRadioData::Error)), this, SLOT(_q_error(QRadioData::Error)));
|
connect(m_radioData, SIGNAL(error(QRadioData::Error)), this, SLOT(_q_error(QRadioData::Error)));
|
||||||
|
|||||||
@@ -49,11 +49,11 @@ QT_BEGIN_NAMESPACE
|
|||||||
/*!
|
/*!
|
||||||
\qmlclass Torch QDeclarativeTorch
|
\qmlclass Torch QDeclarativeTorch
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
\brief The Torch element provides simple control over torch functionality
|
\brief The Torch type provides simple control over torch functionality
|
||||||
|
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
|
|
||||||
This element is part of the \b{QtMultimedia 5.0} module.
|
\c Torch is part of the \b{QtMultimedia 5.0} module.
|
||||||
|
|
||||||
In many cases the torch hardware is shared with camera flash functionality,
|
In many cases the torch hardware is shared with camera flash functionality,
|
||||||
and might be automatically controlled by the device. You have control over
|
and might be automatically controlled by the device. You have control over
|
||||||
|
|||||||
@@ -52,13 +52,13 @@ QT_BEGIN_NAMESPACE
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlclass VideoOutput QDeclarativeVideoOutput
|
\qmlclass VideoOutput QDeclarativeVideoOutput
|
||||||
\brief The VideoOutput element allows you to render video or camera viewfinder.
|
\brief The VideoOutput type allows you to render video or camera viewfinder.
|
||||||
|
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup multimedia_video_qml
|
\ingroup multimedia_video_qml
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
|
|
||||||
This element is part of the \b{QtMultimedia 5.0} module.
|
\c VideoOutput is part of the \b{QtMultimedia 5.0} module.
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
@@ -105,7 +105,7 @@ QT_BEGIN_NAMESPACE
|
|||||||
|
|
||||||
If it is likely that an application will be playing video for an extended
|
If it is likely that an application will be playing video for an extended
|
||||||
period of time without user interaction it may be necessary to disable
|
period of time without user interaction it may be necessary to disable
|
||||||
the platform's screen saver. The \l ScreenSaver element (from \l QtSystemInfo)
|
the platform's screen saver. The \l ScreenSaver (from \l QtSystemInfo)
|
||||||
may be used to disable the screensaver in this fashion:
|
may be used to disable the screensaver in this fashion:
|
||||||
|
|
||||||
\qml
|
\qml
|
||||||
@@ -411,8 +411,8 @@ void QDeclarativeVideoOutput::setOrientation(int orientation)
|
|||||||
|
|
||||||
This property holds the item coordinates of the area that
|
This property holds the item coordinates of the area that
|
||||||
would contain video to render. With certain fill modes,
|
would contain video to render. With certain fill modes,
|
||||||
this rectangle will be larger than the visible area of this
|
this rectangle will be larger than the visible area of the
|
||||||
element.
|
\c VideoOutput.
|
||||||
|
|
||||||
This property is useful when other coordinates are specified
|
This property is useful when other coordinates are specified
|
||||||
in terms of the source dimensions - this applied for relative
|
in terms of the source dimensions - this applied for relative
|
||||||
|
|||||||
@@ -51,14 +51,14 @@ QT_BEGIN_NAMESPACE
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlclass SoundEffect QSoundEffect
|
\qmlclass SoundEffect QSoundEffect
|
||||||
\brief The SoundEffect element provides a way to play sound effects in QML.
|
\brief The SoundEffect type provides a way to play sound effects in QML.
|
||||||
|
|
||||||
\inmodule QtMultimedia
|
\inmodule QtMultimedia
|
||||||
\ingroup multimedia_qml
|
\ingroup multimedia_qml
|
||||||
\ingroup multimedia_audio_qml
|
\ingroup multimedia_audio_qml
|
||||||
\inqmlmodule QtMultimedia 5
|
\inqmlmodule QtMultimedia 5
|
||||||
|
|
||||||
This element is part of the \b{QtMultimedia 5.0} module.
|
SoundEffect is part of the \b{QtMultimedia 5.0} module.
|
||||||
|
|
||||||
The following example plays a WAV file on mouse click.
|
The following example plays a WAV file on mouse click.
|
||||||
|
|
||||||
@@ -85,7 +85,7 @@ QT_BEGIN_NAMESPACE
|
|||||||
\enum QSoundEffect::Status
|
\enum QSoundEffect::Status
|
||||||
|
|
||||||
\value Null No source has been set or the source is null.
|
\value Null No source has been set or the source is null.
|
||||||
\value Loading The soundeffect is trying to load the source.
|
\value Loading The SoundEffect is trying to load the source.
|
||||||
\value Ready The source is loaded and ready for play.
|
\value Ready The source is loaded and ready for play.
|
||||||
\value Error An error occurred during operation, such as failure of loading the source.
|
\value Error An error occurred during operation, such as failure of loading the source.
|
||||||
|
|
||||||
@@ -95,7 +95,10 @@ QT_BEGIN_NAMESPACE
|
|||||||
\qmlproperty url QtMultimedia5::SoundEffect::source
|
\qmlproperty url QtMultimedia5::SoundEffect::source
|
||||||
\property QSoundEffect::source
|
\property QSoundEffect::source
|
||||||
|
|
||||||
This property provides a way to control the sound to play.
|
This property provides a way to control the sound to play. For the SoundEffect
|
||||||
|
to attempt to load the source, the URL must exist and the application must have read permission
|
||||||
|
in the specified directory. If the desired source is a local file the URL may be specified
|
||||||
|
using either absolute or relative (to the file that declared the SoundEffect) pathing.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@@ -118,7 +121,6 @@ QT_BEGIN_NAMESPACE
|
|||||||
\property QSoundEffect::volume
|
\property QSoundEffect::volume
|
||||||
|
|
||||||
This property holds the volume of the playback, from 0.0 (silent) to 1.0 (maximum volume).
|
This property holds the volume of the playback, from 0.0 (silent) to 1.0 (maximum volume).
|
||||||
Note: Currently this has no effect on Mac OS X.
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@@ -132,18 +134,20 @@ QT_BEGIN_NAMESPACE
|
|||||||
\qmlproperty bool QtMultimedia5::SoundEffect::playing
|
\qmlproperty bool QtMultimedia5::SoundEffect::playing
|
||||||
\property QSoundEffect::playing
|
\property QSoundEffect::playing
|
||||||
|
|
||||||
This property indicates if the soundeffect is playing or not.
|
This property indicates whether the sound effect is playing or not.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlproperty enumeration QtMultimedia5::SoundEffect::status
|
\qmlproperty enumeration QtMultimedia5::SoundEffect::status
|
||||||
|
|
||||||
This property indicates the following status of the soundeffect.
|
This property indicates the current status of the SoundEffect
|
||||||
|
as enumerated within SoundEffect.
|
||||||
|
Possible statuses are listed below.
|
||||||
|
|
||||||
\table
|
\table
|
||||||
\header \li Value \li Description
|
\header \li Value \li Description
|
||||||
\row \li SoundEffect.Null \li No source has been set or the source is null.
|
\row \li SoundEffect.Null \li No source has been set or the source is null.
|
||||||
\row \li SoundEffect.Loading \li The soundeffect is trying to load the source.
|
\row \li SoundEffect.Loading \li The SoundEffect is trying to load the source.
|
||||||
\row \li SoundEffect.Ready \li The source is loaded and ready for play.
|
\row \li SoundEffect.Ready \li The source is loaded and ready for play.
|
||||||
\row \li SoundEffect.Error \li An error occurred during operation, such as failure of loading the source.
|
\row \li SoundEffect.Error \li An error occurred during operation, such as failure of loading the source.
|
||||||
\endtable
|
\endtable
|
||||||
@@ -153,55 +157,80 @@ QT_BEGIN_NAMESPACE
|
|||||||
\qmlsignal QtMultimedia5::SoundEffect::sourceChanged()
|
\qmlsignal QtMultimedia5::SoundEffect::sourceChanged()
|
||||||
\fn void QSoundEffect::sourceChanged()
|
\fn void QSoundEffect::sourceChanged()
|
||||||
|
|
||||||
This handler is called when the source has changed.
|
The \c sourceChanged signal is emitted when the source has been changed.
|
||||||
|
|
||||||
|
The corresponding handler is \c onSourceChanged.
|
||||||
*/
|
*/
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::SoundEffect::loadedChanged()
|
\qmlsignal QtMultimedia5::SoundEffect::loadedChanged()
|
||||||
\fn void QSoundEffect::loadedChanged()
|
\fn void QSoundEffect::loadedChanged()
|
||||||
|
|
||||||
This handler is called when the loading state has changed.
|
The \c loadedChanged signal is emitted when the loading state has changed.
|
||||||
|
|
||||||
|
The corresponding handler is \c onLoadedChanged.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::SoundEffect::loopCountChanged()
|
\qmlsignal QtMultimedia5::SoundEffect::loopCountChanged()
|
||||||
\fn void QSoundEffect::loopCountChanged()
|
\fn void QSoundEffect::loopCountChanged()
|
||||||
|
|
||||||
This handler is called when the initial number of loops has changed.
|
The \c loopCountChanged signal is emitted when the initial number of loops has changed.
|
||||||
|
|
||||||
|
The corresponding handler is \c onLoopCountChanged.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::SoundEffect::loopsRemainingChanged()
|
\qmlsignal QtMultimedia5::SoundEffect::loopsRemainingChanged()
|
||||||
\fn void QSoundEffect::loopsRemainingChanged()
|
\fn void QSoundEffect::loopsRemainingChanged()
|
||||||
|
|
||||||
This handler is called when the remaining number of loops has changed.
|
The \c loopsRemainingChanged signal is emitted when the remaining number of loops has changed.
|
||||||
|
|
||||||
|
The corresponding handler is \c onLoopsRemainingChanged.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::SoundEffect::volumeChanged()
|
\qmlsignal QtMultimedia5::SoundEffect::volumeChanged()
|
||||||
\fn void QSoundEffect::volumeChanged()
|
\fn void QSoundEffect::volumeChanged()
|
||||||
|
|
||||||
This handler is called when the volume has changed.
|
The \c volumeChanged signal is emitted when the volume has changed.
|
||||||
|
|
||||||
|
The corresponding handler is \c onVolumeChanged.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::SoundEffect::mutedChanged()
|
\qmlsignal QtMultimedia5::SoundEffect::mutedChanged()
|
||||||
\fn void QSoundEffect::mutedChanged()
|
\fn void QSoundEffect::mutedChanged()
|
||||||
|
|
||||||
This handler is called when the mute state has changed.
|
The \c mutedChanged signal is emitted when the mute state has changed.
|
||||||
|
|
||||||
|
The corresponding handler is \c onMutedChanged.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::SoundEffect::playingChanged()
|
\qmlsignal QtMultimedia5::SoundEffect::playingChanged()
|
||||||
\fn void QSoundEffect::playingChanged()
|
\fn void QSoundEffect::playingChanged()
|
||||||
|
|
||||||
This handler is called when the playing property has changed.
|
The \c playingChanged signal is emitted when the playing property has changed.
|
||||||
|
|
||||||
|
The corresponding handler is \c onPlayingChanged.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlsignal QtMultimedia5::SoundEffect::statusChanged()
|
\qmlsignal QtMultimedia5::SoundEffect::statusChanged()
|
||||||
\fn void QSoundEffect::statusChanged()
|
\fn void QSoundEffect::statusChanged()
|
||||||
|
|
||||||
This handler is called when the status property has changed.
|
The \c statusChanged signal is emitted when the status property has changed.
|
||||||
|
|
||||||
|
The corresponding handler is \c onStatusChanged.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*!
|
||||||
|
\qmlsignal QtMultimedia5::SoundEffect::categoryChanged()
|
||||||
|
\fn void QSoundEffect::categoryChanged()
|
||||||
|
|
||||||
|
The \c categoryChanged signal is emitted when the category property has changed.
|
||||||
|
|
||||||
|
The corresponding handler is \c onCategoryChanged.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
@@ -421,12 +450,19 @@ void QSoundEffect::setCategory(const QString &category)
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
\qmlmethod QtMultimedia5::SoundEffect::stop()
|
\qmlmethod QtMultimedia5::SoundEffect::stop()
|
||||||
\fn QSoundEffect::stop()
|
|
||||||
|
|
||||||
Stop current playback.
|
Stop current playback.
|
||||||
|
|
||||||
Note that if the backend is PulseAudio, due to the limitation of the underlying API,
|
Note that if the backend is PulseAudio, due to the limitation of the underlying API,
|
||||||
tis stop will only prevent next looping but will not be able to stop current playback immediately.
|
calling stop will only prevent next looping but will not be able to stop current playback immediately.
|
||||||
|
|
||||||
|
*/
|
||||||
|
/*!
|
||||||
|
\fn QSoundEffect::stop()
|
||||||
|
Stop current playback.
|
||||||
|
|
||||||
|
Note that if the backend is PulseAudio, due to the limitation of the underlying API,
|
||||||
|
calling stop will only prevent next looping but will not be able to stop current playback immediately.
|
||||||
|
|
||||||
*/
|
*/
|
||||||
void QSoundEffect::stop()
|
void QSoundEffect::stop()
|
||||||
|
|||||||
Reference in New Issue
Block a user