Attempt to represent the S^2->S^3 header reorganisation as a series of "hg rename" operations
1 // Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
14 // Mda\Common\MmfVideo.h
18 #ifndef __MMF_COMMON_VIDEO_H__
19 #define __MMF_COMMON_VIDEO_H__
21 #include <mmf/common/mmfutilities.h>
29 The use of this constant as either a parameter for
30 CVideoRecorderUtility::SetVideoBitRateL or as a return value from
31 CVideoRecorderUtility::VideoBitRateL signifies that a variable
32 video bit rate is being used.
34 const TInt KMMFVariableVideoBitRate = -1;
40 CVideoRecorderUtility::SetMaxClipSizeL can take this constant
41 instead of a byte value. This signifies there should be no max
44 const TInt KMMFNoMaxClipSize = -1;
50 CVideoPlayerUtility/CVideoRecorderUtility HandleEvent() code :
51 the video source file has been successfully opened
53 const TUid KMMFEventCategoryVideoOpenComplete = {0x101F7F85};
59 The unique identifier for the event that indicates that the video has been prepared for recording.
61 const TUid KMMFEventCategoryVideoPrepareComplete = {0x101F7F86};
67 const TUid KMMFEventCategoryVideoLoadingStarted = {0x101F7F87};
73 const TUid KMMFEventCategoryVideoLoadingComplete = {0x101F7F88};
79 const TUid KMMFEventCategoryVideoPlayerGeneralError = {0x101F8000};
85 const TUid KMMFEventCategoryVideoRecorderGeneralError = {0x101F8001};
92 Defines an absolute rotation in 90 degree increments
99 EVideoRotationClockwise90,
100 EVideoRotationClockwise180,
101 EVideoRotationClockwise270
108 Class used when sending custom commands from the client API
109 to the video controller to get or set the video configuration.
111 class TMMFVideoConfig
114 inline TMMFVideoConfig();
118 A flag indicating whether audio output is enabled. ETrue if teh audio is to be enabled, false if
123 The location of the top left corner of the video window.
127 Defines the rectangle in which the video clip will be played.
131 A handle to the bitmap into which the decoded frame(s) are put.
135 The current frame number in the video clip.
139 The number of frames per second; may not be an integer.
141 TReal32 iFramesPerSecond;
143 The width & height of the video frame.
145 TSize iVideoFrameSize;
147 The volume setting of the video device.
149 Should be between 0 and iMaxVolume.
153 The maximum volume setting of the video device.
155 This value is platform dependent but is always greater than or equal to one. This is the maximum
156 value that should be passed to iVolume.
160 The balance of the audio channels for the video device. Zero for normal balance.
164 The gain of the audio channels for the video device. This can be any value from zero to
169 The maximum gain of the audio channels for the video device.
175 Meta data is often contained in the header of multimedia clips and is used to define attributes
176 such as the author and copyright details.
180 Set the maximum size of the recording, in bytes.
184 The number of channels (mono/stereo) that can be read by the video device.
188 The video bit rate of the video device.
192 The audio bit rate of the video device.
196 The unique identifier of the video format handled by the video device.
200 The video data type represented as a fourCC code.
204 The audio data type represented as a fourCC code.
208 The period over which the volume is to rise.
210 TTimeIntervalMicroSeconds iRampDuration;
212 The start position for playback in micro seconds.
214 TTimeIntervalMicroSeconds iStartPosition;
216 The end position for playback in micro seconds.
218 TTimeIntervalMicroSeconds iEndPosition;
220 The (possibly estimated) record time left in the clip.
222 TTimeIntervalMicroSeconds iRecordTimeAvailable;
224 Handle to the bitmap of the current video frame.
226 Used by RMMFVideoPlayControllerCustomCommands::GetFrame()
227 to pass a bitmap handle to the video controller.
229 TInt iFrameBitmapServerHandle;
231 Defines the window in which the video clip will be played.
235 A handle to the video camera being used.
239 Whether the video display is active
243 The percentage of loading/rebuffering completed.
245 TInt iLoadingCompletePercentage;
249 TVideoRotation iVideoRotation;
251 The percentage (100 = original size) by which the width of the video image is scaled.
253 TReal32 iWidthScalePercentage;
255 The percentage (100 = original size) by which the height of the video image is scaled.
257 TReal32 iHeightScalePercentage;
259 A boolean indicating if anti-aliasing filtering should be used.
261 TBool iAntiAliasFiltering;
263 The crop region currently applied to the image.
265 TRect iCropRectangle;
268 This member is internal and not intended for use.
276 Initialises the object with arbitrary values.
278 inline TMMFVideoConfig::TMMFVideoConfig() {};
284 Interface class to provide a callback to the video controller
285 custom command interface from the controller plug-in
286 (the object that implements the video record controller interface
287 MMMFVideoPlayControllerCustomCommandImplementor) when a GetFrame()
288 request has been issued.
290 @see RMMFVideoPlayControllerCustomCommands::GetFrame()
292 class MMMFVideoFrameMessage
296 Called when a frame has been successfully decoded.
299 The result code to be given to the client.
301 virtual void FrameReady(TInt aError) = 0;
303 Returns the decoded frame as a bitmap.
305 @return A reference to the video frame.
307 virtual CFbsBitmap& GetBitmap() = 0;
314 Represents the video aspect ratio as a fraction: iNumerator/iDenominator.
316 class TVideoAspectRatio
320 Aspect ratio numerator.
325 Aspect ratio denominator.
330 Constructs a default aspect ratio object. The default aspect ratio is
333 inline TVideoAspectRatio();
336 Constructs an aspect ratio object from a numerator and a denominator.
339 Aspect ratio numerator.
341 Aspect ratio denominator.
343 inline TVideoAspectRatio(TInt aNumerator, TInt aDenominator);
346 Compares two aspect ratio object for equality. The objects are
347 considered equal if the numerator and denominator match.
348 Note that the implementation will not attempt to reduce the fractions
351 inline TBool operator==(const TVideoAspectRatio& aAspectRatio) const;
354 Compares two aspect ratio object for equality. The objects are
355 considered inequal if either the numerators or the denominators differ.
356 Note that the implementation will not attempt to reduce the fractions
359 inline TBool operator!=(const TVideoAspectRatio& aAspectRatio) const;
362 inline TVideoAspectRatio::TVideoAspectRatio()
363 : iNumerator(1),iDenominator(1)
367 inline TVideoAspectRatio::TVideoAspectRatio(TInt aNumerator, TInt aDenominator)
368 : iNumerator(aNumerator),iDenominator(aDenominator)
372 inline TBool TVideoAspectRatio::operator==(const TVideoAspectRatio& aAspectRatio) const
374 return ((iNumerator == aAspectRatio.iNumerator) && (iDenominator == aAspectRatio.iDenominator));
377 inline TBool TVideoAspectRatio::operator!=(const TVideoAspectRatio& aAspectRatio) const
379 return ((iNumerator != aAspectRatio.iNumerator) || (iDenominator != aAspectRatio.iDenominator));
383 Video playback rate capabilities. This structure defines playback rate
384 capabilities for the current controller and video clip, and can be used
385 to determine if fast forward, rewind, step forward, or step backward
391 @see CVideoPlayerUtility::GetPlayRateCapabilitiesL, CVideoPlayerUtility::SetPlayVelocityL
393 class TVideoPlayRateCapabilities
397 ETrue if fast or slow play forward is possible (i.e. playback
398 velocity 1-99 or 101-). Normal play forward (velocity 100) is
399 supported by default.
404 ETrue if play backward is possible (i.e. playback velocity below0).
405 This includes normal speed, slow, and fast reverse playback.
409 /** ETrue if step forward is possible */
412 /** Etrue if step backward is possible */
417 Automatic scaling type.
422 @see CVideoPlayerUtility::SetAutoScaleL
426 /** No automatic scaling */
430 Best fit: The picture is scaled to fit the window without
431 clipping while maintaining aspect ratio. If window and
432 picture aspect ratios do not match, window background color
433 is used to fill the borders.
438 Clip: The picture is scaled to fit in the window, scaled in both
439 directions while maintaining aspect ratio. If window and
440 picture aspect ratios do not match, some of the video
441 picture will be clipped.
446 Stretch: The picture is scaled to fit in the window without
447 maintaining aspect ratio. If window and picture aspect
448 ratios do not match, the picture will be distorted.
454 Horizontal alignment for automatic scaling.
461 enum THorizontalAlign
463 /** The picture is horizontally centered */
464 EHorizontalAlignCenter = 0x70000000,
465 /** The picture is left-aligned */
466 EHorizontalAlignLeft,
467 /** The picture is right-aligned */
468 EHorizontalAlignRight
472 Vertical alignment for automatic scaling.
481 /** The picture is vertically centered */
482 EVerticalAlignCenter = 0x70000000,
483 /** The picture is top-aligned */
485 /** The picture is bottom-aligned */
495 @see CVideoPlayerUtility::SetVideoQualityL
499 EVideoQualityLow = 25,
500 EVideoQualityNormal = 50,
501 EVideoQualityHigh = 75,
502 EVideoQualityLossless = 100