/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
using System;
using System.Runtime.InteropServices;
/// <summary>
/// Gets the size allocated for the audio input buffer.
/// </summary>
- /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed of.</exception>
public int GetBufferSize()
{
AudioIOUtil.ThrowIfError(AudioInput.GetBufferSize(_handle, out var size));
/// Prepares the AudioCapture for reading audio data by starting buffering of audio data from the device.
/// </summary>
/// <exception cref="InvalidOperationException">
- /// Operation failed due to internal error.\n
+ /// Operation failed due to an internal error.\n
/// -or-\n
/// The current state is not <see cref="AudioIOState.Idle"/>.
/// </exception>
/// Unprepares the AudioCapture.
/// </summary>
/// <exception cref="InvalidOperationException">
- /// Operation failed due to internal error.\n
+ /// Operation failed due to an internal error.\n
/// -or-\n
/// The current state is <see cref="AudioIOState.Idle"/>.
/// </exception>
/// </summary>
/// <param name="streamPolicy">The <see cref="AudioStreamPolicy"/> to apply for the AudioCapture.</param>
/// <exception cref="ArgumentNullException"><paramref name="streamPolicy"/> is null.</exception>
- /// <exception cref="ObjectDisposedException"><paramref name="streamPolicy"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException"><paramref name="streamPolicy"/> has already been disposed of.</exception>
/// <exception cref="NotSupportedException"><paramref name="streamPolicy"/> is not supported.</exception>
/// <exception cref="ArgumentException">Not able to retrieve information from <paramref name="streamPolicy"/>.</exception>
public void ApplyStreamPolicy(AudioStreamPolicy streamPolicy)
}
/// <summary>
- /// Provides the ability to record audio from system audio input devices in synchronous way.
+ /// Provides the ability to record audio from system audio input devices in a synchronous way.
/// </summary>
/// <privilege>http://tizen.org/privilege/recorder</privilege>
public class AudioCapture : AudioCaptureBase
{
/// <summary>
- /// Initializes a new instance of the AudioCapture class with the specified sample rate, channel and sampleType.
+ /// Initializes a new instance of the AudioCapture class with the specified sample rate, channel, and sampleType.
/// </summary>
- /// <param name="sampleRate">The audio sample rate.(8000 ~ 48000Hz)</param>
+ /// <param name="sampleRate">The audio sample rate (8000 ~ 48000Hz).</param>
/// <param name="channel">The audio channel type.</param>
/// <param name="sampleType">The audio sample type.</param>
/// <exception cref="ArgumentOutOfRangeException">
}
/// <summary>
- /// Provides the ability to record audio from system audio input devices in asynchronous way.
+ /// Provides the ability to record audio from system audio input devices in an asynchronous way.
/// </summary>
/// <privilege>http://tizen.org/privilege/recorder</privilege>
public class AsyncAudioCapture : AudioCaptureBase
/// <summary>
/// Initializes a new instance of the AsyncAudioCapture class with the specified sample rate, channel and sampleType.
/// </summary>
- /// <param name="sampleRate">The audio sample rate.(8000 ~ 48000Hz)</param>
+ /// <param name="sampleRate">The audio sample rate (8000 ~ 48000Hz).</param>
/// <param name="channel">The audio channel type.</param>
/// <param name="sampleType">The audio sample type.</param>
/// <exception cref="ArgumentOutOfRangeException">
/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
using System;
/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
using Tizen.Internals.Errors;
}
/// <summary>
- /// Specifies the states for the <see cref="AudioPlayback"/>, <see cref="AudioCapture"/> and <see cref="AsyncAudioCapture"/>.
+ /// Specifies the states for the <see cref="AudioPlayback"/>, <see cref="AudioCapture"/>, and <see cref="AsyncAudioCapture"/>.
/// </summary>
public enum AudioIOState
{
}
/// <summary>
- /// Enumeration for audio sample type.
+ /// Specifies the audio sample types.
/// </summary>
public enum AudioSampleType
{
/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
using System;
namespace Tizen.Multimedia
{
/// <summary>
- /// Provides data for the <see cref="AudioCaptureBase.StateChanged"/> event and <see cref="AudioPlayback.StateChanged"/>.
+ /// Provides data for the <see cref="AudioCaptureBase.StateChanged"/> event and the <see cref="AudioPlayback.StateChanged"/> event.
/// </summary>
public class AudioIOStateChangedEventArgs : EventArgs
{
public AudioIOState Current { get; }
/// <summary>
- /// Gets the value indicating whether the state is changed by policy or not.
+ /// Gets the value indicating whether the state is changed by a policy or not.
/// </summary>
public bool ByPolicy { get; }
}
/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
using System;
using System.Diagnostics;
/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
using System;
using static Interop.AudioIO;
namespace Tizen.Multimedia
{
/// <summary>
- /// Provides the ability to directly manage the system audio output devices and play PCM (pulse-code modulation) data.
+ /// Provides the ability to directly manage the system audio output devices and play the PCM (pulse-code modulation) data.
/// </summary>
public class AudioPlayback : IDisposable
{
#region Event
/// <summary>
- /// Occurs when audio playback data can be written.
+ /// Occurs when the audio playback data can be written.
/// </summary>
/// <seealso cref="Write(byte[])"/>
public event EventHandler<AudioPlaybackBufferAvailableEventArgs> BufferAvailable;
#endregion
/// <summary>
- /// Initializes a new instance of the AudioPlayback class with the specified sample rate, channel and sample type.
+ /// Initializes a new instance of the AudioPlayback class with the specified sample rate, channel, and sample type.
/// </summary>
- /// <param name="sampleRate">The audio sample rate.(8000 ~ 48000Hz)</param>
+ /// <param name="sampleRate">The audio sample rate (8000 ~ 48000Hz).</param>
/// <param name="channel">The audio channel type.</param>
/// <param name="sampleType">The audio sample type.</param>
/// <exception cref="ArgumentOutOfRangeException">
/// <summary>
/// Gets the sound type supported by the audio output device.
/// </summary>
- /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed of.</exception>
public AudioStreamType StreamType
{
get
/// <summary>
/// Gets the size allocated for the audio output buffer.
/// </summary>
- /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed of.</exception>
public int GetBufferSize()
{
AudioIOUtil.ThrowIfError(AudioOutput.GetBufferSize(_handle, out var size));
}
/// <summary>
- /// Drains buffered audio data from the output stream.
- /// It blocks the calling thread until draining the stream buffer completely. (e.g. end of playback)
+ /// Drains the buffered audio data from the output stream.
+ /// It blocks the calling thread until the drain of the stream buffer is complete, for example, at the end of playback.
/// </summary>
- /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed of.</exception>
/// <exception cref="InvalidOperationException">The current state is <see cref="AudioIOState.Idle"/>.</exception>
public void Drain()
{
/// <exception cref="ArgumentNullException"><paramref name="buffer"/> is null.</exception>
/// <exception cref="ArgumentException">The length of <paramref name="buffer"/> is zero.</exception>
/// <exception cref="InvalidOperationException">The current state is not <see cref="AudioIOState.Running"/>.</exception>
- /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed of.</exception>
public int Write(byte[] buffer)
{
ValidateState(AudioIOState.Running);
/// This must be called before <see cref="Write(byte[])"/>.
/// </remarks>
/// <exception cref="InvalidOperationException">
- /// Operation failed due to internal error.\n
+ /// Operation failed due to an internal error.\n
/// -or-\n
/// The current state is not <see cref="AudioIOState.Idle"/>.
/// </exception>
- /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed of.</exception>
/// <seealso cref="Unprepare"/>
public void Prepare()
{
/// Unprepares the AudioPlayback.
/// </summary>
/// <exception cref="InvalidOperationException">
- /// Operation failed due to internal error.\n
+ /// Operation failed due to an internal error.\n
/// -or-\n
/// The current state is <see cref="AudioIOState.Idle"/>.
/// </exception>
- /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed of.</exception>
/// <seealso cref="Prepare"/>
public void Unprepare()
{
}
/// <summary>
- /// Pauses feeding of audio data to the device.
+ /// Pauses feeding of the audio data to the device.
/// </summary>
- /// <remarks>It has no effect if the current is the <see cref="AudioIOState.Paused"/>.</remarks>
+ /// <remarks>It has no effect if the current state is <see cref="AudioIOState.Paused"/>.</remarks>
/// <exception cref="InvalidOperationException">
/// The current state is <see cref="AudioIOState.Idle"/>.\n
/// -or-\n
/// The method is called in the <see cref="BufferAvailable"/> event handler.
/// </exception>
- /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed of.</exception>
/// <seealso cref="Resume"/>
public void Pause()
{
}
/// <summary>
- /// Resumes feeding of audio data to the device.
+ /// Resumes feeding of the audio data to the device.
/// </summary>
- /// <remarks>It has no effect if the current is the <see cref="AudioIOState.Running"/>.</remarks>
+ /// <remarks>It has no effect if the current state is <see cref="AudioIOState.Running"/>.</remarks>
/// <exception cref="InvalidOperationException">
/// The current state is <see cref="AudioIOState.Idle"/>.\n
/// -or-\n
/// The method is called in an event handler.
/// </exception>
- /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed of.</exception>
/// <seealso cref="Pause"/>
public void Resume()
{
}
/// <summary>
- /// Flushes and discards buffered audio data from the output stream.
+ /// Flushes and discards the buffered audio data from the output stream.
/// </summary>
/// <exception cref="InvalidOperationException">The current state is <see cref="AudioIOState.Idle"/>.</exception>
- /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The AudioPlayback has already been disposed of.</exception>
public void Flush()
{
ValidateState(AudioIOState.Running, AudioIOState.Paused);
/// <param name="streamPolicy">The <see cref="AudioStreamPolicy"/> to apply for the AudioPlayback.</param>
/// <exception cref="ArgumentNullException"><paramref name="streamPolicy"/> is null.</exception>
/// <exception cref="ObjectDisposedException">
- /// <paramref name="streamPolicy"/> has already been disposed.\n
+ /// <paramref name="streamPolicy"/> has already been disposed of.\n
/// -or-\n
- /// The AudioPlayback has already been disposed.
+ /// The AudioPlayback has already been disposed of.
/// </exception>
/// <exception cref="NotSupportedException"><paramref name="streamPolicy"/> is not supported.</exception>
/// <exception cref="ArgumentException">Not able to retrieve information from <paramref name="streamPolicy"/>.</exception>
/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
using System;
/// <exception cref="ArgumentOutOfRangeException"><paramref name="durationMilliseconds"/> is less than -1.</exception>
/// <exception cref="InvalidOperationException">Any invalid operations occurred.</exception>
/// <exception cref="NotSupportedException"><paramref name="tone"/> is not a supported type.</exception>
- /// <exception cref="ObjectDisposedException"><paramref name="streamPolicy"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException"><paramref name="streamPolicy"/> has already been disposed of.</exception>
public static Task StartAsync(ToneType tone, AudioStreamPolicy streamPolicy,
int durationMilliseconds)
{
/// <exception cref="ArgumentOutOfRangeException"><paramref name="durationMilliseconds"/> is less than -1.</exception>
/// <exception cref="InvalidOperationException">Any invalid operations occurred.</exception>
/// <exception cref="NotSupportedException"><paramref name="tone"/> is not a supported type.</exception>
- /// <exception cref="ObjectDisposedException"><paramref name="streamPolicy"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException"><paramref name="streamPolicy"/> has already been disposed of.</exception>
public static Task StartAsync(ToneType tone, AudioStreamPolicy streamPolicy,
int durationMilliseconds, CancellationToken cancellationToken)
{
namespace Tizen.Multimedia
{
/// <summary>
- /// Enumeration for Audio Codec.
+ /// Specifies the audio codec.
/// </summary>
public enum ToneType
{
/// </summary>
Dtmf2,
/// <summary>
- /// redefined DTMF 3.
+ /// Predefined DTMF 3.
/// </summary>
Dtmf3,
/// <summary>
/// <exception cref="InvalidOperationException">An internal error occurs.</exception>
/// <exception cref="FileNotFoundException"><paramref name="path"/> does not exists.</exception>
/// <exception cref="FileFormatException">The format of <paramref name="path"/> is not supported.</exception>
- /// <exception cref="ObjectDisposedException"><paramref name="streamPolicy"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException"><paramref name="streamPolicy"/> has already been disposed of.</exception>
public static Task StartAsync(string path, AudioStreamPolicy streamPolicy,
CancellationToken cancellationToken)
{
}
/// <summary>
- /// Gets the value indicating new status of the codec.
+ /// Gets the value indicating the new status of the codec.
/// </summary>
public MediaCodecStatus Status { get; }
}
/// <summary>
- /// Gets the packet that the codec has processed.
+ /// Gets the packet processed by the codec.
/// </summary>
public MediaPacket Packet { get; }
}
namespace Tizen.Multimedia.MediaCodec
{
/// <summary>
- /// Provides the means to encode and decode video and audio data.
+ /// Provides the means to encode and decode the video and the audio data.
/// </summary>
public class MediaCodec : IDisposable
{
private IntPtr _handle;
/// <summary>
- /// Initialize a new instance of the MediaCodec class.
+ /// Initializes a new instance of the MediaCodec class.
/// </summary>
public MediaCodec()
{
#endregion
/// <summary>
- /// Validates if the object already has been disposed of.
+ /// Validates if the object has already been disposed of.
/// </summary>
/// <exception cref="ObjectDisposedException">The current object has been disposed of.</exception>
private void ValidateNotDisposed()
/// Prepares the MediaCodec for encoding or decoding.
/// </summary>
/// <exception cref="InvalidOperationException">
- /// The codec is not configured, yet.\n
+ /// The codec is not configured yet.\n
/// -or-\n
/// Internal error.
/// </exception>
/// Configures the MediaCodec.
/// </summary>
/// <param name="format">The <see cref="MediaFormat"/> for properties of media data to decode or encode.</param>
- /// <param name="encoder">The value indicating whether the codec works as a encoder or a decoder.</param>
+ /// <param name="encoder">The value indicating whether the codec works as an encoder or a decoder.</param>
/// <param name="codecType">The value indicating whether the codec uses hardware acceleration.</param>
- /// <exception cref="ArgumentNullException">format is null</exception>
+ /// <exception cref="ArgumentNullException"><paramref name="format"/> is null.</exception>
/// <exception cref="ArgumentException">
/// <paramref name="codecType"/> is invalid.\n
/// -or-\n
/// <paramref name="format"/> is neither audio type nor video type.
/// </exception>
- /// <exception cref="NotSupportedException">the mime type of the format is not supported.</exception>
+ /// <exception cref="NotSupportedException">The mime type of the format is not supported.</exception>
/// <see cref="SupportedAudioCodecs"/>
/// <see cref="SupportedVideoCodecs"/>
public void Configure(MediaFormat format, bool encoder, MediaCodecTypes codecType)
/// Adds the packet to the internal queue of the codec.
/// </summary>
/// <param name="packet">The packet to be encoded or decoded.</param>
- /// <exception cref="ArgumentNullException">packet is null.</exception>
- /// <exception cref="InvalidOperationException">the current codec is not prepared, yet.</exception>
- /// <remarks>Any attempts to modify the packet will be failed until the <see cref="InputProcessed"/> event for the packet is invoked.</remarks>
+ /// <exception cref="ArgumentNullException"><paramref="packet"/> is null.</exception>
+ /// <exception cref="InvalidOperationException">The current codec is not prepared yet.</exception>
+ /// <remarks>Any attempts to modify the packet will fail until the <see cref="InputProcessed"/> event for the packet is invoked.</remarks>
public void ProcessInput(MediaPacket packet)
{
ValidateNotDisposed();
/// <param name="encoder">The value indicating encoder or decoder.</param>
/// <param name="type">The mime type to query.</param>
/// <returns>The values indicating which codec types are supported on the current device.</returns>
- /// <exception cref="ArgumentException">type is invalid.</exception>
+ /// <exception cref="ArgumentException"><paramref="type"/> is invalid.</exception>
public MediaCodecTypes GetCodecType(bool encoder, MediaFormatVideoMimeType type)
{
ValidateNotDisposed();
/// <param name="encoder">The value indicating encoder or decoder.</param>
/// <param name="type">The mime type to query.</param>
/// <returns>The values indicating which codec types are supported on the current device.</returns>
- /// <exception cref="ArgumentException">type is invalid.</exception>
+ /// <exception cref="ArgumentException"><paramref="type"/> is invalid.</exception>
public MediaCodecTypes GetCodecType(bool encoder, MediaFormatAudioMimeType type)
{
ValidateNotDisposed();
/// <param name="index">The index of the band to get.</param>
/// <exception cref="ObjectDisposedException">The <see cref="Player"/> has already been disposed of.</exception>
/// <exception cref="ArgumentOutOfRangeException">
- /// index is less than zero.\n
+ /// <pramref name="index"/> is less than zero.\n
/// -or-\n
- /// index is equal to or greater than <see cref="Count"/>.
+ /// <paramref name="index"/> is equal to or greater than <see cref="Count"/>.
/// </exception>
public EqualizerBand this[int index]
{
get
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
Player.ValidateNotDisposed();
if (index < 0 || Count <= index)
/// <exception cref="ObjectDisposedException">The <see cref="Player"/> has already been disposed of.</exception>
public void Clear()
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
Player.ValidateNotDisposed();
Native.EqualizerClear(Player.Handle).
ThrowIfFailed("Failed to clear equalizer effect");
- Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
}
/// <summary>
- /// Get the number of items.
+ /// Gets the number of items.
/// </summary>
public int Count { get; }
/// <summary>
- /// Get the band level range of the bands in dB.
+ /// Gets the band level range of the bands in the dB.
/// </summary>
public Range BandLevelRange { get; }
{
/// <summary>
- /// Represents a equalizer band of <see cref="AudioEffect"/>.
+ /// Represents an equalizer band of <see cref="AudioEffect"/>.
/// </summary>
public class EqualizerBand
{
internal EqualizerBand(AudioEffect owner, int index)
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
Debug.Assert(owner != null);
_owner = owner;
{
get
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
_owner.Player.ValidateNotDisposed();
int value = 0;
}
set
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
_owner.Player.ValidateNotDisposed();
if (value < _owner.BandLevelRange.Min || _owner.BandLevelRange.Max < value)
/// <summary>
- /// Gets the frequency in dB.
+ /// Gets the frequency in the dB.
/// </summary>
public int Frequency { get; }
/// <summary>
- /// Gets the frequency range in dB.
+ /// Gets the frequency range in the dB.
/// </summary>
public int FrequencyRange { get; }
private byte[] _buffer;
/// <summary>
- /// Initialize a new instance of the MediaBufferSource class with an allocated buffer.
+ /// Initializes a new instance of the MediaBufferSource class with an allocated buffer.
/// </summary>
/// <param name="length">The value indicating the size of the buffer.</param>
/// <exception cref="ArgumentOutOfRangeException">
}
/// <summary>
- /// Initialize a new instance of the MediaBufferSource class from the buffer.
+ /// Initializes a new instance of the MediaBufferSource class from the buffer.
/// </summary>
/// <param name="buffer">The source array to be copied into the buffer.</param>
- /// <exception cref="ArgumentNullException">buffer is null.</exception>
+ /// <exception cref="ArgumentNullException"><paramref="buffer"/> is null.</exception>
public MediaBufferSource(byte[] buffer) : this(buffer, buffer == null ? 0 : buffer.Length)
{
}
//TODO remove default parameter.
/// <summary>
- /// Initialize a new instance of the MediaBufferSource class from the buffer
+ /// Initializes a new instance of the MediaBufferSource class from the buffer
/// with the specified length and the specified offset.
/// </summary>
/// <param name="buffer">The source array to be copied into the buffer.</param>
/// <param name="length">The value indicating the number of bytes to copy from the buffer.</param>
/// <param name="offset">The value indicating the offset in the buffer of the first byte to copy.</param>
- /// <exception cref="ArgumentNullException">buffer is null.</exception>
+ /// <exception cref="ArgumentNullException"><paramref="buffer"/> is null.</exception>
/// <exception cref="ArgumentOutOfRangeException">
/// <paramref name="offset"/> is less than zero.\n
/// -or-\n
}
/// <summary>
- /// Create a MediaBufferSource that wraps a byte array.
+ /// Creates a MediaBufferSource that wraps a byte array.
/// </summary>
/// <param name="buffer">The array to be wrapped.</param>
/// <returns>A MediaBufferSource wrapping the byte array.</returns>
internal void AttachTo(Player player)
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
OnAttached(player);
}
internal void DetachFrom(Player player)
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
OnDetached(player);
}
}
/// <summary>
- /// Occurs when the buffer underrun or overflow.
+ /// Occurs when the buffer underruns or overflows.
/// </summary>
/// <remarks>The event handler will be executed on an internal thread.</remarks>
/// <seealso cref="BufferMaxSize"/>
/// Gets the max size of the buffer.
/// </summary>
/// <value>The max size of the buffer. The default is 200000.</value>
- /// <remarks>If the buffer level over the max size, <see cref="BufferStatusChanged"/> will be raised with <see cref="MediaStreamBufferStatus.Overflow"/>.</remarks>
+ /// <remarks>If the buffer level overflows the max size, <see cref="BufferStatusChanged"/> will be raised with <see cref="MediaStreamBufferStatus.Overflow"/>.</remarks>
/// <exception cref="InvalidOperationException">The <see cref="MediaStreamSource"/> is not assigned to a player.</exception>
- /// <exception cref="ArgumentOutOfRangeException">value is zero.</exception>
+ /// <exception cref="ArgumentOutOfRangeException"><paramref name="value"/> is zero.</exception>
/// <seealso cref="BufferStatusChanged"/>
public ulong BufferMaxSize
{
}
/// <summary>
- /// Gets the min threshold of the buffer or zero if the <see cref="MediaStreamSource"/> is not assigned to a player.
+ /// Gets the minimum threshold of the buffer, or zero if the <see cref="MediaStreamSource"/> is not assigned to a player.
/// </summary>
/// <value>The minimum threshold of the buffer in percentage. The default is zero.</value>
/// <remarks>If the buffer level drops below the threshold value, <see cref="BufferStatusChanged"/> will be raised with <see cref="MediaStreamBufferStatus.Underrun"/>.</remarks>
/// <exception cref="InvalidOperationException">The <see cref="MediaStreamSource"/> is not assigned to a player.</exception>
- /// <exception cref="ArgumentOutOfRangeException">value is greater than 100.</exception>
+ /// <exception cref="ArgumentOutOfRangeException"><paramref name="value"/> is greater than 100.</exception>
/// <seealso cref="BufferStatusChanged"/>
public uint BufferMinThreshold
{
{
/// <summary>
- /// Provides the ability to push packets as the source of <see cref="Player"/>
+ /// Provides the ability to push packets as the source of <see cref="Player"/>.
/// </summary>
/// <remarks>The source must be set as a source to a player before pushing.</remarks>
/// <seealso cref="Player.SetSource(MediaSource)"/>
/// <summary>
- /// Initialize a new instance of the MediaStreamSource class
+ /// Initializes a new instance of the MediaStreamSource class
/// with the specified <see cref="AudioMediaFormat"/> and <see cref="VideoMediaFormat"/>.
/// </summary>
/// <param name="audioMediaFormat">The <see cref="AudioMediaFormat"/> for this source.</param>
}
/// <summary>
- /// Initialize a new instance of the MediaStreamSource class with the specified <see cref="AudioMediaFormat"/>.
+ /// Initializes a new instance of the MediaStreamSource class with the specified <see cref="AudioMediaFormat"/>.
/// </summary>
/// <param name="audioMediaFormat">The <see cref="AudioMediaFormat"/> for this source.</param>
/// <remarks>AAC is supported.</remarks>
AudioConfiguration = CreateAudioConfiguration(audioMediaFormat);
}
/// <summary>
- /// Initialize a new instance of the MediaStreamSource class with the specified <see cref="VideoMediaFormat"/>.
+ /// Initializes a new instance of the MediaStreamSource class with the specified <see cref="VideoMediaFormat"/>.
/// </summary>
- /// <remarks>H.264 can is supported.</remarks>
+ /// <remarks>H.264 is supported.</remarks>
/// <param name="videoMediaFormat">The <see cref="VideoMediaFormat"/> for this source.</param>
/// <exception cref="ArgumentNullException"><paramref name="videoMediaFormat"/> is null.</exception>
/// <exception cref="ArgumentException"><paramref name="videoMediaFormat"/> is not supported.</exception>
}
/// <summary>
- /// Gets the audio configuration or null if no AudioMediaFormat is specified in the constructor.
+ /// Gets the audio configuration, or null if no AudioMediaFormat is specified in the constructor.
/// </summary>
public MediaStreamConfiguration AudioConfiguration { get; }
/// <summary>
- /// Gets the video configuration or null if no VideoMediaFormat is specified in the constructor.
+ /// Gets the video configuration, or null if no VideoMediaFormat is specified in the constructor.
/// </summary>
public MediaStreamConfiguration VideoConfiguration { get; }
/// <summary>
/// Pushes elementary stream to decode audio or video.
/// </summary>
- /// <remarks>This source must be set as a source to a player and the player must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</remarks>
+ /// <remarks>This source must be set as a source to a player and the player must be in the <see cref="PlayerState.Ready"/>,
+ /// <see cref="PlayerState.Playing"/>, or <see cref="PlayerState.Paused"/> state.</remarks>
/// <param name="packet">The <see cref="MediaPacket"/> to decode.</param>
/// <exception cref="InvalidOperationException">
/// This source is not set as a source to a player.\n
/// -or-\n
/// The player is not in the valid state.
/// </exception>
- /// <exception cref="ArgumentNullException">packet is null.</exception>
- /// <exception cref="ObjectDisposedException">packet has been disposed.</exception>
+ /// <exception cref="ArgumentNullException"><paramref name="packet"/> is null.</exception>
+ /// <exception cref="ObjectDisposedException"><paramref name="packet"/> has been disposed of.</exception>
/// <exception cref="ArgumentException">
/// <paramref name="packet"/> is neither video nor audio type.\n
/// -or-\n
/// The format of packet is not matched with the specified format in the constructor.
/// </exception>
- /// <exception cref="NoBufferSpaceException">the internal buffer reaches limits.</exception>
+ /// <exception cref="NoBufferSpaceException">The internal buffer has reached its limits.</exception>
/// <seealso cref="Player.SetSource(MediaSource)"/>
/// <seealso cref="MediaStreamConfiguration.BufferMaxSize"/>
/// <seealso cref="MediaPacket"/>
}
/// <summary>
- /// Gets the <see cref="Player"/> that this source is assigned to as a source or null if this source is not assigned.
+ /// Gets the <see cref="Player"/> that this source is assigned to as a source, or null if this source is not assigned.
/// </summary>
/// <seealso cref="Player.SetSource(MediaSource)"/>
public Player Player => _player;
/// Represents a media source with a uri.
/// </summary>
/// <remarks>
- /// The internet privilege(http://tizen.org/privilege/internet) must be added if any URLs are used to play from network.
+ /// The internet privilege(http://tizen.org/privilege/internet) must be added if any URLs are used to play from a network.
/// The mediastorage privilege(http://tizen.org/privilege/mediastorage) must be added if any video/audio files are used to play located in the internal storage.
/// The externalstorage privilege(http://tizen.org/privilege/externalstorage) must be added if any video/audio files are used to play located in the external storage.
/// </remarks>
public partial class Player
{
/// <summary>
- /// Occurs when playback of a media is finished.
+ /// Occurs when the playback of a media is finished.
/// </summary>
public event EventHandler<EventArgs> PlaybackCompleted;
private NativePlayer.PlaybackCompletedCallback _playbackCompletedCallback;
/// <summary>
- /// Occurs when playback of a media is interrupted.
+ /// Occurs when the playback of a media is interrupted.
/// </summary>
public event EventHandler<PlaybackInterruptedEventArgs> PlaybackInterrupted;
private NativePlayer.PlaybackInterruptedCallback _playbackInterruptedCallback;
private NativePlayer.PlaybackErrorCallback _playbackErrorCallback;
/// <summary>
- /// Occurs when the video stream changed.
+ /// Occurs when the video stream is changed.
/// </summary>
/// <remarks>The event handler will be executed on an internal thread.</remarks>
public event EventHandler<VideoStreamChangedEventArgs> VideoStreamChanged;
private string _userAgent = "";
/// <summary>
- /// Gets or Sets the cookie for streaming playback.
+ /// Gets or sets the cookie for streaming playback.
/// </summary>
/// <remarks>To set, the player must be in the <see cref="PlayerState.Idle"/> state.</remarks>
/// <exception cref="InvalidOperationException">The player is not in the valid state.</exception>
}
/// <summary>
- /// Gets or Sets the user agent for streaming playback.
+ /// Gets or sets the user agent for streaming playback.
/// </summary>
/// <remarks>To set, the player must be in the <see cref="PlayerState.Idle"/> state.</remarks>
/// <exception cref="InvalidOperationException">The player is not in the valid state.</exception>
/// <value>A <see cref="AudioLatencyMode"/> that specifies the mode. The default is <see cref="AudioLatencyMode.Mid"/>.</value>
/// <remarks>
/// If the mode is <see cref="AudioLatencyMode.High"/>,
- /// audio output interval can be increased so, it can keep more audio data to play.
+ /// audio output interval can be increased, so it can keep more audio data to play.
/// But, state transition like pause or resume can be more slower than default(<see cref="AudioLatencyMode.Mid"/>).
/// </remarks>
/// <exception cref="ObjectDisposedException">The player has already been disposed of.</exception>
private PlayerTrackInfo _audioTrack;
/// <summary>
- /// Gets the track info for audio.
+ /// Gets the track info for the audio.
/// </summary>
/// <value>A <see cref="PlayerTrackInfo"/> for audio.</value>
public PlayerTrackInfo AudioTrackInfo
private PlayerTrackInfo _subtitleTrackInfo;
/// <summary>
- /// Gets the track info for subtitle.
+ /// Gets the track info for the subtitle.
/// </summary>
- /// <value>A <see cref="PlayerTrackInfo"/> for subtitle.</value>
+ /// <value>A <see cref="PlayerTrackInfo"/> for the subtitle.</value>
public PlayerTrackInfo SubtitleTrackInfo
{
get
namespace Tizen.Multimedia
{
- static internal class PlayerLog
+ internal static class PlayerLog
{
internal const string Tag = "Tizen.Multimedia.Player";
- internal const string Enter = "[ENTER]";
- internal const string Leave = "[LEAVE]";
}
/// <summary>
/// Provides the ability to control media playback.
/// </summary>
/// <remarks>
- /// The Player provides functions to play a media content.
+ /// The player provides functions to play a media content.
/// It also provides functions to adjust the configurations of the player such as playback rate, volume, looping etc.
/// Note that only one video player can be played at one time.
/// </remarks>
private PlayerHandle _handle;
/// <summary>
- /// Initialize a new instance of the Player class.
+ /// Initializes a new instance of the <see cref="Player"/> class.
/// </summary>
public Player()
{
#region Methods
/// <summary>
- /// Gets the streaming download Progress.
+ /// Gets the streaming download progress.
/// </summary>
/// <returns>The <see cref="DownloadProgress"/> containing current download progress.</returns>
/// <remarks>The player must be in the <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</remarks>
/// <exception cref="ObjectDisposedException">The player has already been disposed of.</exception>
public DownloadProgress GetDownloadProgress()
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
ValidatePlayerState(PlayerState.Playing, PlayerState.Paused);
int start = 0;
/// <exception cref="ArgumentNullException">The path is null.</exception>
public void SetSubtitle(string path)
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
ValidateNotDisposed();
if (path == null)
NativePlayer.SetSubtitlePath(Handle, path).
ThrowIfFailed("Failed to set the subtitle path to the player");
-
- Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
}
/// <summary>
/// <exception cref="InvalidOperationException">The player is not in the valid state.</exception>
public void ClearSubtitle()
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
ValidatePlayerState(PlayerState.Idle);
NativePlayer.SetSubtitlePath(Handle, null).
ThrowIfFailed("Failed to clear the subtitle of the player");
- Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
}
/// <summary>
}
err.ThrowIfFailed("Failed to the subtitle offset of the player");
- Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
}
private void Prepare()
/// <exception cref="InvalidOperationException">The player is not in the valid state.</exception>
public virtual Task PrepareAsync()
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
if (_source == null)
{
throw new InvalidOperationException("No source is set.");
completionSource.TrySetException(e);
}
});
- Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
return completionSource.Task;
}
/// Unprepares the player.
/// </summary>
/// <remarks>
- /// The most recently used source is reset and no longer associated with the player. Playback is no longer possible.
+ /// The most recently used source is reset and is no longer associated with the player. Playback is no longer possible.
/// If you want to use the player again, you have to set a source and call <see cref="PrepareAsync"/> again.
/// <para>
- /// The player must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.
+ /// The player must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/>, or <see cref="PlayerState.Paused"/> state.
/// It has no effect if the player is already in the <see cref="PlayerState.Idle"/> state.
/// </para>
/// </remarks>
/// <exception cref="InvalidOperationException">The player is not in the valid state.</exception>
public virtual void Unprepare()
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
if (State == PlayerState.Idle)
{
Log.Warn(PlayerLog.Tag, "idle state already");
/// <seealso cref="ApplyAudioStreamPolicy"/>
public virtual void Start()
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
if (State == PlayerState.Playing)
{
Log.Warn(PlayerLog.Tag, "playing state already");
ValidatePlayerState(PlayerState.Ready, PlayerState.Paused);
NativePlayer.Start(Handle).ThrowIfFailed("Failed to start the player");
- Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
}
/// <summary>
- /// Stops playing media content.
+ /// Stops playing the media content.
/// </summary>
/// <remarks>
/// The player must be in the <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.
/// <seealso cref="Pause"/>
public virtual void Stop()
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
if (State == PlayerState.Ready)
{
Log.Warn(PlayerLog.Tag, "ready state already");
ValidatePlayerState(PlayerState.Paused, PlayerState.Playing);
NativePlayer.Stop(Handle).ThrowIfFailed("Failed to stop the player");
- Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
}
/// <summary>
/// <seealso cref="Start"/>
public virtual void Pause()
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
if (State == PlayerState.Paused)
{
Log.Warn(PlayerLog.Tag, "pause state already");
ValidatePlayerState(PlayerState.Playing);
NativePlayer.Pause(Handle).ThrowIfFailed("Failed to pause the player");
- Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
}
private MediaSource _source;
/// <seealso cref="PrepareAsync"/>
public void SetSource(MediaSource source)
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
ValidatePlayerState(PlayerState.Idle);
if (source != null)
}
_source = source;
- Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
}
/// <summary>
- /// Captures a video frame asynchronously.
+ /// Captures a video frame, asynchronously.
/// </summary>
/// <returns>A task that represents the asynchronous capture operation.</returns>
/// <feature>http://tizen.org/feature/multimedia.raw_video</feature>
/// <exception cref="NotSupportedException">The required feature is not supported.</exception>
public async Task<CapturedFrame> CaptureVideoAsync()
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
-
ValidationUtil.ValidateFeatureSupported(Features.RawVideo);
ValidatePlayerState(PlayerState.Playing, PlayerState.Paused);
/// <summary>
/// Gets the play position in milliseconds.
/// </summary>
- /// <remarks>The player must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</remarks>
+ /// <remarks>The player must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/>,
+ /// or <see cref="PlayerState.Paused"/> state.</remarks>
/// <exception cref="ObjectDisposedException">The player has already been disposed of.</exception>
/// <exception cref="InvalidOperationException">The player is not in the valid state.</exception>
/// <seealso cref="SetPlayPositionAsync(int, bool)"/>
public int GetPlayPosition()
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
ValidatePlayerState(PlayerState.Ready, PlayerState.Paused, PlayerState.Playing);
int playPosition = 0;
private void SetPlayPosition(int milliseconds, bool accurate,
NativePlayer.SeekCompletedCallback cb)
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
var ret = NativePlayer.SetPlayPosition(Handle, milliseconds, accurate, cb, IntPtr.Zero);
//Note that we assume invalid param error is returned only when the position value is invalid.
/// <param name="position">The value indicating a desired position in milliseconds.</param>
/// <param name="accurate">The value indicating whether the operation performs with accuracy.</param>
/// <remarks>
- /// <para>The player must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</para>
+ /// <para>The player must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/>,
+ /// or <see cref="PlayerState.Paused"/> state.</para>
/// <para>If the <paramref name="accurate"/> is true, the play position will be adjusted as the specified <paramref name="position"/> value,
/// but this might be considerably slow. If false, the play position will be a nearest keyframe position.</para>
/// </remarks>
/// <seealso cref="GetPlayPosition"/>
public async Task SetPlayPositionAsync(int position, bool accurate)
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
ValidatePlayerState(PlayerState.Ready, PlayerState.Playing, PlayerState.Paused);
var taskCompletionSource = new TaskCompletionSource<bool>();
await taskCompletionSource.Task;
}
-
- Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
}
/// <summary>
- /// Sets playback rate.
+ /// Sets the playback rate.
/// </summary>
/// <param name="rate">The value for the playback rate. Valid range is -5.0 to 5.0, inclusive.</param>
/// <remarks>
- /// <para>The player must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</para>
+ /// <para>The player must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/>,
+ /// or <see cref="PlayerState.Paused"/> state.</para>
/// <para>The sound will be muted, when the playback rate is under 0.0 or over 2.0.</para>
/// </remarks>
/// <exception cref="ObjectDisposedException">The player has already been disposed of.</exception>
/// </exception>
public void SetPlaybackRate(float rate)
{
- Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
if (rate < -5.0F || 5.0F < rate || rate == 0.0F)
{
throw new ArgumentOutOfRangeException(nameof(rate), rate, "Valid range is -5.0 to 5.0 (except 0.0)");
ValidatePlayerState(PlayerState.Ready, PlayerState.Playing, PlayerState.Paused);
NativePlayer.SetPlaybackRate(Handle, rate).ThrowIfFailed("Failed to set the playback rate.");
- Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
}
/// <summary>
/// <exception cref="InvalidOperationException">
/// Operation failed; internal error.
/// </exception>
- /// <exception cref="ObjectDisposedException">The player already has been disposed of.</exception>
+ /// <exception cref="ObjectDisposedException">The player has already been disposed of.</exception>
/// <exception cref="ArgumentException">The specified value to set is invalid.</exception>
public PlayerDisplayMode Mode
{
/// <exception cref="InvalidOperationException">
/// Operation failed; internal error.
/// </exception>
- /// <exception cref="ObjectDisposedException">The player already has been disposed of.</exception>
+ /// <exception cref="ObjectDisposedException">The player has already been disposed of.</exception>
public bool IsVisible
{
get
/// <exception cref="InvalidOperationException">
/// Operation failed; internal error.
/// </exception>
- /// <exception cref="ObjectDisposedException">The player already has been disposed of.</exception>
+ /// <exception cref="ObjectDisposedException">The player has already been disposed of.</exception>
/// <exception cref="ArgumentException">The specified value to set is invalid.</exception>
public Rotation Rotation
{
/// -or-\n
/// <see cref="Mode"/> is not set to <see cref="PlayerDisplayMode.Roi"/>.
/// </exception>
- /// <exception cref="ObjectDisposedException">The player already has been disposed of.</exception>
- /// <exception cref="ArgumentOutOfRangeException">width or height is less than or equal to zero.</exception>
+ /// <exception cref="ObjectDisposedException">The player has already been disposed of.</exception>
+ /// <exception cref="ArgumentOutOfRangeException">The width or the height is less than or equal to zero.</exception>
public void SetRoi(Rectangle roi)
{
if (roi.Width <= 0)
Paused,
/// <summary>
- /// Preparing in progress.
+ /// Preparation in progress.
/// </summary>
/// <seealso cref="Player.PrepareAsync"/>/>
Preparing,
}
/// <summary>
- /// Specifies audio latency modes for <see cref="Player"/> .
+ /// Specifies audio latency modes for <see cref="Player"/>.
/// </summary>
/// <seealso cref="Player.AudioLatencyMode"/>
public enum AudioLatencyMode
}
/// <summary>
- /// Specifies display modes for <see cref="Player"/>
+ /// Specifies display modes for <see cref="Player"/>.
/// </summary>
/// <seealso cref="PlayerDisplaySettings.Mode"/>
public enum PlayerDisplayMode
CroppedFull,
/// <summary>
- /// Origin size (if surface size is larger than video size(width/height)) or
- /// Letter box (if video size(width/height) is larger than surface size).
+ /// Original size (if surface size is larger than video size(width/height)) or
+ /// letter box (if video size(width/height) is larger than surface size).
/// </summary>
OriginalOrFull,
/// <summary>
- /// Region of interest, See <see cref="PlayerDisplaySettings.SetRoi(Rectangle)"/>.
+ /// Region of interest.
/// </summary>
+ /// <seealso cref="PlayerDisplaySettings.SetRoi(Rectangle)"/>
Roi
}
internal enum StreamType
{
/// <summary>
- /// Audio element stream type
+ /// Audio element stream type.
/// </summary>
Audio = 1,
/// <summary>
- /// Video element stream type
+ /// Video element stream type.
/// </summary>
Video,
/// <summary>
- /// Text type
+ /// Text type.
/// </summary>
Text
}
public enum PlaybackInterruptionReason
{
/// <summary>
- /// Interrupted by a resource conflict and the <see cref="Player"/> will be unprepared, automatically.
+ /// Interrupted by a resource conflict and the <see cref="Player"/> will be unprepared automatically.
/// </summary>
ResourceConflict = 4
}
/// <summary>
/// Initializes a new instance of the PlayerErrorOccurredEventArgs class.
/// </summary>
- /// <param name="error">The value indicating what kind of error occurred.</param>
+ /// <param name="error">The value indicating the kind of error occurred.</param>
public PlayerErrorOccurredEventArgs(PlayerError error)
{
Error = error;
namespace Tizen.Multimedia
{
/// <summary>
- /// Provides a means to retrieve track information.
+ /// Provides a means to retrieve the track information.
/// </summary>
/// <seealso cref="Player.SubtitleTrackInfo"/>
/// <seealso cref="Player.AudioTrackInfo"/>
/// Gets the number of tracks.
/// </summary>
/// <returns>The number of tracks.</returns>
- /// <remarks>The <see cref="Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</remarks>
- /// <exception cref="ObjectDisposedException">The <see cref="Player"/> that this instance belongs to has been disposed.</exception>
+ /// <remarks>
+ /// The <see cref="Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>,
+ /// <see cref="PlayerState.Playing"/>, or <see cref="PlayerState.Paused"/> state.
+ /// </remarks>
+ /// <exception cref="ObjectDisposedException">The <see cref="Player"/> that this instance belongs to has been disposed of.</exception>
/// <exception cref="InvalidOperationException">The <see cref="Player"/> that this instance belongs to is not in the valid state.</exception>
public int GetCount()
{
}
/// <summary>
- /// Gets the language code for the specified index or null if the language is undefined.
+ /// Gets the language code for the specified index, or null if the language is undefined.
/// </summary>
/// <returns>The number of tracks.</returns>
/// <remarks>
- /// <para>The <see cref="Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</para>
+ /// <para>The <see cref="Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>,
+ /// <see cref="PlayerState.Playing"/>, or <see cref="PlayerState.Paused"/> state.</para>
/// <para>The language codes are defined in ISO 639-1.</para>
/// </remarks>
- /// <exception cref="ObjectDisposedException">The <see cref="Player"/> that this instance belongs to has been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="Player"/> that this instance belongs to has been disposed of.</exception>
/// <exception cref="InvalidOperationException">The <see cref="Player"/> that this instance belongs to is not in the valid state.</exception>
/// <exception cref="ArgumentOutOfRangeException">
/// <paramref name="index"/> is less than zero.\n
/// Gets or sets the selected track index.
/// </summary>
/// <value>The currently selected track index.</value>
- /// <remarks>The <see cref="Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</remarks>
- /// <exception cref="ObjectDisposedException">The <see cref="Player"/> that this instance belongs to has been disposed.</exception>
+ /// <remarks>
+ /// The <see cref="Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>,
+ /// <see cref="PlayerState.Playing"/>, or <see cref="PlayerState.Paused"/> state.
+ /// </remarks>
+ /// <exception cref="ObjectDisposedException">The <see cref="Player"/> that this instance belongs to has been disposed of.</exception>
/// <exception cref="InvalidOperationException">The <see cref="Player"/> that this instance belongs to is not in the valid state.</exception>
/// <exception cref="ArgumentOutOfRangeException">
/// <paramref name="value"/> is less than zero.\n
namespace Tizen.Multimedia
{
/// <summary>
- /// Represents properties for audio stream.
+ /// Represents properties for the audio stream.
/// </summary>
public struct AudioStreamProperties
{
/// <summary>
- /// Initialize a new instance of the AudioStreamProperties struct with the specified sample rate, channels and bit rate.
+ /// Initializes a new instance of the AudioStreamProperties struct with the specified sample rate, channels, and bit rate.
/// </summary>
/// <param name="sampleRate">The sample rate of the stream.</param>
/// <param name="channels">The number of channels of the stream.</param>
}
/// <summary>
- /// Represents properties for video stream.
+ /// Represents properties for the video stream.
/// </summary>
public struct VideoStreamProperties
{
/// <summary>
- /// Initialize a new instance of the VideoStreamProperties struct with the specified fps, bit rate and size.
+ /// Initializes a new instance of the VideoStreamProperties struct with the specified fps, bit rate, and size.
/// </summary>
/// <param name="fps">The fps of the stream.</param>
/// <param name="bitRate">The bit rate of the stream.</param>
", width : " + size.Width + ", height : " + size.Height);
}
/// <summary>
- /// Initialize a new instance of the VideoStreamProperties struct with the specified fps, bit rate, width and height.
+ /// Initializes a new instance of the VideoStreamProperties struct with the specified fps, bit rate, width, and height.
/// </summary>
/// <param name="fps">The fps of the stream.</param>
/// <param name="bitRate">The bit rate of the stream.</param>
}
/// <summary>
- /// Retrieves the album art of the stream or null if there is no album art data.
+ /// Retrieves the album art of the stream, or null if there is no album art data.
/// </summary>
/// <returns>Raw byte array if album art exists; otherwise null.</returns>
- /// <remarks>The <see cref="Multimedia.Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</remarks>
- /// <exception cref="ObjectDisposedException">The <see cref="Multimedia.Player"/> that this instance belongs to has been disposed.</exception>
- /// <exception cref="InvalidOperationException">The <see cref="Multimedia.Player"/> that this instance belongs to is not in the valid state.</exception>
+ /// <remarks>
+ /// The <see cref="Multimedia.Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>,
+ /// <see cref="PlayerState.Playing"/>, or <see cref="PlayerState.Paused"/> state.
+ /// </remarks>
+ /// <exception cref="ObjectDisposedException">
+ /// The <see cref="Multimedia.Player"/> that this instance belongs to has been disposed of.
+ /// </exception>
+ /// <exception cref="InvalidOperationException">
+ /// The <see cref="Multimedia.Player"/> that this instance belongs to is not in the valid state.
+ /// </exception>
public byte[] GetAlbumArt()
{
Player.ValidatePlayerState(PlayerState.Ready, PlayerState.Playing, PlayerState.Paused);
}
/// <summary>
- /// Retrieves the codec name of audio or null if there is no audio.
+ /// Retrieves the codec name of the audio or null if there is no audio.
/// </summary>
- /// <returns>A string that represents codec name.</returns>
+ /// <returns>A string that represents the codec name.</returns>
public string GetAudioCodec()
{
return GetCodecInfo(true);
}
/// <summary>
- /// Retrieves the codec name of video or null if there is no video.
+ /// Retrieves the codec name of the video or null if there is no video.
/// </summary>
- /// <returns>A string that represents codec name.</returns>
+ /// <returns>A string that represents the codec name.</returns>
public string GetVideoCodec()
{
return GetCodecInfo(false);
/// Gets the duration.
/// </summary>
/// <returns>The duration of the stream.</returns>
- /// <remarks>The <see cref="Multimedia.Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</remarks>
- /// <exception cref="ObjectDisposedException">The <see cref="Multimedia.Player"/> that this instance belongs to has been disposed.</exception>
- /// <exception cref="InvalidOperationException">The <see cref="Multimedia.Player"/> that this instance belongs to is not in the valid state.</exception>
+ /// <remarks>
+ /// The <see cref="Multimedia.Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>,
+ /// <see cref="PlayerState.Playing"/>, or <see cref="PlayerState.Paused"/> state.
+ /// </remarks>
+ /// <exception cref="ObjectDisposedException">
+ /// The <see cref="Multimedia.Player"/> that this instance belongs to has been disposed of.
+ /// </exception>
+ /// <exception cref="InvalidOperationException">
+ /// The <see cref="Multimedia.Player"/> that this instance belongs to is not in the valid state.
+ /// </exception>
public int GetDuration()
{
Player.ValidatePlayerState(PlayerState.Ready, PlayerState.Playing, PlayerState.Paused);
}
/// <summary>
- /// Gets the properties of audio.
+ /// Gets the properties of the audio.
/// </summary>
- /// <returns>A <see cref="AudioStreamProperties"/> that contains audio stream information.</returns>
- /// <remarks>The <see cref="Multimedia.Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</remarks>
- /// <exception cref="ObjectDisposedException">The <see cref="Multimedia.Player"/> that this instance belongs to has been disposed.</exception>
- /// <exception cref="InvalidOperationException">The <see cref="Multimedia.Player"/> that this instance belongs to is not in the valid state.</exception>
+ /// <returns>A <see cref="AudioStreamProperties"/> that contains the audio stream information.</returns>
+ /// <remarks>
+ /// The <see cref="Multimedia.Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>,
+ /// <see cref="PlayerState.Playing"/>, or <see cref="PlayerState.Paused"/> state.
+ /// </remarks>
+ /// <exception cref="ObjectDisposedException">
+ /// The <see cref="Multimedia.Player"/> that this instance belongs to has been disposed of.
+ /// </exception>
+ /// <exception cref="InvalidOperationException">
+ /// The <see cref="Multimedia.Player"/> that this instance belongs to is not in the valid state.
+ /// </exception>
public AudioStreamProperties GetAudioProperties()
{
Player.ValidatePlayerState(PlayerState.Ready, PlayerState.Playing, PlayerState.Paused);
NativePlayer.GetAudioStreamInfo(Player.Handle, out sampleRate, out channels, out bitRate).
ThrowIfFailed("Failed to get audio stream info");
- // TODO should we check value is zero and return null?
-
return new AudioStreamProperties(sampleRate, channels, bitRate);
}
/// <summary>
- /// Gets the properties of video.
+ /// Gets the properties of the video.
/// </summary>
- /// <returns>A <see cref="VideoStreamProperties"/> that contains video stream information.</returns>
- /// <remarks>The <see cref="Multimedia.Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</remarks>
- /// <exception cref="ObjectDisposedException">The <see cref="Multimedia.Player"/> that this instance belongs to has been disposed.</exception>
- /// <exception cref="InvalidOperationException">The <see cref="Multimedia.Player"/> that this instance belongs to is not in the valid state.</exception>
+ /// <returns>A <see cref="VideoStreamProperties"/> that contains the video stream information.</returns>
+ /// <remarks>
+ /// The <see cref="Multimedia.Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>,
+ /// <see cref="PlayerState.Playing"/>, or <see cref="PlayerState.Paused"/> state.
+ /// </remarks>
+ /// <exception cref="ObjectDisposedException">
+ /// The <see cref="Multimedia.Player"/> that this instance belongs to has been disposed of.
+ /// </exception>
+ /// <exception cref="InvalidOperationException">
+ /// The <see cref="Multimedia.Player"/> that this instance belongs to is not in the valid state.
+ /// </exception>
public VideoStreamProperties GetVideoProperties()
{
Player.ValidatePlayerState(PlayerState.Ready, PlayerState.Playing, PlayerState.Paused);
NativePlayer.GetVideoStreamInfo(Player.Handle, out fps, out bitRate).
ThrowIfFailed("Failed to get the video stream info");
- // TODO should we check value is zero and return null?
-
return new VideoStreamProperties(fps, bitRate, GetVideoSize());
}
/// </summary>
/// <returns>A string that represents the value of the specified key.</returns>
/// <param name="key">The key to query.</param>
- /// <remarks>The <see cref="Multimedia.Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>, <see cref="PlayerState.Playing"/> or <see cref="PlayerState.Paused"/> state.</remarks>
- /// <exception cref="ObjectDisposedException">The <see cref="Multimedia.Player"/> that this instance belongs to has been disposed.</exception>
- /// <exception cref="InvalidOperationException">The <see cref="Multimedia.Player"/> that this instance belongs to is not in the valid state.</exception>
+ /// <remarks>
+ /// The <see cref="Multimedia.Player"/> that owns this instance must be in the <see cref="PlayerState.Ready"/>,
+ /// <see cref="PlayerState.Playing"/>, or <see cref="PlayerState.Paused"/> state.</remarks>
+ /// <exception cref="ObjectDisposedException">
+ /// The <see cref="Multimedia.Player"/> that this instance belongs to has been disposed of.
+ /// </exception>
+ /// <exception cref="InvalidOperationException">
+ /// The <see cref="Multimedia.Player"/> that this instance belongs to is not in the valid state.
+ /// </exception>
public string GetMetadata(StreamMetadataKey key)
{
Player.ValidatePlayerState(PlayerState.Ready, PlayerState.Playing, PlayerState.Paused);
}
/// <summary>
- /// Gets the <see cref="Size"/> of new video.
+ /// Gets the <see cref="Size"/> of the new video.
/// </summary>
public Size Size { get; }
/// <summary>
- /// Gets the fps of new video
+ /// Gets the fps of the new video
/// </summary>
public int Fps { get; }
/// <summary>
- /// Gets the bit rate of new video.
+ /// Gets the bit rate of the new video.
/// </summary>
public int BitRate { get; }
/// Provides a means to edit the metadata of the media file.
/// </summary>
/// <privilege>
- /// If you want to access only internal storage,
+ /// If you want to access only an internal storage,
/// you should add privilege http://tizen.org/privilege/mediastorage. \n
- /// Or if you want to access only external storage,
+ /// Or if you want to access only an external storage,
/// you should add privilege http://tizen.org/privilege/externalstorage. \n
/// </privilege>
public class MetadataEditor : IDisposable
/// Initializes a new instance of the <see cref="MetadataEditor"/> class with the specified path.
/// </summary>
/// <since_tizen> 3 </since_tizen>
- /// <param name="path">The path of the media file to edit metadata.</param>
+ /// <param name="path">The path of the media file to edit the metadata.</param>
/// <exception cref="ArgumentNullException"><paramref name="path"/> is null.</exception>
/// <exception cref="ArgumentException"><paramref name="path"/> is a zero-length string, contains only white space.</exception>
/// <exception cref="FileFormatException">The file is not supported.</exception>
- /// <exception cref="FileNotFoundException">File does not exist.</exception>
- /// <exception cref="UnauthorizedAccessException">Caller does not have required privilege to access the file.</exception>
+ /// <exception cref="FileNotFoundException">The file does not exist.</exception>
+ /// <exception cref="UnauthorizedAccessException">The caller does not have required privilege to access the file.</exception>
public MetadataEditor(string path)
{
if (path == null)
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string Artist
{
get
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string Title
{
get
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string Album
{
get
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string Genre
{
get
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string Author
{
get
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string Copyright
{
get
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <remarks>
- /// If the media contains ID3 tag, this refers to the recorded date.
- /// If the media is a mp4 format, this refers to the year and the value to set will be converted into integer.
+ /// If the media contains the ID3 tag, this refers to the recorded date.
+ /// If the media is a mp4 format, this refers to the year, and the value to set will be converted into integer.
/// </remarks>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string Date
{
get
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string Description
{
get
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string Comment
{
get
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string TrackNumber
{
get
/// Gets the count of album arts of media.
/// </summary>
/// <since_tizen> 3 </since_tizen>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public int PictureCount
{
get => int.TryParse(GetParam(MetadataEditorAttr.PictureCount), out var value) ? value : 0;
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string Conductor
{
get
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <exception cref="InvalidOperationException">The file is read-only.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public string UnsyncLyrics
{
get
/// -or-\n
/// The file is read-only.
/// </exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public void Commit()
{
if (_isFileReadOnly)
/// Gets the artwork image in the media file.
/// </summary>
/// <since_tizen> 3 </since_tizen>
- /// <param name="index">The index of picture to import.</param>
- /// <returns> Artwork included in the media file.</returns>
- /// <returns>Artwork included in the media file.</returns>
+ /// <param name="index">The index of the picture to import.</param>
+ /// <returns>The artwork included in the media file.</returns>
/// <exception cref="InvalidOperationException">An internal error occurs.</exception>
/// <exception cref="ArgumentOutOfRangeException">
/// <paramref name="index"/> is less than zero.\n
/// -or-\n
/// <paramref name="index"/> is greater than or equal to <see cref="PictureCount"/>.\n
/// </exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public Artwork GetPicture(int index)
{
if (index < 0)
/// Appends the picture to the media file.
/// </summary>
/// <since_tizen> 3 </since_tizen>
- /// <param name="path">The path of picture for adding to the metadata.</param>
+ /// <param name="path">The path of the picture for adding to the metadata.</param>
/// <exception cref="InvalidOperationException">
/// An internal error occurs.\n
/// -or-\n
/// The media file is read-only.
/// </exception>
- /// <exception cref="ArgumentNullException"> Picture path is null</exception>
- /// <exception cref="FileNotFoundException">File does not exist.</exception>
- /// <exception cref="UnauthorizedAccessException">Caller does not have required privilege to access the file.</exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ArgumentNullException"><paramref name="path"/> is null</exception>
+ /// <exception cref="FileNotFoundException">The file does not exist.</exception>
+ /// <exception cref="UnauthorizedAccessException">The caller does not have required privilege to access the file.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
/// <exception cref="FileFormatException">The specified file is not supported.</exception>
public void AddPicture(string path)
{
/// Removes the picture from the media file.
/// </summary>
/// <since_tizen> 3 </since_tizen>
- /// <param name="index">The index of picture to remove.</param>
+ /// <param name="index">The index of the picture to remove.</param>
/// <exception cref="InvalidOperationException">
/// An internal error occurs.\n
/// -or-\n
/// -or-\n
/// <paramref name="index"/> is greater than or equal to <see cref="PictureCount"/>.\n
/// </exception>
- /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The <see cref="MetadataEditor"/> has already been disposed of.</exception>
public void RemovePicture(int index)
{
if (index < 0)
namespace Tizen.Multimedia
{
/// <summary>
- /// Enumeration for metadata extractor's error codes.
+ /// Enumeration for the metadata extractor's error codes.
/// </summary>
internal enum MetadataEditorError
{
namespace Tizen.Multimedia
{
/// <summary>
- /// Represents artwork information of media.
+ /// Represents the artwork information of the media.
/// </summary>
public class Artwork
{
/// <summary>
- /// Initializes a new instance of the Artwork class with the specified data and mime type.
+ /// Initializes a new instance of the Artwork class with the specified data and the mime type.
/// </summary>
/// <since_tizen> 3 </since_tizen>
- /// <param name="data">The data of the artwork to set metadata.</param>
+ /// <param name="data">The data of the artwork to set the metadata.</param>
/// <param name="mimeType">The mime type of the data of the artwork.</param>
public Artwork(byte[] data, string mimeType)
{
public byte[] Data { get; }
/// <summary>
- /// Gets the mime type of artwork.
+ /// Gets the mime type of the artwork.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public string MimeType { get; }
namespace Tizen.Multimedia
{
/// <summary>
- /// Represents video metadata information.
+ /// Represents the video metadata information.
/// </summary>
public class VideoMetadata
{
public int? BitRate { get; }
/// <summary>
- /// Gets the video FPS.
+ /// Gets the video fps.
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <value>The fps value, or null if the information does not exist.</value>
public int? Height { get; }
/// <summary>
- /// Get the codec type of the video.
+ /// Gets the codec type of the video.
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <value>A string representing the codec type, or null if the information does not exist.</value>
}
/// <summary>
- /// Represents audio metadata information.
+ /// Represents the audio metadata information.
/// </summary>
public class AudioMetadata
{
}
/// <summary>
- /// Represents metadata information of a media.
+ /// Represents the metadata information of a media.
/// </summary>
public class Metadata
{
*/
using System;
+using System.IO;
using System.Runtime.InteropServices;
namespace Tizen.Multimedia
}
/// <summary>
- /// Provides a set of functions to get the metadata from a media file.
+ /// Provides a means to get the metadata from a media file.
/// </summary>
public class MetadataExtractor : IDisposable
{
/// Initializes a new instance of the MetadataExtractor class with the specified path.
/// </summary>
/// <since_tizen> 3 </since_tizen>
- /// <param name="path">The path for the file to extract metadata.</param>
+ /// <param name="path">The path for the file to extract the metadata.</param>
/// <exception cref="ArgumentNullException"><paramref name="path"/> is null.</exception>
- /// <exception cref="FileNotFoundException"><paramref name="path"/> is not exist.</exception>
+ /// <exception cref="FileNotFoundException"><paramref name="path"/> does not exist.</exception>
public MetadataExtractor(string path)
{
if (path == null)
/// Initializes a new instance of the MetadataExtractor class with the specified buffer.
/// </summary>
/// <since_tizen> 3 </since_tizen>
- /// <param name="buffer">The buffer to extract metadata.</param>
+ /// <param name="buffer">The buffer to extract the metadata.</param>
/// <exception cref="ArgumentNullException"><paramref name="buffer"/> is null.</exception>
/// <exception cref="ArgumentException">The length of <paramref name="buffer"/> is zero.</exception>
public MetadataExtractor(byte[] buffer)
/// Retrieves the <see cref="Metadata"/>.
/// </summary>
/// <since_tizen> 3 </since_tizen>
- /// <returns>A <see cref="Metadata"/> for the given source.</returns>
- /// <exception cref="InvalidOperationException">Internal process error is occurred.</exception>
+ /// <returns>The <see cref="Metadata"/> for the given source.</returns>
+ /// <exception cref="InvalidOperationException">An internal process error occurs.</exception>
/// <exception cref="ObjectDisposedException">The <see cref="MetadataExtractor"/> has been already disposed of.</exception>
public Metadata GetMetadata()
{
/// Gets the artwork image in the source.
/// </summary>
/// <since_tizen> 3 </since_tizen>
- /// <returns>A <see cref="Artwork"/> if it exists, otherwise null.</returns>
- /// <exception cref="InvalidOperationException">Internal process error is occurred.</exception>
+ /// <returns>The <see cref="Artwork"/> if it exists, otherwise null.</returns>
+ /// <exception cref="InvalidOperationException">An internal process error occurs.</exception>
/// <exception cref="ObjectDisposedException">The <see cref="MetadataExtractor"/> has been already disposed of.</exception>
public Artwork GetArtwork()
{
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <param name="index">The index of lyrics to retrieve.</param>
- /// <returns>A <see cref="SyncLyrics"/> object if <paramref name="index"/> is valid, otherwise null.</returns>
- /// <exception cref="InvalidOperationException">Internal process error is occurred.</exception>
+ /// <returns>The <see cref="SyncLyrics"/> object if <paramref name="index"/> is valid, otherwise null.</returns>
+ /// <exception cref="InvalidOperationException">An internal process error occurs.</exception>
/// <exception cref="ObjectDisposedException">The <see cref="MetadataExtractor"/> has been already disposed of.</exception>
public SyncLyrics GetSyncLyrics(int index)
{
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <returns>The raw thumbnail data in RGB888 if it exists, otherwise null.</returns>
- /// <exception cref="InvalidOperationException">Internal process error is occurred.</exception>
+ /// <exception cref="InvalidOperationException">An internal process error occurs.</exception>
/// <exception cref="ObjectDisposedException">The <see cref="MetadataExtractor"/> has been already disposed of.</exception>
public byte[] GetVideoThumbnail()
{
}
}
- /// <summary>
- /// Metadata Extractor destructor
- /// </summary>
- /// <since_tizen> 3 </since_tizen>
~MetadataExtractor()
{
Dispose(false);
namespace Tizen.Multimedia
{
/// <summary>
- /// Enumeration for metadata extractor's error codes.
+ /// Enumeration for the metadata extractor's error codes.
/// </summary>
internal enum MetadataExtractorError
{
namespace Tizen.Multimedia
{
/// <summary>
- /// Represents synchronized lyrics information of media.
+ /// Represents the synchronized lyrics information of the media.
/// </summary>
public class SyncLyrics
{
/// <summary>
- /// Initialize a new instance of the MetadataExtractor class with the specified lyrics and timestamp.
+ /// Initializes a new instance of the MetadataExtractor class with the specified lyrics and the timestamp.
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <param name="lyrics">The text of synchronized lyrics.</param>
private const string FeatureFmRadio = "http://tizen.org/feature/fmradio";
/// <summary>
- /// Initialize a new instance of the Radio class.
+ /// Initializes a new instance of the Radio class.
/// </summary>
- /// <exception cref="NotSupportedException">Radio feature is not supported</exception>
+ /// <exception cref="NotSupportedException">The radio feature is not supported.</exception>
public Radio()
{
ValidateFeatureSupported(FeatureFmRadio);
}
/// <summary>
- /// Occurs when radio scan information is updated.
+ /// Occurs when the radio scanning information is updated.
/// </summary>
public event EventHandler<ScanUpdatedEventArgs> ScanUpdated;
/// <summary>
- /// Occurs when radio scanning stops.
+ /// Occurs when the radio scanning stops.
/// </summary>
public event EventHandler ScanStopped;
/// <summary>
- /// Occurs when radio scan is completed.
+ /// Occurs when the radio scanning is completed.
/// </summary>
public event EventHandler ScanCompleted;
/// <summary>
- /// Occurs when radio is interrupted
+ /// Occurs when the radio is interrupted.
/// </summary>
public event EventHandler<RadioInterruptedEventArgs> Interrupted;
}
/// <summary>
- /// Gets or sets the radio frequency, in [87500 ~ 108000] (kHz).
+ /// Gets or sets the radio frequency in the range of 87500 ~ 108000 kHz.
/// </summary>
/// <exception cref="ArgumentOutOfRangeException">
/// <paramref name="value"/> is less than <see cref="Range.Min"/> of <see cref="FrequencyRange"/>.\n
}
/// <summary>
- /// Gets the current signal strength, in [-128 ~ 128] (dBm).
+ /// Gets the current signal strength in the range of -128 ~ 128 dBm.
/// </summary>
public int SignalStrength
{
}
/// <summary>
- /// Gets the value indicating if radio is muted.
+ /// Gets the value indicating if the radio is muted.
/// </summary>
/// <value>
/// true if the radio is muted; otherwise, false.
}
/// <summary>
- /// Gets the channel spacing for current region.
+ /// Gets the channel spacing for the current region.
/// </summary>
public int ChannelSpacing
{
}
/// <summary>
- /// Gets the frequency for the region, in [87500 ~ 108000] (kHz).
+ /// Gets the frequency for the region in the range of 87500 ~ 108000 kHz.
/// </summary>
public Range FrequencyRange
{
}
/// <summary>
- /// Starts radio scan, will trigger ScanInformationUpdated event, when scan information is updated
+ /// Starts the radio scanning and triggers the ScanInformationUpdated event when the scan information is updated.
/// </summary>
/// <remarks>The radio must be in the <see cref="RadioState.Ready"/> or <see cref="RadioState.Playing"/> state.</remarks>
/// <exception cref="InvalidOperationException">The radio is not in the valid state.</exception>
}
/// <summary>
- /// Stops radio scan.
+ /// Stops the radio scanning.
/// </summary>
/// <remarks>The radio must be in the <see cref="RadioState.Scanning"/> state.</remarks>
/// <exception cref="InvalidOperationException">The radio is not in the valid state.</exception>
/// </summary>
/// <returns>
/// A task that represents the asynchronous seeking operation.
- /// The result value is the current frequency, in range [87500 ~ 108000] (kHz).
+ /// The result value is the current frequency in the range of 87500 ~ 108000 kHz.
/// It can be -1 if the seeking operation has failed.
/// </returns>
/// <remarks>The radio must be in the <see cref="RadioState.Playing"/> state.</remarks>
/// </summary>
/// <returns>
/// A task that represents the asynchronous seeking operation.
- /// The result value is the current frequency, in range [87500 ~ 108000] (kHz).
+ /// The result value is the current frequency in the range of 87500 ~ 108000 kHz.
/// It can be -1 if the seeking operation has failed.
/// </returns>
/// <remarks>The radio must be in the <see cref="RadioState.Playing"/> state.</remarks>
/// </summary>
/// <privilege>http://tizen.org/privilege/mediacontroller.client</privilege>
/// <exception cref="InvalidOperationException">An internal error occurs.</exception>
- /// <exception cref="UnauthorizedAccessException">Caller does not have required privilege.</exception>
+ /// <exception cref="UnauthorizedAccessException">The caller does not have required privilege.</exception>
public MediaControllerManager()
{
Native.Create(out _handle).ThrowIfError("Failed to create media controller client.");
namespace Tizen.Multimedia.Remoting
{
+ /// <summary>
+ /// Specifies the repeat mode.
+ /// </summary>
public enum MediaControlRepeatMode
{
+ /// <summary>
+ /// Off.
+ /// </summary>
Off,
+
+ /// <summary>
+ /// On.
+ /// </summary>
On,
}
}
\ No newline at end of file
}
/// <summary>
- /// Gets the current state of screen mirroring.
+ /// Gets the current state of the screen mirroring.
/// </summary>
public ScreenMirroringState State { get; }
}
namespace Tizen.Multimedia.Remoting
{
/// <summary>
- /// Specifies audio codecs for <see cref="ScreenMirroring"/>.
+ /// Specifies the audio codecs for <see cref="ScreenMirroring"/>.
/// </summary>
/// <seealso cref="ScreenMirroringAudioInfo"/>
public enum ScreenMirroringAudioCodec
{
/// <summary>
- /// Screen mirroring is not negotiated yet.
+ /// The screen mirroring is not negotiated yet.
/// </summary>
None,
/// <summary>
- /// AAC codec for audio.
+ /// AAC codec.
/// </summary>
Aac,
/// <summary>
- /// AC3 codec for audio.
+ /// AC3 codec.
/// </summary>
Ac3,
/// <summary>
- /// LPCM codec for audio.
+ /// LPCM codec.
/// </summary>
Lpcm
}
/// <summary>
- /// Specifies video codecs for <see cref="ScreenMirroring"/>.
+ /// Specifies the video codecs for <see cref="ScreenMirroring"/>.
/// </summary>
/// <seealso cref="ScreenMirroringVideoInfo"/>
public enum ScreenMirroringVideoCodec
{
/// <summary>
- /// Screen mirroring is not negotiated yet.
+ /// The screen mirroring is not negotiated yet.
/// </summary>
None,
/// <summary>
- /// H.264 codec for video.
+ /// H.264 codec.
/// </summary>
H264
}
/// <summary>
- /// Specifies available combinations of resolutions and fps for <see cref="ScreenMirroring"/>.
+ /// Specifies the available combinations of resolutions and fps for <see cref="ScreenMirroring"/>.
/// </summary>
[Flags]
public enum ScreenMirroringResolutions
}
/// <summary>
- /// Specifies errors for <see cref="ScreenMirroring"/>.
+ /// Specifies the errors for <see cref="ScreenMirroring"/>.
/// </summary>
public enum ScreenMirroringError
{
namespace Tizen.Multimedia.Util
{
/// <summary>
- /// Represents image data returned by a decoder class.
+ /// Represents the image data returned by a decoder class.
/// </summary>
public class BitmapFrame
{
namespace Tizen.Multimedia.Util
{
/// <summary>
- /// Represent gif image data used to encode a gif image with <see cref="GifEncoder"/>.
+ /// Represents the gif image data used to encode a gif image with <see cref="GifEncoder"/>.
/// </summary>
public class GifFrame
{
/// <summary>
- /// Initialize a new instance of the <see cref="GifFrame"/> class with a buffer and a delay.
+ /// Initializes a new instance of the <see cref="GifFrame"/> class with a buffer and a delay.
/// </summary>
/// <param name="buffer">The raw image buffer to be encoded.</param>
/// <param name="delay">The delay for this image, in 0.001 sec units.</param>
internal enum ImageColorSpace
{
/// <summary>
- /// YV12 - YCrCb planar format
+ /// YV12 - YCrCb planar format.
/// </summary>
YV12,
/// <summary>
- /// YUV422 - planar
+ /// YUV422 - planar.
/// </summary>
Yuv422,
/// <summary>
- /// YUV420 - planar
+ /// YUV420 - planar.
/// </summary>
I420,
/// <summary>
- /// NV12- planar
+ /// NV12- planar.
/// </summary>
NV12,
/// <summary>
- /// UYVY - packed
+ /// UYVY - packed.
/// </summary>
Uyvy,
/// <summary>
- /// YUYV - packed
+ /// YUYV - packed.
/// </summary>
Yuyv,
/// <summary>
- /// RGB565, high-byte is Blue
+ /// RGB565, high-byte is blue.
/// </summary>
Rgb565,
/// <summary>
- /// RGB888, high-byte is Blue
+ /// RGB888, high-byte is blue.
/// </summary>
Rgb888,
/// <summary>
- /// ARGB8888, high-byte is Blue
+ /// ARGB8888, high-byte is blue.
/// </summary>
Argb8888,
/// <summary>
- /// BGRA8888, high-byte is Alpha
+ /// BGRA8888, high-byte is alpha.
/// </summary>
Bgra8888,
/// <summary>
- /// RGBA8888, high-byte is Alpha
+ /// RGBA8888, high-byte is alpha.
/// </summary>
Rgba8888,
/// <summary>
- /// BGRX8888, high-byte is X
+ /// BGRX8888, high-byte is X.
/// </summary>
Bgrx8888,
/// <summary>
- /// NV21- planar
+ /// NV21- planar.
/// </summary>
NV21,
/// <summary>
- /// NV16- planar
+ /// NV16- planar.
/// </summary>
NV16,
/// <summary>
- /// NV61- planar
+ /// NV61- planar.
/// </summary>
NV61,
}
/// <summary>
/// Decodes an image from the specified file.
/// </summary>
- /// <param name="inputFilePath">Input file path from which to decode.</param>
+ /// <param name="inputFilePath">The input file path from which to decode.</param>
/// <returns>A task that represents the asynchronous decoding operation.</returns>
/// <remarks>
/// Only Graphics Interchange Format(GIF) codec returns more than one frame.\n
/// \n
- /// http://tizen.org/privilege/mediastorage is needed if <paramref name="inputFilePath"/> is relevant to media storage.\n
- /// http://tizen.org/privilege/externalstorage is needed if <paramref name="inputFilePath"/> is relevant to external storage.
+ /// http://tizen.org/privilege/mediastorage is needed if <paramref name="inputFilePath"/> is relevant to the media storage.\n
+ /// http://tizen.org/privilege/externalstorage is needed if <paramref name="inputFilePath"/> is relevant to the external storage.
/// </remarks>
/// <exception cref="ArgumentNullException"><paramref name="inputFilePath"/> is null.</exception>
/// <exception cref="ArgumentException">
/// The format of <paramref name="inputFilePath"/> is not <see cref="InputFormat"/>.
/// </exception>
/// <exception cref="FileNotFoundException"><paramref name="inputFilePath"/> does not exists.</exception>
- /// <exception cref="UnauthorizedAccessException">Caller does not have required permission to access the path.</exception>
+ /// <exception cref="UnauthorizedAccessException">The caller does not have required permission to access the path.</exception>
/// <exception cref="FileFormatException">The format of <paramref name="inputFilePath"/> is not <see cref="InputFormat"/>.</exception>
/// <exception cref="ObjectDisposedException">The <see cref="ImageDecoder"/> has already been disposed of.</exception>
public async Task<IEnumerable<BitmapFrame>> DecodeAsync(string inputFilePath)
private static readonly byte[] _header = { (byte)'B', (byte)'M' };
/// <summary>
- /// Initialize a new instance of the <see cref="BmpDecoder"/> class.
+ /// Initializes a new instance of the <see cref="BmpDecoder"/> class.
/// </summary>
/// <remarks><see cref="ImageDecoder.InputFormat"/> will be the <see cref="ImageFormat.Bmp"/>.</remarks>
public BmpDecoder() : base(ImageFormat.Bmp)
}
/// <summary>
- /// Provides the ability to decode Portable Network Graphics (PNG) encoded images.
+ /// Provides the ability to decode the Portable Network Graphics (PNG) encoded images.
/// </summary>
public class PngDecoder : ImageDecoder
{
private static readonly byte[] _header = { 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a };
/// <summary>
- /// Initialize a new instance of the <see cref="PngDecoder"/> class.
+ /// Initializes a new instance of the <see cref="PngDecoder"/> class.
/// </summary>
/// <remarks><see cref="ImageDecoder.InputFormat"/> will be the <see cref="ImageFormat.Png"/>.</remarks>
public PngDecoder() : base(ImageFormat.Png)
}
/// <summary>
- /// Provides the ability to decode Joint Photographic Experts Group (JPEG) encoded images.
+ /// Provides the ability to decode the Joint Photographic Experts Group (JPEG) encoded images.
/// </summary>
public class JpegDecoder : ImageDecoder
{
private JpegDownscale _jpegDownscale = DefaultJpegDownscale;
/// <summary>
- /// Initialize a new instance of the <see cref="JpegDecoder"/> class.
+ /// Initializes a new instance of the <see cref="JpegDecoder"/> class.
/// </summary>
/// <remarks><see cref="ImageDecoder.InputFormat"/> will be the <see cref="ImageFormat.Jpeg"/>.</remarks>
public JpegDecoder() : base(ImageFormat.Jpeg)
}
/// <summary>
- /// Provides the ability to decode Graphics Interchange Format (GIF) encoded images.
+ /// Provides the ability to decode the Graphics Interchange Format (GIF) encoded images.
/// </summary>
public class GifDecoder : ImageDecoder
{
private static readonly byte[] _header = { (byte)'G', (byte)'I', (byte)'F' };
/// <summary>
- /// Initialize a new instance of the <see cref="GifDecoder"/> class.
+ /// Initializes a new instance of the <see cref="GifDecoder"/> class.
/// </summary>
/// <remarks><see cref="ImageDecoder.InputFormat"/> will be the <see cref="ImageFormat.Gif"/>.</remarks>
public GifDecoder() : base(ImageFormat.Gif)
}
/// <summary>
- /// Provides the ability to encode Bitmap (BMP) format images.
+ /// Provides the ability to encode the Bitmap (BMP) format images.
/// </summary>
public class BmpEncoder : ImageEncoder
{
/// <summary>
- /// Initialize a new instance of the <see cref="BmpEncoder"/> class.
+ /// Initializes a new instance of the <see cref="BmpEncoder"/> class.
/// </summary>
/// <remarks><see cref="ImageEncoder.OutputFormat"/> will be the <see cref="ImageFormat.Bmp"/>.</remarks>
public BmpEncoder() : base(ImageFormat.Bmp)
}
/// <summary>
- /// Provides the ability to encode Portable Network Graphics (PNG) format images.
+ /// Provides the ability to encode the Portable Network Graphics (PNG) format images.
/// </summary>
public class PngEncoder : ImageEncoder
{
private PngCompression? _compression;
/// <summary>
- /// Initialize a new instance of the <see cref="PngEncoder"/> class.
+ /// Initializes a new instance of the <see cref="PngEncoder"/> class.
/// </summary>
/// <remarks><see cref="ImageEncoder.OutputFormat"/> will be the <see cref="ImageFormat.Png"/>.</remarks>
public PngEncoder() :
}
/// <summary>
- /// Initialize a new instance of the <see cref="PngEncoder"/> class with <see cref="PngCompression"/>.
+ /// Initializes a new instance of the <see cref="PngEncoder"/> class with <see cref="PngCompression"/>.
/// </summary>
/// <remarks><see cref="ImageEncoder.OutputFormat"/> will be the <see cref="ImageFormat.Png"/>.</remarks>
/// <param name="compression">The compression level of the encoder.</param>
}
/// <summary>
- /// Provides the ability to encode Joint Photographic Experts Group (JPEG) format images.
+ /// Provides the ability to encode the Joint Photographic Experts Group (JPEG) format images.
/// </summary>
public class JpegEncoder : ImageEncoder
{
private int? _quality;
/// <summary>
- /// Initialize a new instance of the <see cref="JpegEncoder"/> class.
+ /// Initializes a new instance of the <see cref="JpegEncoder"/> class.
/// </summary>
/// <remarks><see cref="ImageEncoder.OutputFormat"/> will be the <see cref="ImageFormat.Jpeg"/>.</remarks>
public JpegEncoder() : base(ImageFormat.Jpeg)
/// <summary>
- /// Initialize a new instance of the <see cref="JpegEncoder"/> class with initial quality value.
+ /// Initializes a new instance of the <see cref="JpegEncoder"/> class with initial quality value.
/// </summary>
/// <param name="quality">The quality for JPEG image encoding; from 1(lowest quality) to 100(highest quality).</param>
/// <remarks><see cref="ImageEncoder.OutputFormat"/> will be the <see cref="ImageFormat.Jpeg"/>.</remarks>
}
/// <summary>
- /// Provides the ability to encode Graphics Interchange Format (GIF) format images.
+ /// Provides the ability to encode the Graphics Interchange Format (GIF) format images.
/// </summary>
public class GifEncoder : ImageEncoder
{
/// <summary>
- /// Initialize a new instance of the <see cref="GifEncoder"/> class.
- /// </summary>
- /// <remarks><see cref="ImageEncoder.OutputFormat"/> will be the <see cref="ImageFormat.Gif"/>.</remarks>
+ /// Initializes a new instance of the <see cref="GifEncoder"/> class.
+ /// </summary>
+ /// <remarks><see cref="ImageEncoder.OutputFormat"/> will be the <see cref="ImageFormat.Gif"/>.</remarks>
public GifEncoder() : base(ImageFormat.Gif)
{
}
/// <summary>
/// Returns an enumerator that can iterate through the collection.
/// </summary>
- /// <returns>A enumerator that can be used to iterate through the collection.</returns>
+ /// <returns>An enumerator that can be used to iterate through the collection.</returns>
public IEnumerator<ImageTransform> GetEnumerator() => _list.GetEnumerator();
IEnumerator IEnumerable.GetEnumerator() => _list.GetEnumerator();
}
/// <summary>
- /// Rotates or flips an image.
+ /// Rotates an image.
/// </summary>
/// <seealso cref="Rotation"/>
public class RotateTransform : ImageTransform
private Rotation _rotation;
/// <summary>
- /// Initialize a new instance of the <see cref="RotateTransform"/> class.
+ /// Initializes a new instance of the <see cref="RotateTransform"/> class.
/// </summary>
/// <param name="rotation">The value how to rotate an image.</param>
/// <exception cref="ArgumentException"><paramref name="rotation"/> is invalid.</exception>
/// <summary>
- /// Rotates or flips an image.
+ /// Flips an image.
/// </summary>
/// <seealso cref="Rotation"/>
public class FlipTransform : ImageTransform
private Flips _flip;
/// <summary>
- /// Initialize a new instance of the <see cref="RotateTransform"/> class.
+ /// Initializes a new instance of the <see cref="RotateTransform"/> class.
/// </summary>
/// <param name="flip">The value how to flip an image.</param>
/// <exception cref="ArgumentException"><paramref name="flip"/> is invalid.</exception>
}
/// <summary>
- /// Changes colorspace of image.
+ /// Changes the colorspace of an image.
/// </summary>
/// <seealso cref="ColorSpace"/>
public class ColorSpaceTransform : ImageTransform
private ImageColorSpace _imageColorSpace;
/// <summary>
- /// Initialize a new instance of the <see cref="ColorSpaceTransform"/> class.
+ /// Initializes a new instance of the <see cref="ColorSpaceTransform"/> class.
/// </summary>
/// <param name="colorSpace">The colorspace of output image.</param>
/// <exception cref="ArgumentException"><paramref name="colorSpace"/> is invalid.</exception>
private Rectangle _region;
/// <summary>
- /// Initialize a new instance of the <see cref="CropTransform"/> class.
+ /// Initializes a new instance of the <see cref="CropTransform"/> class.
/// </summary>
/// <param name="region">The crop region.</param>
/// <exception cref="ArgumentOutOfRangeException">
private Size _size;
/// <summary>
- /// Initialize a new instance of the <see cref="ResizeTransform"/> class.
+ /// Initializes a new instance of the <see cref="ResizeTransform"/> class.
/// </summary>
/// <param name="size">The size that an image is resized to.</param>
/// <exception cref="ArgumentOutOfRangeException">
public class ImageTransformer : IDisposable
{
/// <summary>
- /// Initialize a new instance of the <see cref="ImageTransformer"/> class.
+ /// Initializes a new instance of the <see cref="ImageTransformer"/> class.
/// </summary>
public ImageTransformer()
{
namespace Tizen.Multimedia.Util
{
/// <summary>
- /// Specifies JPEG Downscale options for decoding.
+ /// Specifies the JPEG Downscale options for decoding.
/// </summary>
public enum JpegDownscale
{
namespace Tizen.Multimedia.Util
{
/// <summary>
- /// Specifies PNG compression levels.
+ /// Specifies the PNG compression levels.
/// </summary>
public enum PngCompression
{
/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
namespace Tizen.Multimedia.Util
{
/// <summary>
- /// Represents the result of thumbnail extraction.
+ /// Represents the result of the thumbnail extraction.
/// </summary>
public class ThumbnailExtractionResult
{
/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
using System;
using System.IO;
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <returns>A task that represents the asynchronous extracting operation.</returns>
- /// <remarks>The size of the thumbnail will be the default size(320x240).\n</remarks>
+ /// <remarks>The size of the thumbnail will be the default size (320x240).</remarks>
/// <param name="path">The path of the media file to extract the thumbnail.</param>
/// <exception cref="ArgumentNullException"><paramref name="path"/> is null.</exception>
- /// <exception cref="FileNotFoundException">Requested <paramref name="path"/> does not exist.</exception>
- /// <exception cref="InvalidOperationException">Internal error occurred.</exception>
- /// <exception cref="UnauthorizedAccessException">Caller does not have required privilege for accessing the <paramref name="path"/>.</exception>
+ /// <exception cref="FileNotFoundException"><paramref name="path"/> does not exist.</exception>
+ /// <exception cref="InvalidOperationException">An internal error occurs.</exception>
+ /// <exception cref="UnauthorizedAccessException">The caller does not have required privilege for accessing the <paramref name="path"/>.</exception>
/// <exception cref="FileFormatException">The specified file is not supported.</exception>
public static Task<ThumbnailExtractionResult> ExtractAsync(string path)
{
/// <param name="path">The path of the media file to extract the thumbnail.</param>
/// <param name="cancellationToken">The token to stop the operation.</param>
/// <exception cref="ArgumentNullException"><paramref name="path"/> is null.</exception>
- /// <exception cref="FileNotFoundException">Requested <paramref name="path"/> does not exist.</exception>
- /// <exception cref="InvalidOperationException">Internal error occurred.</exception>
- /// <exception cref="UnauthorizedAccessException">Caller does not have required privilege for accessing the <paramref name="path"/>.</exception>
+ /// <exception cref="FileNotFoundException"><paramref name="path"/> does not exist.</exception>
+ /// <exception cref="InvalidOperationException">An internal error occurs.</exception>
+ /// <exception cref="UnauthorizedAccessException">The caller does not have required privilege for accessing the <paramref name="path"/>.</exception>
/// <exception cref="FileFormatException">The specified file is not supported.</exception>
public static Task<ThumbnailExtractionResult> ExtractAsync(string path, CancellationToken cancellationToken)
{
/// <since_tizen> 3 </since_tizen>
/// <returns>A task that represents the asynchronous extracting operation.</returns>
/// <remarks>
- /// If the width is not a multiple of 8, it can be changed by inner process.\n
+ /// If the width is not a multiple of 8, it can be changed by the inner process.\n
/// The width will be a multiple of 8 greater than the set value.
/// </remarks>
/// <param name="path">The path of the media file to extract the thumbnail.</param>
/// <param name="size">The size of the thumbnail.</param>
/// <exception cref="ArgumentNullException"><paramref name="path"/> is null.</exception>
- /// <exception cref="FileNotFoundException">Requested <paramref name="path"/> does not exist.</exception>
- /// <exception cref="InvalidOperationException">Internal error occurred.</exception>
- /// <exception cref="UnauthorizedAccessException">Caller does not have required privilege for accessing the <paramref name="path"/>.</exception>
+ /// <exception cref="FileNotFoundException"><paramref name="path"/> does not exist.</exception>
+ /// <exception cref="InvalidOperationException">An internal error occurs.</exception>
+ /// <exception cref="UnauthorizedAccessException">The caller does not have required privilege for accessing the <paramref name="path"/>.</exception>
/// <exception cref="ArgumentOutOfRangeException">
- /// Width or height of <paramref name="size"/> is less than or equal to zero.
+ /// The width or the height of <paramref name="size"/> is less than or equal to zero.
/// </exception>
/// <exception cref="FileFormatException">The specified file is not supported.</exception>
public static Task<ThumbnailExtractionResult> ExtractAsync(string path, Size size)
/// <since_tizen> 3 </since_tizen>
/// <returns>A task that represents the asynchronous extracting operation.</returns>
/// <remarks>
- /// If the width is not a multiple of 8, it can be changed by inner process.\n
+ /// If the width is not a multiple of 8, it can be changed by the inner process.\n
/// The width will be a multiple of 8 greater than the set value.
/// </remarks>
/// <param name="path">The path of the media file to extract the thumbnail.</param>
/// <param name="size">The size of the thumbnail.</param>
/// <param name="cancellationToken">The token to stop the operation.</param>
/// <exception cref="ArgumentNullException"><paramref name="path"/> is null.</exception>
- /// <exception cref="FileNotFoundException">Requested <paramref name="path"/> does not exist.</exception>
- /// <exception cref="InvalidOperationException">Internal error occurred.</exception>
- /// <exception cref="UnauthorizedAccessException">Caller does not have required privilege for accessing the <paramref name="path"/>.</exception>
+ /// <exception cref="FileNotFoundException"><paramref name="path"/> does not exist.</exception>
+ /// <exception cref="InvalidOperationException">An internal error occurs.</exception>
+ /// <exception cref="UnauthorizedAccessException">The caller does not have required privilege for accessing the <paramref name="path"/>.</exception>
/// <exception cref="ArgumentOutOfRangeException">
- /// Width or height of <paramref name="size"/> is less than or equal to zero.
+ /// The width or the height of <paramref name="size"/> is less than or equal to zero.
/// </exception>
/// <exception cref="FileFormatException">The specified file is not supported.</exception>
public static Task<ThumbnailExtractionResult> ExtractAsync(string path, Size size,
/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
using System;
using System.IO;
namespace Tizen.Multimedia
{
/// <summary>
- /// The Device API provides functions to query the information of sound devices.
+ /// Provides the ability to query the information of sound devices.
/// </summary>
public class AudioDevice
{
}
/// <summary>
- /// Gets the id of the device.
+ /// Gets the ID of the device.
/// </summary>
/// <value>The id of the device.</value>
public int Id => _id;
private static object _audioDeviceConnectionLock = new object();
/// <summary>
- /// Occurs when the state of connection of an audio device changes.
+ /// Occurs when the state of a connection of an audio device changes.
/// </summary>
public static event EventHandler<AudioDeviceConnectionChangedEventArgs> DeviceConnectionChanged
{
namespace Tizen.Multimedia
{
/// <summary>
- /// Specifies the flag for audio device options.
+ /// Specifies the flags for the audio device options.
/// <para>
/// This enumeration has a <see cref="FlagsAttribute"/> attribute that allows a bitwise combination of its member values.
/// </para>
}
/// <summary>
- /// Specifies audio device type.
+ /// Specifies the audio device types.
/// </summary>
public enum AudioDeviceType
{
/// </summary>
BuiltinMic,
/// <summary>
- /// Audio jack that can be connected to wired accessory such as headphones and headsets.
+ /// Audio jack that can be connected to wired accessories such as headphones and headsets.
/// </summary>
AudioJack,
/// <summary>
- /// Bluetooth Media (A2DP).
+ /// Bluetooth media (A2DP).
/// </summary>
BluetoothMedia,
/// <summary>
/// </summary>
Forwarding,
/// <summary>
- /// USB Audio.
+ /// USB audio.
/// </summary>
UsbAudio,
/// <summary>
- /// Bluetooth Voice (SCO).
+ /// Bluetooth voice (SCO).
/// </summary>
BluetoothVoice
}
/// <summary>
- /// Specifies audio device direction.
+ /// Specifies the audio device directions.
/// </summary>
public enum AudioDeviceIoDirection
{
}
/// <summary>
- /// Specifies audio device state.
+ /// Specifies the audio device states.
/// </summary>
public enum AudioDeviceState
{
}
/// <summary>
- /// Specifies audio volume type.
+ /// Specifies the audio volume types.
/// </summary>
public enum AudioVolumeType
{
}
/// <summary>
- /// Specifies audio stream type.
+ /// Specifies the audio stream types.
/// </summary>
public enum AudioStreamType
{
}
/// <summary>
- /// Specifies change reason of audio stream focus state.
+ /// Specifies the change reasons of the audio stream focus state.
/// </summary>
public enum AudioStreamFocusChangedReason
{
}
/// <summary>
- /// Specifies the flag for audio stream focus options.
+ /// Specifies the flags for the audio stream focus options.
/// <para>
/// This enumeration has a <see cref="FlagsAttribute"/> attribute that allows a bitwise combination of its member values.
/// </para>
}
/// <summary>
- /// Specifies audio stream focus state.
+ /// Specifies the audio stream focus states.
/// </summary>
public enum AudioStreamFocusState
{
}
/// <summary>
- /// Specifies the flag for audio stream behaviors.
+ /// Specifies the flags for the audio stream behaviors.
/// <para>
/// This enumeration has a <see cref="FlagsAttribute"/> attribute that allows a bitwise combination of its member values.
/// </para>
namespace Tizen.Multimedia
{
/// <summary>
- /// Provides the ability to control a sound stream.
+ /// Provides the ability to control the sound stream.
/// </summary>
public class AudioStreamPolicy : IDisposable
{
private Interop.AudioStreamPolicy.FocusStateChangedCallback _focusStateChangedCallback;
/// <summary>
- /// Initializes a new instance of the <see cref="AudioStreamPolicy"/> class with <see cref="AudioStreamType"/>
+ /// Initializes a new instance of the <see cref="AudioStreamPolicy"/> class with <see cref="AudioStreamType"/>
/// </summary>
/// <remarks>
/// To apply the stream policy according to this stream information, the AudioStreamPolicy should
- /// be passed to other APIs related to playback or recording. (e.g., <see cref="Player"/>, <see cref="WavPlayer"/> , etc.)
+ /// be passed to other APIs related to playback or recording. (For example., <see cref="Player"/>, <see cref="WavPlayer"/> , etc.)
/// </remarks>
- /// <param name="streamType">Type of sound stream for which policy needs to be created.</param>
+ /// <param name="streamType">The type of the sound stream for which the policy needs to be created.</param>
/// <exception cref="ArgumentException"><paramref name="streamType"/> is invalid.</exception>
public AudioStreamPolicy(AudioStreamType streamType)
{
}
/// <summary>
- /// Gets the state of focus for playback.
+ /// Gets the state of focus for the playback.
/// </summary>
/// <value>The state of focus for playback.</value>
/// <exception cref="ObjectDisposedException">The <see cref="AudioStreamPolicy"/> has already been disposed of.</exception>
public AudioStreamFocusState PlaybackFocusState => GetFocusState(true);
/// <summary>
- /// Gets the state of focus for recording.
+ /// Gets the state of focus for the recording.
/// </summary>
/// <value>The state of focus for recording.</value>
/// <exception cref="ObjectDisposedException">The <see cref="AudioStreamPolicy"/> has already been disposed of.</exception>
/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
using System;
public AudioVolumeType Type { get; }
/// <summary>
- /// Gets the new volume.
+ /// Gets the new volume level.
/// </summary>
/// <value>The new volume level.</value>
public int Level { get; }
namespace Tizen.Multimedia
{
-
/// <summary>
/// Provides a means to control volume levels.
/// </summary>
/// -or-
/// <paramref name="value"/> is greater than <see cref="MaxVolumeLevel.this[AudioVolumeType]"/>.
/// </exception>
- /// <exception cref="UnauthorizedAccessException">Caller does not have required privilege to set volume.</exception>
+ /// <exception cref="UnauthorizedAccessException">The caller does not have required privilege to set volume.</exception>
public int this[AudioVolumeType type]
{
get
if (!bufferOwner.IsBufferAccessible(buffer, MediaBufferAccessMode.Write))
{
- throw new InvalidOperationException("The buffer is not in writable state.");
+ throw new InvalidOperationException("The buffer is not in the writable state.");
}
}
}
public bool IsReadOnly { get; }
/// <summary>
- /// Validates the range
+ /// Validates the range.
/// </summary>
/// <param name="offset"></param>
/// <param name="length"></param>
/// <exception cref="ArgumentOutOfRangeException">
- /// offset + length is greater than <see cref="Length"/>.
+ /// The offset + length is greater than <see cref="Length"/>.
/// <para>-or-</para>
- /// offset or length is less than zero.
+ /// The offset or length is less than zero.
/// </exception>
private void ValidateRange(int offset, int length)
{
namespace Tizen.Multimedia
{
/// <summary>
- /// Specifies whether a codec is audio codec or video codec.
+ /// Specifies whether a codec is an audio codec or a video codec.
/// </summary>
public enum CodecKind
{
/// <summary>
- /// Audio codec
+ /// Audio codec.
/// </summary>
Audio,
/// <summary>
- /// Video codec
+ /// Video codec.
/// </summary>
Video
}
public enum ColorSpace
{
/// <summary>
- /// Y800
+ /// Y800.
/// </summary>
Y800,
/// <summary>
- /// I420
+ /// I420.
/// </summary>
I420,
/// <summary>
- /// NV12
+ /// NV12.
/// </summary>
NV12,
/// <summary>
- /// NV16
+ /// NV16.
/// </summary>
NV16,
/// <summary>
- /// NV21
+ /// NV21.
/// </summary>
NV21,
/// <summary>
- /// NV61
+ /// NV61.
/// </summary>
NV61,
/// <summary>
- /// YV12
+ /// YV12.
/// </summary>
///
YV12,
/// <summary>
- /// YUYV
+ /// YUYV.
/// </summary>
Yuyv,
/// <summary>
- /// YUV422
+ /// YUV422.
/// </summary>
Yuv422,
/// <summary>
- /// UYVY
+ /// UYVY.
/// </summary>
Uyvy,
/// <summary>
- /// YUV422P
+ /// YUV422P.
/// </summary>
///
Yuv422P,
/// <summary>
- /// RGB565
+ /// RGB565.
/// </summary>
Rgb565,
/// <summary>
- /// RGB888
+ /// RGB888.
/// </summary>
Rgb888,
/// <summary>
- /// RGBA8888
+ /// RGBA8888.
/// </summary>
Rgba8888,
/// <summary>
- /// ARGB8888
+ /// ARGB8888.
/// </summary>
Argb8888,
/// <summary>
- /// BGRA8888
+ /// BGRA8888.
/// </summary>
Bgra8888,
/// <summary>
- /// BGRX8888
+ /// BGRX8888.
/// </summary>
Bgrx8888
internal enum DisplayType
{
/// <summary>
- /// Overlay surface display
+ /// Overlay surface display.
/// </summary>
Overlay,
/// <summary>
- /// Evas image object surface display
+ /// Evas image object surface display.
/// </summary>
Surface,
/// <summary>
- /// This disposes off buffers
+ /// This disposes off buffers.
/// </summary>
None,
}
{
/// <summary>
/// The exception that is thrown when an input file or a data stream that is supposed to conform
- /// to a certain file format specification is malformed.
+ /// to a certain file format specification, is malformed.
/// </summary>
public class FileFormatException : FormatException
{
namespace Tizen.Multimedia
{
/// <summary>
- /// Provides functionality to read and write a media buffer.
+ /// Provides functionality to read and write the media buffer.
/// </summary>
public interface IMediaBuffer
{
/// </summary>
/// <param name="index">The index of the value to get or set.</param>
/// <exception cref="ArgumentOutOfRangeException">
- /// index is less than zero.\n
+ /// <paramref name="index"/> is less than zero.\n
/// -or-\n
- /// index is equal to or greater than <see cref="Length"/>.
+ /// <paramref name="index"/> is equal to or greater than <see cref="Length"/>.
/// </exception>
- /// <exception cref="ObjectDisposedException">The object that owns the current buffer already has been disposed of.</exception>
- /// <exception cref="InvalidOperationException">The buffer is not available. i.e. not writable state.</exception>
+ /// <exception cref="ObjectDisposedException">The object that owns the current buffer has already been disposed of.</exception>
+ /// <exception cref="InvalidOperationException">The buffer is not available, i.e. not writable state.</exception>
byte this[int index]
{
get;
/// <param name="dest">The array to copy to.</param>
/// <param name="startIndex">The zero-based index in the source array where copying should start.</param>
/// <param name="length">The number of array elements to copy.</param>
- /// <exception cref="ArgumentOutOfRangeException">startIndex or length is not valid.</exception>
- /// <exception cref="ObjectDisposedException">The object that owns the current buffer already has been disposed of.</exception>
+ /// <exception cref="ArgumentNullException"><paramref name="dest"/> is null.</exception>
+ /// <exception cref="ArgumentOutOfRangeException"><paramref name="startIndex"/> or <paramref name="length"/> is not valid.</exception>
+ /// <exception cref="ObjectDisposedException">The object that owns the current buffer has already been disposed of.</exception>
void CopyTo(byte[] dest, int startIndex, int length);
/// <summary>
/// <param name="startIndex">The zero-based index in the source array where copying should start.</param>
/// <param name="length">The number of array elements to copy.</param>
/// <param name="offset">The zero-based index in the buffer where copying should start.</param>
- /// <exception cref="ArgumentOutOfRangeException">startIndex, offset or length is not valid.</exception>
- /// <exception cref="ObjectDisposedException">The object that owns the current buffer already has been disposed of.</exception>
+ /// <exception cref="ArgumentNullException"><paramref name="dest"/> is null.</exception>
+ /// <exception cref="ArgumentOutOfRangeException"><paramref name="startIndex"/>, <paramref name="length"/>,
+ /// or <paramref name="offset"/> is not valid.</exception>
+ /// <exception cref="ObjectDisposedException">The object that owns the current buffer has already been disposed of.</exception>
void CopyTo(byte[] dest, int startIndex, int length, int offset);
/// <summary>
/// Copies data from the buffer to a byte array.
/// </summary>
/// <param name="source">The array to copy from.</param>
- /// <param name="startIndex">The zero-based index in the dest array where copying should start.</param>
+ /// <param name="startIndex">The zero-based index in the destination array where copying should start.</param>
/// <param name="length">The number of elements to copy.</param>
- /// <exception cref="ArgumentOutOfRangeException">startIndex or length is not valid.</exception>
- /// <exception cref="ObjectDisposedException">The object that owns the current buffer already has been disposed of.</exception>
+ /// <exception cref="ArgumentNullException"><paramref name="source"/> is null.</exception>
+ /// <exception cref="ArgumentOutOfRangeException"><paramref name="startIndex"/> or <paramref name="length"/> is not valid.</exception>
+ /// <exception cref="ObjectDisposedException">The object that owns the current buffer has already been disposed of.</exception>
/// <exception cref="InvalidOperationException">The buffer is not available. i.e. not writable state.</exception>
-
void CopyFrom(byte[] source, int startIndex, int length);
/// <summary>
/// Copies data from the buffer to a byte array.
/// </summary>
/// <param name="source">The array to copy from.</param>
- /// <param name="startIndex">The zero-based index in the dest array where copying should start.</param>
+ /// <param name="startIndex">The zero-based index in the destination array where copying should start.</param>
/// <param name="length">The number of elements to copy.</param>
/// <param name="offset">The zero-based index in the buffer where copying should start.</param>
- /// <exception cref="ArgumentOutOfRangeException">startIndex, offset or length is not valid.</exception>
- /// <exception cref="ObjectDisposedException">The object that owns the current buffer already has been disposed of.</exception>
+ /// <exception cref="ArgumentNullException"><paramref name="source"/> is null.</exception>
+ /// <exception cref="ArgumentOutOfRangeException"><paramref name="startIndex"/>, <paramref name="length"/>,
+ /// or <paramref name="offset"/> is not valid.</exception>
+ /// <exception cref="ObjectDisposedException">The object that owns the current buffer has already been disposed of.</exception>
/// <exception cref="InvalidOperationException">The buffer is not available. i.e. not writable state.</exception>
void CopyFrom(byte[] source, int startIndex, int length, int offset);
}
namespace Tizen.Multimedia
{
/// <summary>
- /// Represents a point in 2D space.
+ /// Represents a point in the 2D space.
/// </summary>
public struct Point
{
/// <summary>
/// Initializes a new instance of the Point with the specified coordinates.
/// </summary>
- /// <param name="x">X-axis coordinate of the point in 2D space.</param>
- /// <param name="y">Y-axis coordinate of the point in 2D space.</param>
+ /// <param name="x">X-axis coordinate of the point in the 2D space.</param>
+ /// <param name="y">Y-axis coordinate of the point in the 2D space.</param>
public Point(int x, int y)
{
X = x;
}
/// <summary>
- /// Gets or sets X-axis coordinate of the point in 2D space.
+ /// Gets or sets the X-axis coordinate of the point in the 2D space.
/// </summary>
public int X
{
}
/// <summary>
- /// Gets or sets Y-axis coordinate of the point in 2D space.
+ /// Gets or sets the Y-axis coordinate of the point in the 2D space.
/// </summary>
public int Y
{
public struct Range
{
/// <summary>
- /// Initializes a new instance of the Range with the specified values.
+ /// Initializes a new instance of the range with the specified values.
/// </summary>
/// <param name="min">Minimum value of the range.</param>
/// <param name="max">Maximum value of the range.</param>
}
/// <summary>
- /// Gets or sets minimum value of the range.
+ /// Gets or sets the minimum value of the range.
/// </summary>
public int Min
{
}
/// <summary>
- /// Gets or sets maximum value of the range.
+ /// Gets or sets the maximum value of the range.
/// </summary>
public int Max
{
}
/// <summary>
- /// Gets length of the range.
+ /// Gets the length of the range.
/// </summary>
public int Length => Max - Min;
/// <summary>
- /// Determines if the specified value is inside of the range.
+ /// Determines if the specified value is within the range.
/// </summary>
- /// <param name="value">A value to check.</param>
- /// <returns>true if the value is inside of the range; otherwise false.</returns>
+ /// <param name="value">The value to check.</param>
+ /// <returns>true if the value is within the range; otherwise false.</returns>
public bool IsInside(int value)
{
return Min <= value && value <= Max;
namespace Tizen.Multimedia
{
/// <summary>
- /// This class represents location of the object bounded by rectangle defined by
+ /// Represents the location of the object bounded by a rectangle defined by
/// coordinates of top left corner, width and height.
/// </summary>
public struct Rectangle
private Size _size;
/// <summary>
- /// Initializes a new instance of the Rectangle with the specified values.
+ /// Initializes a new instance of the <see cref="Rectangle"/> with the specified values.
/// </summary>
/// <param name="x">The x-coordinate of the upper-left corner of the rectangle.</param>
/// <param name="y">The y-coordinate of the upper-left corner of the rectangle.</param>
}
/// <summary>
- /// Initializes a new instance of the Rectangle with the specified values.
+ /// Initializes a new instance of the <see cref="Rectangle"/> with the specified values.
/// </summary>
/// <param name="location">A <see cref="Location"/> that represents the upper-left corner of the rectangular region.</param>
/// <param name="size">A <see cref="Size"/> that represents the width and height of the rectangular region.</param>
public struct Size
{
/// <summary>
- /// Initializes a new instance of the Size with the specified values.
+ /// Initializes a new instance of the <see cref="Size"/> with the specified values.
/// </summary>
/// <param name="width">Width of the size.</param>
/// <param name="height">Height of the size.</param>
}
/// <summary>
- /// Gets or sets the width of the Size.
+ /// Gets or sets the width.
/// </summary>
public int Width
{
}
/// <summary>
- /// Gets or sets the height of the Size.
+ /// Gets or sets the height.
/// </summary>
public int Height
{
/// <summary>
/// Initializes a new instance of the AudioMediaFormat class with the specified mime type,
- /// channel, sample rate, bit and bit rate.
+ /// channel, sample rate, bit, and bit rate.
/// </summary>
/// <param name="mimeType">The mime type of the format.</param>
/// <param name="channel">The channel value of the format.</param>
/// <param name="bitRate">The bit rate value of the format.</param>
/// <exception cref="ArgumentException"><paramref name="mimeType"/> is invalid(i.e. undefined value).</exception>
/// <exception cref="ArgumentOutOfRangeException">
- /// <paramref name="channel"/>, <paramref name="sampleRate"/>, <paramref name="bit"/> or <paramref name="bitRate"/> is less than zero.
+ /// <paramref name="channel"/>, <paramref name="sampleRate"/>, <paramref name="bit"/>, or <paramref name="bitRate"/> is less than zero.
/// </exception>
public AudioMediaFormat(MediaFormatAudioMimeType mimeType,
int channel, int sampleRate, int bit, int bitRate)
/// <summary>
/// Initializes a new instance of the AudioMediaFormat class with the specified mime type,
- /// channel, sample rate, bit, bit rate and aac type.
+ /// channel, sample rate, bit, bit rate, and AAC type.
/// </summary>
/// <param name="mimeType">The mime type of the format.</param>
/// <param name="channel">The channel value of the format.</param>
/// <param name="bitRate">The bit rate value of the format.</param>
/// <param name="aacType">The AAC bitstream format(ADIF or ADTS).</param>
/// <exception cref="ArgumentException">
- /// <paramref name="mimeType"/> or <paramref name="aacType"/> is invalid(i.e. undefined value).\n
+ /// <paramref name="mimeType"/> or <paramref name="aacType"/> is invalid (i.e. undefined value).\n
/// -or-\n
- /// <paramref name="aacType"/> is not <see cref="MediaFormatAacType.None"/>, but <paramref name="mimeType"/> is one of aac types.
+ /// <paramref name="aacType"/> is not <see cref="MediaFormatAacType.None"/>, but <paramref name="mimeType"/> is one of the AAC types.
/// </exception>
/// <exception cref="ArgumentOutOfRangeException">
- /// <paramref name="channel"/>, <paramref name="sampleRate"/>, <paramref name="bit"/> or <paramref name="bitRate"/> is less than zero.
+ /// <paramref name="channel"/>, <paramref name="sampleRate"/>, <paramref name="bit"/>, or <paramref name="bitRate"/> is less than zero.
/// </exception>
public AudioMediaFormat(MediaFormatAudioMimeType mimeType,
int channel, int sampleRate, int bit, int bitRate, MediaFormatAacType aacType)
}
/// <summary>
- /// Returns an indication whether a specified mime type is a aac type.
+ /// Returns an indication whether a specified mime type is an AAC type.
/// </summary>
/// <param name="mimeType">A mime type.</param>
private static bool IsAacSupportedMimeType(MediaFormatAudioMimeType mimeType)
}
/// <summary>
- /// Retrieves audio properties of media format from a native handle.
+ /// Retrieves audio properties of the media format from a native handle.
/// </summary>
- /// <param name="handle">A native handle that properties are retrieved from.</param>
- /// <param name="mimeType">An out parameter for mime type.</param>
- /// <param name="channel">An out parameter for channel.</param>
- /// <param name="sampleRate">An out parameter for sample rate.</param>
- /// <param name="bit">An out parameter for bit.</param>
- /// <param name="bitRate">An out parameter for bit rate.</param>
+ /// <param name="handle">A native handle that the properties are retrieved from.</param>
+ /// <param name="mimeType">An out parameter for the mime type.</param>
+ /// <param name="channel">An out parameter for the channel.</param>
+ /// <param name="sampleRate">An out parameter for the sample rate.</param>
+ /// <param name="bit">An out parameter for the bit.</param>
+ /// <param name="bitRate">An out parameter for the bit rate.</param>
private static void GetInfo(IntPtr handle, out MediaFormatAudioMimeType mimeType,
out int channel, out int sampleRate, out int bit, out int bitRate)
{
}
/// <summary>
- /// Retrieves aac type value from a native handle.
+ /// Retrieves the AAC type value from a native handle.
/// </summary>
- /// <param name="handle">A native handle that properties are retrieved from.</param>
- /// <param name="aacType">An out parameter for aac type.</param>
+ /// <param name="handle">A native handle that the properties are retrieved from.</param>
+ /// <param name="aacType">An out parameter for tha AAC type.</param>
private static void GetAacType(IntPtr handle, out MediaFormatAacType aacType)
{
Debug.Assert(handle != IntPtr.Zero, "The handle is invalid!");
public int BitRate { get; }
/// <summary>
- /// Gets the aac type of the current format.
+ /// Gets the AAC type of the current format.
/// </summary>
public MediaFormatAacType AacType { get; }
/// Initializes a new instance of the ContainerMediaFormat class.
/// </summary>
/// <param name="mimeType">The mime type of the container format.</param>
- /// <exception cref="ArgumentException">mimeType is invalid(i.e. undefined value).</exception>
+ /// <exception cref="ArgumentException"><paramref name="mimeType"/> is invalid (i.e. undefined value).</exception>
public ContainerMediaFormat(MediaFormatContainerMimeType mimeType)
: base(MediaFormatType.Container)
{
/// Creates a media format from a native handle.
/// </summary>
/// <param name="handle">A native handle.</param>
- /// <returns>An object of one of subclasses of <see cref="MediaFormat"/>.</returns>
+ /// <returns>An object of one of the subclasses of <see cref="MediaFormat"/>.</returns>
internal static MediaFormat FromHandle(IntPtr handle)
{
if (handle == IntPtr.Zero)
}
/// <summary>
- /// Create a native media format from this object.
+ /// Creates a native media format from this object.
/// </summary>
/// <returns>A converted native handle.</returns>
/// <remarks>The returned handle must be destroyed using <see cref="Interop.MediaFormat.Unref(IntPtr)"/>.</remarks>
}
/// <summary>
- /// Fill out properties of a native media format with the current media format object.
+ /// Fills out properties of a native media format with the current media format object.
/// </summary>
/// <param name="handle">A native handle to be written.</param>
internal abstract void AsNativeHandle(IntPtr handle);
namespace Tizen.Multimedia
{
/// <summary>
- /// Specifies aac types for <see cref="AudioMediaFormat"/>.
- /// </summary>
+ /// Specifies the AAC types for <see cref="AudioMediaFormat"/>.
+ /// </summary>
public enum MediaFormatAacType
{
/// <summary>
- /// Raw, no header
+ /// Raw, no header.
/// </summary>
None,
/// <summary>
- /// ADTS header
+ /// ADTS header.
/// </summary>
Adts,
/// <summary>
- /// ADIF header
+ /// ADIF header.
/// </summary>
Adif
}
}
/// <summary>
- /// Enumeration for media format data type
+ /// Specifies the media format data types.
/// </summary>
internal enum MediaFormatDataType
{
/// <summary>
- /// Encoded type
+ /// Encoded type.
/// </summary>
Encoded = 0x10000000,
/// <summary>
- /// Raw type
+ /// Raw type.
/// </summary>
Raw = 0x20000000,
}
public enum MediaFormatAudioMimeType
{
/// <summary>
- /// AMR, Alias for <see cref="AmrNB"/>.
+ /// AMR, alias for <see cref="AmrNB"/>.
/// </summary>
Amr = (MediaFormatType.Audio | MediaFormatDataType.Encoded | 0x1040),
AmrWB = (MediaFormatType.Audio | MediaFormatDataType.Encoded | 0x1041),
/// <summary>
- /// AAC, Alias for <see cref="AacLC"/>.
+ /// AAC, alias for <see cref="AacLC"/>.
/// </summary>
Aac = (MediaFormatType.Audio | MediaFormatDataType.Encoded | 0x1060),
H263P = (MediaFormatType.Video | MediaFormatDataType.Encoded | 0x2021),
/// <summary>
- /// H264_SP
+ /// H264_SP.
/// </summary>
H264SP = (MediaFormatType.Video | MediaFormatDataType.Encoded | 0x2030),
Mpeg4Asp = (MediaFormatType.Video | MediaFormatDataType.Encoded | 0x2071),
/// <summary>
- /// I420
+ /// I420.
/// </summary>
I420 = (MediaFormatType.Video | MediaFormatDataType.Raw | 0x2510),
public enum MediaFormatContainerMimeType
{
/// <summary>
- /// MP4 container, Video.
+ /// MP4 container, video.
/// </summary>
MP4 = (MediaFormatType.Container | 0x3010),
/// <summary>
- /// AVI container, Video.
+ /// AVI container, video.
/// </summary>
Avi = (MediaFormatType.Container | 0x3020),
/// <summary>
- /// MPEG2TS container, Video.
+ /// MPEG2TS container, video.
/// </summary>
Mpeg2TS = (MediaFormatType.Container | 0x3030),
/// <summary>
- /// MPEG2PS container, Video.
+ /// MPEG2PS container, video.
/// </summary>
Mpeg2PS = (MediaFormatType.Container | 0x3040),
/// <summary>
- /// MATROSKA container, Video.
+ /// MATROSKA container, video.
/// </summary>
Matroska = (MediaFormatType.Container | 0x3050),
/// <summary>
- /// WEBM container, Video.
+ /// WEBM container, video.
/// </summary>
Webm = (MediaFormatType.Container | 0x3060),
/// <summary>
- /// 3GP container, Video.
+ /// 3GP container, video.
/// </summary>
ThreeGP = (MediaFormatType.Container | 0x3070),
/// <summary>
- /// WAV container, Audio.
+ /// WAV container, audio.
/// </summary>
Wav = (MediaFormatType.Container | 0x4010),
/// <summary>
- /// OGG container, Audio
+ /// OGG container, audio
/// </summary>
Ogg = (MediaFormatType.Container | 0x4020),
/// <summary>
- /// AAC_ADTS container, Audio
+ /// AAC_ADTS container, audio
/// </summary>
AacAdts = (MediaFormatType.Container | 0x4030),
/// <summary>
- /// AAC_ADIF container, Audio
+ /// AAC_ADIF container, audio.
/// </summary>
AacAdif = (MediaFormatType.Container | 0x4031),
}
/// <summary>
- /// Enumeration for text mime type
+ /// Specifies the text mime types.
/// </summary>
public enum MediaFormatTextMimeType
{
namespace Tizen.Multimedia
{
/// <summary>
- /// Specifies text types.
+ /// Specifies the text types.
/// </summary>
public enum MediaFormatTextType
{
None,
/// <summary>
- /// The mp4 type.
+ /// MP4.
/// </summary>
MP4,
/// <summary>
- /// The 3gpp type.
+ /// 3GPP.
/// </summary>
ThreeGpp
}
private readonly LockState _lock = new LockState();
/// <summary>
- /// Validate the current object is not locked.
+ /// Validates the current object is not locked.
/// </summary>
/// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed of.</exception>
/// <exception cref="InvalidOperationException">The MediaPacket is in use by another module.</exception>
/// Initializes a new instance of the MediaPacket class with the specified media format.
/// </summary>
/// <param name="format">The media format containing properties for the packet.</param>
- /// <exception cref="ArgumentNullException">format is null.</exception>
+ /// <exception cref="ArgumentNullException"><paramref name="format"/> is null.</exception>
/// <exception cref="ArgumentException">
- /// <see cref="MediaFormatType"/> of the specified format is <see cref="MediaFormatType.Container"/>.</exception>
+ /// The <see cref="MediaFormatType"/> of the specified format is <see cref="MediaFormatType.Container"/>.
+ /// </exception>
/// <exception cref="InvalidOperationException">Operation failed.</exception>
internal MediaPacket(MediaFormat format)
{
/// <summary>
/// Gets or sets the PTS(Presentation Time Stamp) value of the current packet.
/// </summary>
- /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed of.</exception>
/// <exception cref="InvalidOperationException">
- /// The MediaPacket is not writable state which means it being used by another module.</exception>
+ /// The MediaPacket is not in the writable state, which means it is being used by another module.
+ /// </exception>
public ulong Pts
{
get
/// <summary>
/// Gets or sets the DTS(Decoding Time Stamp) value of the current packet.
/// </summary>
- /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed of.</exception>
/// <exception cref="InvalidOperationException">
- /// The MediaPacket is not in writable state which means it being used by another module.</exception>
+ /// The MediaPacket is not in the writable state, which means it is being used by another module.
+ /// </exception>
public ulong Dts
{
get
}
/// <summary>
- /// Gets a value indicating whether the packet is encoded type.
+ /// Gets a value indicating whether the packet is the encoded type.
/// </summary>
- /// <value>true if the packet is encoded type; otherwise, false.</value>
- /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed.</exception>
+ /// <value>true if the packet is the encoded type; otherwise, false.</value>
+ /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed of.</exception>
public bool IsEncoded
{
get
/// Gets the buffer of the packet.
/// </summary>
/// <value>The <see cref="MediaPacketBuffer"/> allocated to the packet.
- /// This property will return null if the packet is raw video format.</value>
- /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed.</exception>
+ /// This property will return null if the packet is in the raw video format.</value>
+ /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed of.</exception>
/// <seealso cref="IsEncoded"/>
/// <seealso cref="VideoPlanes"/>
public MediaPacketBuffer Buffer
/// <summary>
/// Gets or sets a length of data written in the <see cref="Buffer"/>.
/// </summary>
- /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed of.</exception>
/// <exception cref="ArgumentOutOfRangeException">
/// The value specified for this property is less than zero or greater than <see cref="MediaPacketBuffer.Length"/>.</exception>
/// <exception cref="InvalidOperationException">
/// The MediaPacket has <see cref="VideoPlanes"/> instead of <see cref="Buffer"/>.\n
/// -or-\n
- /// The MediaPacket is not in writable state which means it being used by another module.
+ /// The MediaPacket is not in the writable state, which means it is being used by another module.
/// </exception>
public int BufferWrittenLength
{
/// Gets the video planes of the packet.
/// </summary>
/// <value>The <see cref="MediaPacketVideoPlane"/>s allocated to the packet.
- /// This property will return null if the packet is not raw video format.</value>
- /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed.</exception>
+ /// This property will return null if the packet is not in the raw video format.</value>
+ /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed of.</exception>
/// <seealso cref="IsEncoded"/>
/// <seealso cref="Buffer"/>
public MediaPacketVideoPlane[] VideoPlanes
/// <summary>
/// Gets or sets the buffer flags of the packet.
/// </summary>
- /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed.</exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed of.</exception>
/// <exception cref="InvalidOperationException">
- /// The MediaPacket is not in writable state which means it being used by another module.
- /// </exception>
+ /// The MediaPacket is not in the writable state, which means it is being used by another module.
+ /// </exception>
public MediaPacketBufferFlags BufferFlags
{
get
/// Releases all resources used by the <see cref="MediaPacket"/> object.
/// </summary>
/// <exception cref="InvalidOperationException">
- /// The MediaPacket can not be disposed which means it being used by another module.
+ /// The MediaPacket can not be disposed, which means it is being used by another module.
/// </exception>
public void Dispose()
{
}
/// <summary>
- /// Validate the current object has not been disposed of.
+ /// Validates the current object has not been disposed of.
/// </summary>
/// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed of.</exception>
private void ValidateNotDisposed()
/// <summary>
/// Ensures whether the packet is writable.
/// </summary>
- /// <exception cref="ObjectDisposedException">The MediaPacket already has been disposed of.</exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed of.</exception>
/// <exception cref="InvalidOperationException">The MediaPacket is being used by another module.</exception>
internal void EnsureWritableState()
{
/// <summary>
/// Ensures whether the packet is readable.
/// </summary>
- /// <exception cref="ObjectDisposedException">The MediaPacket already has been disposed of.</exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket has already been disposed of.</exception>
internal void EnsureReadableState()
{
ValidateNotDisposed();
}
/// <summary>
- /// Gets a value indicating whether the packet is raw video format.
+ /// Gets a value indicating whether the packet is in the raw video format.
/// </summary>
- /// <value>true if the packet is raw video format; otherwise, false.</value>
+ /// <value>true if the packet is in the raw video format; otherwise, false.</value>
private bool IsVideoPlaneSupported
{
get
/// </summary>
/// <param name="index">The index of the value to get or set.</param>
/// <exception cref="ArgumentOutOfRangeException">
- /// index is less than zero.\n
+ /// <paramref name="index"/> is less than zero.\n
/// -or-\n
- /// index is equal to or greater than <see cref="Length"/>.
+ /// <paramref name="index"/> is equal to or greater than <see cref="Length"/>.
/// </exception>
- /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer already has been disposed of.</exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer has already been disposed of.</exception>
/// <exception cref="InvalidOperationException">The MediaPacket that owns the current buffer is being used by another module.</exception>
public byte this[int index]
{
}
/// <summary>
- /// Validates the range
+ /// Validates the range.
/// </summary>
/// <param name="offset"></param>
/// <param name="length"></param>
/// <exception cref="ArgumentOutOfRangeException">
- /// offset + length is greater than <see cref="Length"/>.\n
+ /// <paramref name="offset"/> + <paramref name="length"/> is greater than <see cref="Length"/>.\n
/// -or-\n
- /// offset or length is less than zero.
+ /// <paramref name="offset"/> or <paramref name="length"/> is less than zero.
/// </exception>
private void ValidateRange(int offset, int length)
{
}
/// <summary>
- /// Copies data from a byte array to the buffer.
+ /// Copies the data from a byte array to the buffer.
/// </summary>
/// <param name="source">The array to copy from.</param>
/// <param name="startIndex">The zero-based index in the source array where copying should start.</param>
/// <param name="length">The number of array elements to copy.</param>
/// <param name="offset">The zero-based index in the buffer where copying should start.</param>
- /// <exception cref="ArgumentOutOfRangeException">startIndex, offset or length is not valid.</exception>
- /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer already has been disposed of.</exception>
+ /// <exception cref="ArgumentOutOfRangeException">
+ /// <paramref name="startIndex"/>, <paramref name="offset"/>, or <paramref name="length"/> is not valid.
+ /// </exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer has already been disposed of.</exception>
public void CopyFrom(byte[] source, int startIndex, int length, int offset = 0)
{
_packet.EnsureReadableState();
}
/// <summary>
- /// Copies data from the buffer to a byte array.
+ /// Copies the data from the buffer to a byte array.
/// </summary>
/// <param name="dest">The array to copy to.</param>
- /// <param name="startIndex">The zero-based index in the dest array where copying should start.</param>
+ /// <param name="startIndex">The zero-based index in the destination array where copying should start.</param>
/// <param name="length">The number of elements to copy.</param>
/// <param name="offset">The zero-based index in the buffer where copying should start.</param>
- /// <exception cref="ArgumentOutOfRangeException">startIndex, offset or length is not valid.</exception>
- /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer already has been disposed of.</exception>
+ /// <exception cref="ArgumentOutOfRangeException">
+ /// <paramref name="startIndex"/>, <paramref name="offset"/>, <paramref name="length"/>, or <paramref name="offset"/> is not valid.
+ /// </exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer has already been disposed of.</exception>
/// <exception cref="InvalidOperationException">The MediaPacket that owns the current buffer is being used by another module.</exception>
public void CopyTo(byte[] dest, int startIndex, int length, int offset = 0)
{
/// <summary>
/// Gets the size of the buffer, in bytes.
/// </summary>
- /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer already has been disposed of.</exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer has already been disposed of.</exception>
public int Length
{
get
public enum MediaPacketBufferFlags
{
/// <summary>
- /// The buffer contains codec initialization or codec specific data instead of media data.
+ /// The buffer contains the codec initialization or the codec specific data instead of the media data.
/// </summary>
CodecConfig = 0x1,
/// <summary>
- /// The buffer indicates the end of stream.
+ /// The buffer indicates the end of the stream.
/// </summary>
EndOfStream = 0x2,
namespace Tizen.Multimedia
{
/// <summary>
- /// Represents a video plane for <see cref="MediaPacket"/>.
- /// This class is used if and only if the format of the packet is raw video.
+ /// Represents a video plane for the <see cref="MediaPacket"/>.
+ /// This class is used if and only if the format of the packet is the raw video.
/// </summary>
public class MediaPacketVideoPlane
{
/// <summary>
/// Gets the buffer of the current video plane.
/// </summary>
- /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer already has been disposed of.</exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer has already been disposed of.</exception>
public MediaPacketBuffer Buffer
{
get
/// <summary>
/// Gets the stride width of the current video plane.
/// </summary>
- /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer already has been disposed of.</exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer has already been disposed of.</exception>
public int StrideWidth
{
get
/// <summary>
/// Gets the stride height of the current video plane.
/// </summary>
- /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer already has been disposed of.</exception>
+ /// <exception cref="ObjectDisposedException">The MediaPacket that owns the current buffer has already been disposed of.</exception>
public int StrideHeight
{
get
/// <param name="mimeType">The mime type of the format.</param>
/// <param name="textType">The text type of the format.</param>
/// <exception cref="ArgumentException">
- /// mimeType or textType is invalid(i.e. undefined value).</exception>
+ /// <paramref name="mimeType"/> or <paramref name="textType"/> is invalid (i.e. undefined value).
+ /// </exception>
public TextMediaFormat(MediaFormatTextMimeType mimeType, MediaFormatTextType textType)
: base(MediaFormatType.Text)
{
}
/// <summary>
- /// Retrieves text properties of media format from a native handle.
+ /// Retrieves text properties of the media format from a native handle.
/// </summary>
- /// <param name="handle">A native handle that properties are retrieved from.</param>
- /// <param name="mimeType">An out parameter for mime type.</param>
- /// <param name="textType">An out parameter for text type.</param>
+ /// <param name="handle">A native handle that the properties are retrieved from.</param>
+ /// <param name="mimeType">An out parameter for the mime type.</param>
+ /// <param name="textType">An out parameter for the text type.</param>
private static void GetInfo(IntPtr handle, out MediaFormatTextMimeType mimeType,
out MediaFormatTextType textType)
{
private const int DefaultBitRate = 0;
/// <summary>
- /// Initializes a new instance of the VideoMediaFormat class with the specified mime type, width and height.
+ /// Initializes a new instance of the VideoMediaFormat class with the specified mime type, width, and height.
/// </summary>
/// <param name="mimeType">The mime type of the format.</param>
/// <param name="width">The width value of the format.</param>
/// <param name="height">The height value of the format</param>
- /// <exception cref="ArgumentException">mimeType is invalid(i.e. undefined value).</exception>
- /// <exception cref="ArgumentOutOfRangeException">width, or height is less than zero.</exception>
+ /// <exception cref="ArgumentException"><paramref name="mimeType"/> is invalid (i.e. undefined value).</exception>
+ /// <exception cref="ArgumentOutOfRangeException"><paramref name="width"/> or <paramref name="height"/> is less than zero.</exception>
public VideoMediaFormat(MediaFormatVideoMimeType mimeType, int width, int height)
: this(mimeType, width, height, DefaultFrameRate)
{
/// </summary>
/// <param name="mimeType">The mime type of the format.</param>
/// <param name="size">The size of the format.</param>
- /// <exception cref="ArgumentException">mimeType is invalid(i.e. undefined value).</exception>
- /// <exception cref="ArgumentOutOfRangeException">width, or height is less than zero.</exception>
+ /// <exception cref="ArgumentException"><paramref name="mimeType"/> is invalid (i.e. undefined value).</exception>
+ /// <exception cref="ArgumentOutOfRangeException">The width or the height of <paramref name="size"/> is less than zero.</exception>
public VideoMediaFormat(MediaFormatVideoMimeType mimeType, Size size)
: this(mimeType, size, DefaultFrameRate)
{
/// <summary>
/// Initializes a new instance of the VideoMediaFormat class with the specified mime type,
- /// width, height and frame rate.
+ /// width, height, and frame rate.
/// </summary>
/// <param name="mimeType">The mime type of the format.</param>
/// <param name="width">The width value of the format.</param>
/// <param name="height">The height value of the format</param>
/// <param name="frameRate">The frame rate of the format.</param>
- /// <exception cref="ArgumentException">mimeType is invalid(i.e. undefined value).</exception>
- /// <exception cref="ArgumentOutOfRangeException">width, height or frameRate is less than zero.</exception>
- public VideoMediaFormat(MediaFormatVideoMimeType mimeType, int width, int height,
- int frameRate)
+ /// <exception cref="ArgumentException"><paramref name="mimeType"/> is invalid (i.e. undefined value).</exception>
+ /// <exception cref="ArgumentOutOfRangeException">
+ /// <paramref name="width"/>, <paramref name="height"/>, or <paramref name="frameRate"/> is less than zero.
+ /// </exception>
+ public VideoMediaFormat(MediaFormatVideoMimeType mimeType, int width, int height, int frameRate)
: this(mimeType, width, height, frameRate, DefaultBitRate)
{
}
/// <summary>
/// Initializes a new instance of the VideoMediaFormat class with the specified mime type,
- /// width, height and frame rate.
+ /// width, height, and frame rate.
/// </summary>
/// <param name="mimeType">The mime type of the format.</param>
/// <param name="size">The video size of the format.</param>
/// <param name="frameRate">The frame rate of the format.</param>
- /// <exception cref="ArgumentException">mimeType is invalid(i.e. undefined value).</exception>
- /// <exception cref="ArgumentOutOfRangeException">width, height or frameRate is less than zero.</exception>
+ /// <exception cref="ArgumentException"><paramref name="mimeType"/> is invalid (i.e. undefined value).</exception>
+ /// <exception cref="ArgumentOutOfRangeException">
+ /// The width or the height of <paramref name="size"/> is less than zero.\n
+ /// -or-\n
+ /// <paramref name="frameRate"/> is less than zero.
+ /// </exception>
public VideoMediaFormat(MediaFormatVideoMimeType mimeType, Size size,
int frameRate)
: this(mimeType, size, frameRate, DefaultBitRate)
/// <summary>
/// Initializes a new instance of the VideoMediaFormat class with the specified mime type,
- /// width, height, frame rate and bit rate.
+ /// width, height, frame rate, and bit rate.
/// </summary>
/// <param name="mimeType">The mime type of the format.</param>
/// <param name="width">The width value of the format.</param>
/// <param name="height">The height value of the format</param>
/// <param name="frameRate">The frame rate of the format.</param>
/// <param name="bitRate">The bit rate of the format.</param>
- /// <exception cref="ArgumentException">mimeType is invalid(i.e. undefined value).</exception>
- /// <exception cref="ArgumentOutOfRangeException">width, height, frameRate or bitRate is less than zero.</exception>
+ /// <exception cref="ArgumentException"><paramref name="mimeType"/> is invalid (i.e. undefined value).</exception>
+ /// <exception cref="ArgumentOutOfRangeException">
+ /// <paramref name="width"/>, <paramref name="height"/>, <paramref name="frameRate"/>, or <paramref name="bitRate"/> is less than zero.
+ /// </exception>
public VideoMediaFormat(MediaFormatVideoMimeType mimeType, int width, int height,
int frameRate, int bitRate)
: this(mimeType, new Size(width, height), frameRate, bitRate)
/// <summary>
/// Initializes a new instance of the VideoMediaFormat class with the specified mime type,
- /// size, frame rate and bit rate.
+ /// size, frame rate, and bit rate.
/// </summary>
/// <param name="mimeType">The mime type of the format.</param>
/// <param name="size">The size of the format.</param>
/// <param name="frameRate">The frame rate of the format.</param>
/// <param name="bitRate">The bit rate of the format.</param>
- /// <exception cref="ArgumentException">mimeType is invalid(i.e. undefined value).</exception>
- /// <exception cref="ArgumentOutOfRangeException">width, height, frameRate or bitRate is less than zero.</exception>
+ /// <exception cref="ArgumentException"><paramref name="mimeType"/> is invalid (i.e. undefined value).</exception>
+ /// <exception cref="ArgumentOutOfRangeException">
+ /// The width or the height of <paramref name="size"/> is less than zero.\n
+ /// -or-\n
+ /// <paramref name="frameRate"/> is less than zero.\n
+ /// -or-\n
+ /// <paramref name="bitRate"/> is less than zero.
+ /// </exception>
public VideoMediaFormat(MediaFormatVideoMimeType mimeType, Size size,
int frameRate, int bitRate)
: base(MediaFormatType.Video)
}
/// <summary>
- /// Retrieves video properties of media format from a native handle.
+ /// Retrieves video properties of the media format from a native handle.
/// </summary>
- /// <param name="handle">A native handle that properties are retrieved from.</param>
- /// <param name="width">An out parameter for width.</param>
- /// <param name="height">An out parameter for height.</param>
- /// <param name="bitRate">An out parameter for bit rate.</param>
- /// <param name="mimeType">An out parameter for mime type.</param>
+ /// <param name="handle">A native handle that the properties are retrieved from.</param>
+ /// <param name="width">An out parameter for the width.</param>
+ /// <param name="height">An out parameter for the height.</param>
+ /// <param name="bitRate">An out parameter for the bit rate.</param>
+ /// <param name="mimeType">An out parameter for the mime type.</param>
private static void GetInfo(IntPtr handle, out int width, out int height, out int bitRate,
out MediaFormatVideoMimeType mimeType)
{
/// <summary>
/// Retrieves frame rate from a native handle.
/// </summary>
- /// <param name="handle">A native handle that properties are retrieved from.</param>
- /// <param name="frameRate">An out parameter for frame rate.</param>
+ /// <param name="handle">A native handle that the properties are retrieved from.</param>
+ /// <param name="frameRate">An out parameter for the frame rate.</param>
private static void GetFrameRate(IntPtr handle, out int frameRate)
{
Debug.Assert(handle != IntPtr.Zero, "The handle is invalid!");
namespace Tizen.Multimedia
{
/// <summary>
- /// The MediaView class allows application developers to display the video output on screen.
+ /// The MediaView class allows application developers to display the video output on the screen.
/// </summary>
/// <remarks>
/// This view should not be instantiated directly.\n