--- /dev/null
+/*
+ * 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;
+using Tizen.Multimedia;
+
+internal static partial class Interop
+{
+ internal static partial class AudioEffect
+ {
+ [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_get_equalizer_bands_count")]
+ internal static extern PlayerErrorCode GetEqualizerBandsCount(IntPtr player, out int count);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_set_equalizer_band_level")]
+ internal static extern PlayerErrorCode SetEqualizerBandLevel(IntPtr player, int index, int level);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_get_equalizer_band_level")]
+ internal static extern PlayerErrorCode GetEqualizerBandLevel(IntPtr player, int index, out int level);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_set_equalizer_all_bands")]
+ internal static extern PlayerErrorCode SetEqualizerAllBands(IntPtr player, out int band_levels, int length);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_get_equalizer_level_range")]
+ internal static extern PlayerErrorCode GetEqualizerLevelRange(IntPtr player, out int min, out int max);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_get_equalizer_band_frequency")]
+ internal static extern PlayerErrorCode GetEqualizerBandFrequency(IntPtr player, int index, out int frequency);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_get_equalizer_band_frequency_range")]
+ internal static extern PlayerErrorCode GetEqualizerBandFrequencyRange(IntPtr player, int index, out int range);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_equalizer_clear")]
+ internal static extern PlayerErrorCode EqualizerClear(IntPtr player);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_equalizer_is_available")]
+ internal static extern PlayerErrorCode EqualizerIsAvailable(IntPtr player, out bool available);
+ }
+
+}
--- /dev/null
+/*
+ * 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;
+using Tizen.Multimedia;
+
+internal static partial class Interop
+{
+ internal static partial class Display
+ {
+
+ [DllImport(Libraries.Player, EntryPoint = "player_set_display_mode")]
+ internal static extern PlayerErrorCode SetMode(IntPtr player, PlayerDisplayMode mode);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_get_display_mode")]
+ internal static extern PlayerErrorCode GetMode(IntPtr player, out int mode);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_set_display_visible")]
+ internal static extern PlayerErrorCode SetVisible(IntPtr player, bool visible);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_is_display_visible")]
+ internal static extern PlayerErrorCode IsVisible(IntPtr player, out bool visible);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_set_display_rotation")]
+ internal static extern PlayerErrorCode SetRotation(IntPtr player, PlayerDisplayRotation rotation);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_get_display_rotation")]
+ internal static extern PlayerErrorCode GetRotation(IntPtr player, out int rotation);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_set_display_roi_area")]
+ internal static extern PlayerErrorCode SetRoi(IntPtr player, int x, int y, int width, int height);
+ }
+}
+/*
+ * 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;
using Tizen;
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
internal delegate void SeekCompletedCallback(IntPtr userData);
-
[DllImport(Libraries.Player, EntryPoint = "player_create")]
internal static extern PlayerErrorCode Create(out PlayerHandle player);
[DllImport(Libraries.Player, EntryPoint = "player_get_media_stream_buffer_min_threshold")]
internal static extern PlayerErrorCode GetMediaStreamBufferMinThreshold(IntPtr player, int type, out uint percent);
- [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_get_equalizer_bands_count")]
- internal static extern PlayerErrorCode AudioEffectGetEqualizerBandsCount(IntPtr player, out int count);
-
- [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_set_equalizer_band_level")]
- internal static extern PlayerErrorCode AudioEffectSetEqualizerBandLevel(IntPtr player, int index, int level);
-
- [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_get_equalizer_band_level")]
- internal static extern PlayerErrorCode AudioEffectGetEqualizerBandLevel(IntPtr player, int index, out int level);
-
- [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_set_equalizer_all_bands")]
- internal static extern PlayerErrorCode AudioEffectSetEqualizerAllBands(IntPtr player, out int band_levels, int length);
-
- [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_get_equalizer_level_range")]
- internal static extern PlayerErrorCode AudioEffectGetEqualizerLevelRange(IntPtr player, out int min, out int max);
-
- [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_get_equalizer_band_frequency")]
- internal static extern PlayerErrorCode AudioEffectGetEqualizerBandFrequency(IntPtr player, int index, out int frequency);
-
- [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_get_equalizer_band_frequency_range")]
- internal static extern PlayerErrorCode AudioEffectGetEqualizerBandFrequencyRange(IntPtr player, int index, out int range);
-
- [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_equalizer_clear")]
- internal static extern PlayerErrorCode AudioEffectEqualizerClear(IntPtr player);
-
- [DllImport(Libraries.Player, EntryPoint = "player_audio_effect_equalizer_is_available")]
- internal static extern PlayerErrorCode AudioEffectEqualizerIsAvailable(IntPtr player, out bool available);
-
- [DllImport(Libraries.Player, EntryPoint = "player_set_display_mode")]
- internal static extern PlayerErrorCode SetDisplayMode(IntPtr player, PlayerDisplayMode mode);
-
- [DllImport(Libraries.Player, EntryPoint = "player_get_display_mode")]
- internal static extern PlayerErrorCode GetDisplayMode(IntPtr player, out int mode);
-
- [DllImport(Libraries.Player, EntryPoint = "player_set_display_visible")]
- internal static extern PlayerErrorCode SetDisplayVisible(IntPtr player, bool visible);
-
- [DllImport(Libraries.Player, EntryPoint = "player_is_display_visible")]
- internal static extern PlayerErrorCode IsDisplayVisible(IntPtr player, out bool visible);
-
- [DllImport(Libraries.Player, EntryPoint = "player_set_display_rotation")]
- internal static extern PlayerErrorCode SetDisplayRotation(IntPtr player, PlayerDisplayRotation rotation);
-
- [DllImport(Libraries.Player, EntryPoint = "player_get_display_rotation")]
- internal static extern PlayerErrorCode GetDisplayRotation(IntPtr player, out int rotation);
-
- [DllImport(Libraries.Player, EntryPoint = "player_set_display_roi_area")]
- internal static extern PlayerErrorCode SetDisplayRoi(IntPtr player, int x, int y, int width, int height);
-
[DllImport(Libraries.Player, EntryPoint = "player_get_content_info")]
internal static extern PlayerErrorCode GetContentInfo(IntPtr player, StreamMetadataKey key, out IntPtr value);
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+
using System;
-using static Interop;
+using Native = Interop.AudioEffect;
namespace Tizen.Multimedia
{
bool available = false;
- NativePlayer.AudioEffectEqualizerIsAvailable(Player.Handle, out available).
+ Native.EqualizerIsAvailable(Player.Handle, out available).
ThrowIfFailed("Failed to initialize the AudioEffect");
IsAvailable = available;
}
int count = 0;
- NativePlayer.AudioEffectGetEqualizerBandsCount(Player.Handle, out count).
+ Native.GetEqualizerBandsCount(Player.Handle, out count).
ThrowIfFailed("Failed to initialize the AudioEffect");
int min = 0;
int max = 0;
- NativePlayer.AudioEffectGetEqualizerLevelRange(Player.Handle, out min, out max).
+ Native.GetEqualizerLevelRange(Player.Handle, out min, out max).
ThrowIfFailed("Failed to initialize the AudioEffect");
Count = count;
Log.Debug(PlayerLog.Tag, PlayerLog.Enter);
Player.ValidateNotDisposed();
- NativePlayer.AudioEffectEqualizerClear(Player.Handle).
+ Native.EqualizerClear(Player.Handle).
ThrowIfFailed("Failed to clear equalizer effect");
Log.Debug(PlayerLog.Tag, PlayerLog.Leave);
}
*/
using System;
using System.Diagnostics;
-using static Interop;
+using Native = Interop.AudioEffect;
namespace Tizen.Multimedia
{
int frequency = 0;
int range = 0;
- NativePlayer.AudioEffectGetEqualizerBandFrequency(_owner.Player.Handle, _index, out frequency).
+ Native.GetEqualizerBandFrequency(_owner.Player.Handle, _index, out frequency).
ThrowIfFailed("Failed to initialize equalizer band");
- NativePlayer.AudioEffectGetEqualizerBandFrequencyRange(_owner.Player.Handle, _index, out range).
+ Native.GetEqualizerBandFrequencyRange(_owner.Player.Handle, _index, out range).
ThrowIfFailed("Failed to initialize equalizer band");
Frequency = frequency;
$"but got {value}.");
}
- NativePlayer.AudioEffectSetEqualizerBandLevel(_owner.Player.Handle, _index, value).
+ Native.SetEqualizerBandLevel(_owner.Player.Handle, _index, value).
ThrowIfFailed("Failed to set the level of the equalizer band");
}
_owner.Player.ValidateNotDisposed();
int value = 0;
- NativePlayer.AudioEffectGetEqualizerBandLevel(_owner.Player.Handle, _index, out value).
+ Native.GetEqualizerBandLevel(_owner.Player.Handle, _index, out value).
ThrowIfFailed("Failed to get the level of the equalizer band");
Log.Info(PlayerLog.Tag, "get level : " + value);
return value;
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+
using System;
using System.Diagnostics;
-using static Interop;
+using Native = Interop.Display;
namespace Tizen.Multimedia
{
ValidationUtil.ValidateEnum(typeof(PlayerDisplayMode), value);
- NativePlayer.SetDisplayMode(Player.Handle, value).
+ Native.SetMode(Player.Handle, value).
ThrowIfFailed("Failed to set display mode");
_displayMode = value;
return;
}
- NativePlayer.SetDisplayVisible(Player.Handle, value).
+ Native.SetVisible(Player.Handle, value).
ThrowIfFailed("Failed to set the visible state of the display");
_isVisible = value;
ValidationUtil.ValidateEnum(typeof(PlayerDisplayRotation), value);
- NativePlayer.SetDisplayRotation(Player.Handle, value).
+ Native.SetRotation(Player.Handle, value).
ThrowIfFailed("Failed to set the rotation state of the display");
_rotation = value;
$"The height of the roi can't be less than or equal to zero.");
}
- NativePlayer.SetDisplayRoi(Player.Handle, roi.X, roi.Y, roi.Width, roi.Height).
+ Native.SetRoi(Player.Handle, roi.X, roi.Y, roi.Width, roi.Height).
ThrowIfFailed("Failed to set the roi");
}
}