From: Piotr Tworek
Date: Tue, 3 Mar 2015 06:19:04 +0000 (+0900)
Subject: Migrate multimedia support code to new chromium_impl structure.
X-Git-Tag: submit/tizen/20201118.160233~1125
X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=bb4ed5304b5274739808b488dd296ebfb6282f88;p=platform%2Fframework%2Fweb%2Fchromium-efl.git
Migrate multimedia support code to new chromium_impl structure.
The code implements internal chromium interfaces so it belongs in
chromium part of new project structure. The expectation is it'll be
possible to use it from both xwalk/content_shell and EWK.
Due to the fact that xwalk gyp files
(xwalk/build/xwalk_filename_rules.gypi) exclude files with tizen in
their path from build if tizen gyp variable is set to 0 the code had to
be renamed. These files were renamed to have the "efl" suffix instead, given
that there were no Tizen specific (desktop build also builds them).
This way we still keep the ability to build and test the code on desktop.
Change-Id: Ic967fb97131152494520ac9232b986126918c969
Signed-off-by: Piotr Tworek
Signed-off-by: Taeho Kim
---
diff --git a/tizen_src/build/system.gyp b/tizen_src/build/system.gyp
index 9d8689e..7279a7a 100644
--- a/tizen_src/build/system.gyp
+++ b/tizen_src/build/system.gyp
@@ -216,5 +216,46 @@
}],
],
}, # libtbm
+ {
+ 'target_name': 'gstreamer',
+ 'type': 'none',
+ 'conditions': [
+ ['chromium_efl_tizen_version >= "2.4"', {
+ 'variables': {
+ 'dependent_pkgs': [
+ 'gstreamer-1.0',
+ 'gstreamer-base-1.0',
+ 'gstreamer-app-1.0',
+ 'gstreamer-pbutils-1.0',
+ 'gstreamer-video-1.0',
+ ],
+ },
+ }, { # for Tizen v2.X
+ 'variables': {
+ 'dependent_pkgs': [
+ 'gstreamer-0.10',
+ 'gstreamer-base-0.10',
+ 'gstreamer-app-0.10',
+ 'gstreamer-pbutils-0.10',
+ 'gstreamer-interfaces-0.10',
+ 'gstreamer-video-0.10',
+ ],
+ },
+ }]
+ ],
+ 'direct_dependent_settings': {
+ 'cflags': [
+ '& demuxer,
+ Internal(const scoped_refptr& demuxer,
int demuxer_client_id)
: demuxer_(demuxer),
demuxer_client_id_(demuxer_client_id) { }
@@ -19,8 +20,8 @@ class BrowserDemuxerTizen::Internal : public media::DemuxerTizen {
demuxer_->RemoveDemuxerClient(demuxer_client_id_);
}
- // media::DemuxerTizen implementation.
- virtual void Initialize(media::DemuxerTizenClient* client) override {
+ // media::DemuxerEfl implementation.
+ virtual void Initialize(media::DemuxerEflClient* client) override {
DCHECK(!ClientIDExists()) << demuxer_client_id_;
demuxer_->AddDemuxerClient(demuxer_client_id_, client);
}
@@ -50,18 +51,18 @@ class BrowserDemuxerTizen::Internal : public media::DemuxerTizen {
return demuxer_->demuxer_clients_.Lookup(demuxer_client_id_);
}
- scoped_refptr demuxer_;
+ scoped_refptr demuxer_;
int demuxer_client_id_;
DISALLOW_COPY_AND_ASSIGN(Internal);
};
-BrowserDemuxerTizen::BrowserDemuxerTizen()
- : BrowserMessageFilter(MediaPlayerTizenMsgStart) {}
+BrowserDemuxerEfl::BrowserDemuxerEfl()
+ : BrowserMessageFilter(MediaPlayerEflMsgStart) {}
-BrowserDemuxerTizen::~BrowserDemuxerTizen() {}
+BrowserDemuxerEfl::~BrowserDemuxerEfl() {}
-void BrowserDemuxerTizen::OverrideThreadForMessage(
+void BrowserDemuxerEfl::OverrideThreadForMessage(
const IPC::Message& message,
BrowserThread::ID* thread) {
switch (message.type()) {
@@ -75,9 +76,9 @@ void BrowserDemuxerTizen::OverrideThreadForMessage(
}
}
-bool BrowserDemuxerTizen::OnMessageReceived(const IPC::Message& message) {
+bool BrowserDemuxerEfl::OnMessageReceived(const IPC::Message& message) {
bool handled = true;
- IPC_BEGIN_MESSAGE_MAP(BrowserDemuxerTizen, message)
+ IPC_BEGIN_MESSAGE_MAP(BrowserDemuxerEfl, message)
IPC_MESSAGE_HANDLER(MediaPlayerGstHostMsg_DemuxerReady, OnDemuxerReady)
IPC_MESSAGE_HANDLER(MediaPlayerGstHostMsg_ReadFromDemuxerAck,
OnReadFromDemuxerAck)
@@ -92,67 +93,67 @@ bool BrowserDemuxerTizen::OnMessageReceived(const IPC::Message& message) {
return handled;
}
-scoped_ptr BrowserDemuxerTizen::CreateDemuxer(
+scoped_ptr BrowserDemuxerEfl::CreateDemuxer(
int demuxer_client_id) {
- return scoped_ptr(
+ return scoped_ptr(
new Internal(this, demuxer_client_id));
}
-void BrowserDemuxerTizen::AddDemuxerClient(
+void BrowserDemuxerEfl::AddDemuxerClient(
int demuxer_client_id,
- media::DemuxerTizenClient* client) {
+ media::DemuxerEflClient* client) {
VLOG(1) << __FUNCTION__ << " peer_pid=" << peer_pid()
<< " demuxer_client_id=" << demuxer_client_id;
demuxer_clients_.AddWithID(client, demuxer_client_id);
}
-void BrowserDemuxerTizen::RemoveDemuxerClient(int demuxer_client_id) {
+void BrowserDemuxerEfl::RemoveDemuxerClient(int demuxer_client_id) {
VLOG(1) << __FUNCTION__ << " peer_pid=" << peer_pid()
<< " demuxer_client_id=" << demuxer_client_id;
demuxer_clients_.Remove(demuxer_client_id);
}
-void BrowserDemuxerTizen::OnDemuxerReady(
+void BrowserDemuxerEfl::OnDemuxerReady(
int demuxer_client_id,
const media::DemuxerConfigs& configs) {
- media::DemuxerTizenClient* client =
+ media::DemuxerEflClient* client =
demuxer_clients_.Lookup(demuxer_client_id);
if (client)
client->OnDemuxerConfigsAvailable(configs);
}
-void BrowserDemuxerTizen::OnReadFromDemuxerAck(
+void BrowserDemuxerEfl::OnReadFromDemuxerAck(
int demuxer_client_id,
base::SharedMemoryHandle foreign_memory_handle,
const media::DemuxedBufferMetaData& meta_data) {
- media::DemuxerTizenClient* client =
+ media::DemuxerEflClient* client =
demuxer_clients_.Lookup(demuxer_client_id);
if (client)
client->OnDemuxerDataAvailable(foreign_memory_handle, meta_data);
}
-void BrowserDemuxerTizen::OnBufferMetaDataAck(
+void BrowserDemuxerEfl::OnBufferMetaDataAck(
int demuxer_client_id,
const media::DemuxedBufferMetaData& meta_data) {
- media::DemuxerTizenClient* client =
+ media::DemuxerEflClient* client =
demuxer_clients_.Lookup(demuxer_client_id);
if (client)
client->OnBufferMetaDataAvailable( meta_data);
}
-void BrowserDemuxerTizen::OnDemuxerSeekDone(
+void BrowserDemuxerEfl::OnDemuxerSeekDone(
int demuxer_client_id,
const base::TimeDelta& actual_browser_seek_time) {
- media::DemuxerTizenClient* client =
+ media::DemuxerEflClient* client =
demuxer_clients_.Lookup(demuxer_client_id);
if (client)
client->OnDemuxerSeekDone(actual_browser_seek_time);
}
-void BrowserDemuxerTizen::OnDurationChanged(
+void BrowserDemuxerEfl::OnDurationChanged(
int demuxer_client_id,
const base::TimeDelta& duration) {
- media::DemuxerTizenClient* client =
+ media::DemuxerEflClient* client =
demuxer_clients_.Lookup(demuxer_client_id);
if (client)
client->OnDemuxerDurationChanged(duration);
diff --git a/tizen_src/impl/content/browser/media/tizen/browser_demuxer_tizen.h b/tizen_src/chromium_impl/content/browser/media/efl/browser_demuxer_efl.h
similarity index 68%
rename from tizen_src/impl/content/browser/media/tizen/browser_demuxer_tizen.h
rename to tizen_src/chromium_impl/content/browser/media/efl/browser_demuxer_efl.h
index 64cdec3..c6e60ff 100644
--- a/tizen_src/impl/content/browser/media/tizen/browser_demuxer_tizen.h
+++ b/tizen_src/chromium_impl/content/browser/media/efl/browser_demuxer_efl.h
@@ -2,24 +2,24 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef CONTENT_BROWSER_MEDIA_TIZEN_BROWSER_DEMUXER_TIZEN_H_
-#define CONTENT_BROWSER_MEDIA_TIZEN_BROWSER_DEMUXER_TIZEN_H_
+#ifndef CONTENT_BROWSER_MEDIA_TIZEN_BROWSER_DEMUXER_EFL_H_
+#define CONTENT_BROWSER_MEDIA_TIZEN_BROWSER_DEMUXER_EFl_H_
#include "base/id_map.h"
#include "base/memory/shared_memory.h"
#include "content/public/browser/browser_message_filter.h"
-#include "media/base/tizen/demuxer_tizen.h"
+#include "media/base/efl/demuxer_efl.h"
namespace content {
// Represents the browser process half of an IPC-based demuxer proxy.
-// It vends out media::DemuxerTizen instances that are registered with an
+// It vends out media::DemuxerEfl instances that are registered with an
// end point in the renderer process.
//
-// Refer to RendererDemuxerTizen for the renderer process half.
-class CONTENT_EXPORT BrowserDemuxerTizen : public BrowserMessageFilter {
+// Refer to RendererDemuxerEfl for the renderer process half.
+class CONTENT_EXPORT BrowserDemuxerEfl : public BrowserMessageFilter {
public:
- BrowserDemuxerTizen();
+ BrowserDemuxerEfl();
// BrowserMessageFilter overrides.
virtual void OverrideThreadForMessage(
@@ -30,11 +30,11 @@ class CONTENT_EXPORT BrowserDemuxerTizen : public BrowserMessageFilter {
// Returns an uninitialized demuxer implementation associated with
// |demuxer_client_id|, which can be used to communicate with the real demuxer
// in the renderer process.
- scoped_ptr CreateDemuxer(int demuxer_client_id);
+ scoped_ptr CreateDemuxer(int demuxer_client_id);
protected:
- friend class base::RefCountedThreadSafe;
- virtual ~BrowserDemuxerTizen();
+ friend class base::RefCountedThreadSafe;
+ virtual ~BrowserDemuxerEfl();
private:
class Internal;
@@ -43,7 +43,7 @@ class CONTENT_EXPORT BrowserDemuxerTizen : public BrowserMessageFilter {
// association.
void AddDemuxerClient(
int demuxer_client_id,
- media::DemuxerTizenClient* client);
+ media::DemuxerEflClient* client);
void RemoveDemuxerClient(int demuxer_client_id);
// IPC message handlers.
@@ -64,11 +64,11 @@ class CONTENT_EXPORT BrowserDemuxerTizen : public BrowserMessageFilter {
int demuxer_client_id,
const base::TimeDelta& duration);
- IDMap demuxer_clients_;
+ IDMap demuxer_clients_;
- DISALLOW_COPY_AND_ASSIGN(BrowserDemuxerTizen);
+ DISALLOW_COPY_AND_ASSIGN(BrowserDemuxerEfl);
};
} // namespace content
-#endif // CONTENT_BROWSER_MEDIA_TIZEN_BROWSER_DEMUXER_TIZEN_H_
+#endif // CONTENT_BROWSER_MEDIA_TIZEN_BROWSER_DEMUXER_EFL_H_
diff --git a/tizen_src/impl/content/browser/media/tizen/browser_media_player_manager_tizen.cc b/tizen_src/chromium_impl/content/browser/media/efl/browser_media_player_manager_efl.cc
similarity index 59%
rename from tizen_src/impl/content/browser/media/tizen/browser_media_player_manager_tizen.cc
rename to tizen_src/chromium_impl/content/browser/media/efl/browser_media_player_manager_efl.cc
index 6048ba5..b178e38 100644
--- a/tizen_src/impl/content/browser/media/tizen/browser_media_player_manager_tizen.cc
+++ b/tizen_src/chromium_impl/content/browser/media/efl/browser_media_player_manager_efl.cc
@@ -2,48 +2,48 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "content/browser/media/tizen/browser_media_player_manager_tizen.h"
+#include "content/browser/media/efl/browser_media_player_manager_efl.h"
#include "base/memory/shared_memory.h"
-#include "content/browser/media/tizen/browser_demuxer_tizen.h"
+#include "content/browser/media/efl/browser_demuxer_efl.h"
#include "content/browser/renderer_host/render_process_host_impl.h"
-#include "content/common/media/tizen/media_player_messages_tizen.h"
+#include "content/common/media/efl/media_player_messages_efl.h"
#include "content/public/browser/web_contents.h"
#include "ipc/ipc_channel_proxy.h"
#include "ipc/ipc_logging.h"
-#include "media/base/tizen/media_source_player_gstreamer.h"
+#include "media/base/efl/media_source_player_gstreamer.h"
#if defined(TIZEN_CAPI_PLAYER_SUPPORT) && defined(TIZEN_MULTIMEDIA_PIXMAP_SUPPORT)
#include "media/base/tizen/media_player_bridge_capi.h"
#else
-#include "media/base/tizen/media_player_bridge_gstreamer.h"
+#include "media/base/efl/media_player_bridge_gstreamer.h"
#endif
namespace content {
-BrowserMediaPlayerManagerTizen* BrowserMediaPlayerManagerTizen::Create(
+BrowserMediaPlayerManagerEfl* BrowserMediaPlayerManagerEfl::Create(
RenderFrameHost* rfh) {
- return new BrowserMediaPlayerManagerTizen(rfh);
+ return new BrowserMediaPlayerManagerEfl(rfh);
}
-BrowserMediaPlayerManagerTizen::BrowserMediaPlayerManagerTizen(
+BrowserMediaPlayerManagerEfl::BrowserMediaPlayerManagerEfl(
RenderFrameHost* render_frame_host)
: render_frame_host_(render_frame_host),
web_contents_(WebContents::FromRenderFrameHost(render_frame_host)),
weak_ptr_factory_(this) {
}
-BrowserMediaPlayerManagerTizen::~BrowserMediaPlayerManagerTizen() {
- for (ScopedVector::iterator it = players_.begin();
+BrowserMediaPlayerManagerEfl::~BrowserMediaPlayerManagerEfl() {
+ for (ScopedVector::iterator it = players_.begin();
it != players_.end(); ++it) {
(*it)->Destroy();
}
players_.weak_clear();
}
-media::MediaPlayerTizen* BrowserMediaPlayerManagerTizen::GetPlayer(
+media::MediaPlayerEfl* BrowserMediaPlayerManagerEfl::GetPlayer(
int player_id) {
- for (ScopedVector::iterator it = players_.begin();
+ for (ScopedVector::iterator it = players_.begin();
it != players_.end(); ++it) {
if ((*it)->GetPlayerId() == player_id)
return *it;
@@ -51,7 +51,7 @@ media::MediaPlayerTizen* BrowserMediaPlayerManagerTizen::GetPlayer(
return NULL;
}
-void BrowserMediaPlayerManagerTizen::OnNewFrameAvailable(
+void BrowserMediaPlayerManagerEfl::OnNewFrameAvailable(
int player_id,
base::SharedMemoryHandle foreign_memory_handle,
uint32 length, base::TimeDelta timestamp) {
@@ -60,7 +60,7 @@ void BrowserMediaPlayerManagerTizen::OnNewFrameAvailable(
}
#if defined(TIZEN_MULTIMEDIA_PIXMAP_SUPPORT)
-void BrowserMediaPlayerManagerTizen::OnPlatformSurfaceUpdated(
+void BrowserMediaPlayerManagerEfl::OnPlatformSurfaceUpdated(
int player_id,
int pixmap_id,
base::TimeDelta timestamp) {
@@ -69,25 +69,25 @@ void BrowserMediaPlayerManagerTizen::OnPlatformSurfaceUpdated(
}
#endif
-void BrowserMediaPlayerManagerTizen::OnTimeChanged(int player_id) {
+void BrowserMediaPlayerManagerEfl::OnTimeChanged(int player_id) {
Send(new MediaPlayerGstMsg_TimeChanged(GetRoutingID(), player_id));
}
-void BrowserMediaPlayerManagerTizen::OnPauseStateChange(
+void BrowserMediaPlayerManagerEfl::OnPauseStateChange(
int player_id,
bool state) {
Send(new MediaPlayerGstMsg_OnPauseStateChange(
GetRoutingID(), player_id, state));
}
-void BrowserMediaPlayerManagerTizen::OnSeekStateChange(
+void BrowserMediaPlayerManagerEfl::OnSeekStateChange(
int player_id,
bool state) {
Send(new MediaPlayerGstMsg_OnSeekStateChange(
GetRoutingID(), player_id, state));
}
-void BrowserMediaPlayerManagerTizen::OnRequestSeek(
+void BrowserMediaPlayerManagerEfl::OnRequestSeek(
int player_id,
double seek_time) {
// To handle internal seek.
@@ -95,42 +95,42 @@ void BrowserMediaPlayerManagerTizen::OnRequestSeek(
GetRoutingID(), player_id, seek_time));
}
-void BrowserMediaPlayerManagerTizen::OnTimeUpdate(
+void BrowserMediaPlayerManagerEfl::OnTimeUpdate(
int player_id,
double current_time) {
Send(new MediaPlayerGstMsg_TimeUpdate(
GetRoutingID(), player_id, current_time));
}
-void BrowserMediaPlayerManagerTizen::OnBufferUpdate(
+void BrowserMediaPlayerManagerEfl::OnBufferUpdate(
int player_id,
- std::vector buffer_range) {
+ std::vector buffer_range) {
Send(new MediaPlayerGstMsg_BufferUpdate(
GetRoutingID(), player_id, buffer_range));
}
-void BrowserMediaPlayerManagerTizen::OnDurationChange(
+void BrowserMediaPlayerManagerEfl::OnDurationChange(
int player_id,
double duration) {
Send(new MediaPlayerGstMsg_DurationChanged(
GetRoutingID(), player_id, duration));
}
-void BrowserMediaPlayerManagerTizen::OnReadyStateChange(
+void BrowserMediaPlayerManagerEfl::OnReadyStateChange(
int player_id,
- media::MediaPlayerTizen::ReadyState state) {
+ media::MediaPlayerEfl::ReadyState state) {
Send(new MediaPlayerGstMsg_ReadyStateChange(
GetRoutingID(), player_id, state));
}
-void BrowserMediaPlayerManagerTizen::OnNetworkStateChange(
+void BrowserMediaPlayerManagerEfl::OnNetworkStateChange(
int player_id,
- media::MediaPlayerTizen::NetworkState state) {
+ media::MediaPlayerEfl::NetworkState state) {
Send(new MediaPlayerGstMsg_NetworkStateChange(
GetRoutingID(), player_id, state));
}
-void BrowserMediaPlayerManagerTizen::OnMediaDataChange(
+void BrowserMediaPlayerManagerEfl::OnMediaDataChange(
int player_id,
int format,
int height,
@@ -140,19 +140,19 @@ void BrowserMediaPlayerManagerTizen::OnMediaDataChange(
GetRoutingID(), player_id, format, height, width, media));
}
-int BrowserMediaPlayerManagerTizen::GetRoutingID() {
+int BrowserMediaPlayerManagerEfl::GetRoutingID() {
if (!render_frame_host_)
return 0;
return render_frame_host_->GetRoutingID();
}
-bool BrowserMediaPlayerManagerTizen::Send(IPC::Message* msg) {
+bool BrowserMediaPlayerManagerEfl::Send(IPC::Message* msg) {
if (!render_frame_host_)
return false;
return render_frame_host_->Send(msg);
}
-void BrowserMediaPlayerManagerTizen::OnInitialize(
+void BrowserMediaPlayerManagerEfl::OnInitialize(
int player_id,
MediaPlayerHostMsg_Initialize_Type type,
const GURL& url,
@@ -166,7 +166,7 @@ void BrowserMediaPlayerManagerTizen::OnInitialize(
LOG(INFO) << "MediaElement is using |CAPI| to play media";
AddPlayer(new media::MediaPlayerBridgeCapi(player_id, url, volume, this));
#else
- LOG(INFO) << "MediaElement is using |Gstreamer| to play media";
+ LOG(INFO) << "MediaElement is using |Efl| to play media";
AddPlayer(
new media::MediaPlayerBridgeGstreamer(player_id, url, volume, this));
#endif
@@ -176,64 +176,64 @@ void BrowserMediaPlayerManagerTizen::OnInitialize(
web_contents()->GetRenderProcessHost());
AddPlayer(new media::MediaSourcePlayerGstreamer(
player_id,
- host->browser_demuxer_tizen()->CreateDemuxer(demuxer_client_id),
+ host->browser_demuxer_efl()->CreateDemuxer(demuxer_client_id),
this));
} else {
LOG(ERROR) << __FUNCTION__ << " Load type is wrong!";
}
}
-void BrowserMediaPlayerManagerTizen::OnDestroy(int player_id) {
+void BrowserMediaPlayerManagerEfl::OnDestroy(int player_id) {
VLOG(1) << __FUNCTION__ << " " << player_id;
RemovePlayer(player_id);
}
-void BrowserMediaPlayerManagerTizen::OnPlay(int player_id) {
- media::MediaPlayerTizen* player = GetPlayer(player_id);
+void BrowserMediaPlayerManagerEfl::OnPlay(int player_id) {
+ media::MediaPlayerEfl* player = GetPlayer(player_id);
if (player)
player->Play();
}
-void BrowserMediaPlayerManagerTizen::OnPause(int player_id) {
- media::MediaPlayerTizen* player = GetPlayer(player_id);
+void BrowserMediaPlayerManagerEfl::OnPause(int player_id) {
+ media::MediaPlayerEfl* player = GetPlayer(player_id);
if (player)
player->Pause(false);
}
-void BrowserMediaPlayerManagerTizen::OnSetVolume(
+void BrowserMediaPlayerManagerEfl::OnSetVolume(
int player_id,
double volume) {
- media::MediaPlayerTizen* player = GetPlayer(player_id);
+ media::MediaPlayerEfl* player = GetPlayer(player_id);
if (player)
player->SetVolume(volume);
}
-void BrowserMediaPlayerManagerTizen::OnSetRate(int player_id, double rate) {
- media::MediaPlayerTizen* player = GetPlayer(player_id);
+void BrowserMediaPlayerManagerEfl::OnSetRate(int player_id, double rate) {
+ media::MediaPlayerEfl* player = GetPlayer(player_id);
if (player)
player->SetRate(rate);
}
-void BrowserMediaPlayerManagerTizen::OnSeek(int player_id, double time) {
- media::MediaPlayerTizen* player = GetPlayer(player_id);
+void BrowserMediaPlayerManagerEfl::OnSeek(int player_id, double time) {
+ media::MediaPlayerEfl* player = GetPlayer(player_id);
if (player)
player->Seek(time);
}
-void BrowserMediaPlayerManagerTizen::AddPlayer(
- media::MediaPlayerTizen* player) {
+void BrowserMediaPlayerManagerEfl::AddPlayer(
+ media::MediaPlayerEfl* player) {
DCHECK(!GetPlayer(player->GetPlayerId()));
- VLOG(1) << "BrowserMediaPlayerManagerTizen::" << __FUNCTION__
+ VLOG(1) << "BrowserMediaPlayerManagerEfl::" << __FUNCTION__
<< " Player-Id : " << player->GetPlayerId();
players_.push_back(player);
}
-void BrowserMediaPlayerManagerTizen::RemovePlayer(int player_id) {
- for (ScopedVector::iterator it = players_.begin();
+void BrowserMediaPlayerManagerEfl::RemovePlayer(int player_id) {
+ for (ScopedVector::iterator it = players_.begin();
it != players_.end(); ++it) {
- media::MediaPlayerTizen* player = *it;
+ media::MediaPlayerEfl* player = *it;
if (player->GetPlayerId() == player_id) {
- VLOG(1) << "BrowserMediaPlayerManagerTizen::" << __FUNCTION__
+ VLOG(1) << "BrowserMediaPlayerManagerEfl::" << __FUNCTION__
<< " Player-Id : " << player->GetPlayerId();
players_.weak_erase(it);
player->Destroy();
diff --git a/tizen_src/impl/content/browser/media/tizen/browser_media_player_manager_tizen.h b/tizen_src/chromium_impl/content/browser/media/efl/browser_media_player_manager_efl.h
similarity index 73%
rename from tizen_src/impl/content/browser/media/tizen/browser_media_player_manager_tizen.h
rename to tizen_src/chromium_impl/content/browser/media/efl/browser_media_player_manager_efl.h
index 2456cf8..1178b69 100644
--- a/tizen_src/impl/content/browser/media/tizen/browser_media_player_manager_tizen.h
+++ b/tizen_src/chromium_impl/content/browser/media/efl/browser_media_player_manager_efl.h
@@ -9,24 +9,24 @@
#include "content/public/browser/browser_message_filter.h"
#include "content/public/browser/render_frame_host.h"
#include "content/public/browser/web_contents_observer.h"
-#include "media/base/tizen/media_player_manager_tizen.h"
+#include "media/base/efl/media_player_manager_efl.h"
namespace content {
-// This class manages all the MediaPlayerTizen objects. It receives
+// This class manages all the MediaPlayerEfl objects. It receives
// control operations from the the render process, and forwards
-// them to corresponding MediaPlayerTizen object. Callbacks from
-// MediaPlayerTizen objects are converted to IPCs and then sent to the
+// them to corresponding MediaPlayerEfl object. Callbacks from
+// MediaPlayerEfl objects are converted to IPCs and then sent to the
// render process.
-class CONTENT_EXPORT BrowserMediaPlayerManagerTizen
+class CONTENT_EXPORT BrowserMediaPlayerManagerEfl
: public media::MediaPlayerManager {
public:
// Returns a new instance using the registered factory if available.
- static BrowserMediaPlayerManagerTizen* Create( RenderFrameHost* efh);
- virtual ~BrowserMediaPlayerManagerTizen();
+ static BrowserMediaPlayerManagerEfl* Create( RenderFrameHost* efh);
+ virtual ~BrowserMediaPlayerManagerEfl();
// media::MediaPlayerManager implementation.
- virtual media::MediaPlayerTizen* GetPlayer(int player_id) override;
+ virtual media::MediaPlayerEfl* GetPlayer(int player_id) override;
virtual void OnTimeChanged(int player_id) override;
virtual void OnTimeUpdate(int player_id, double current_time) override;
virtual void OnPauseStateChange(int player_id, bool state) override;
@@ -34,14 +34,14 @@ class CONTENT_EXPORT BrowserMediaPlayerManagerTizen
virtual void OnRequestSeek(int player_id, double seek_time) override;
virtual void OnBufferUpdate(
int player_id,
- std::vector buffer_range) override;
+ std::vector buffer_range) override;
virtual void OnDurationChange(int player_id, double duration) override;
virtual void OnReadyStateChange(
int player_id,
- media::MediaPlayerTizen::ReadyState state) override;
+ media::MediaPlayerEfl::ReadyState state) override;
virtual void OnNetworkStateChange(
int player_id,
- media::MediaPlayerTizen::NetworkState state) override;
+ media::MediaPlayerEfl::NetworkState state) override;
virtual void OnMediaDataChange(
int player_id,
int format,
@@ -60,7 +60,7 @@ class CONTENT_EXPORT BrowserMediaPlayerManagerTizen
base::TimeDelta timestamp) override;
#endif
- // Helper function to handle IPC from RenderMediaPlayerMangaerTizen.
+ // Helper function to handle IPC from RenderMediaPlayerMangaerEfl.
virtual void OnPlay(int player_id);
virtual void OnPause(int player_id);
virtual void OnSetVolume(int player_id, double volume);
@@ -76,9 +76,9 @@ class CONTENT_EXPORT BrowserMediaPlayerManagerTizen
protected:
// Clients must use Create() or subclass constructor.
- explicit BrowserMediaPlayerManagerTizen(RenderFrameHost* render_frame_host);
+ explicit BrowserMediaPlayerManagerEfl(RenderFrameHost* render_frame_host);
- void AddPlayer(media::MediaPlayerTizen* player);
+ void AddPlayer(media::MediaPlayerEfl* player);
void RemovePlayer(int player_id);
// Helper function to send messages to RenderFrameObserver.
@@ -89,12 +89,12 @@ class CONTENT_EXPORT BrowserMediaPlayerManagerTizen
private:
// An array of managed players.
- ScopedVector players_;
+ ScopedVector players_;
RenderFrameHost* render_frame_host_;
WebContents* const web_contents_;
- base::WeakPtrFactory weak_ptr_factory_;
+ base::WeakPtrFactory weak_ptr_factory_;
- DISALLOW_COPY_AND_ASSIGN(BrowserMediaPlayerManagerTizen);
+ DISALLOW_COPY_AND_ASSIGN(BrowserMediaPlayerManagerEfl);
};
} // namespace content
diff --git a/tizen_src/impl/content/browser/media/tizen/webaudio_decoder_browser_gstreamer.cc b/tizen_src/chromium_impl/content/browser/media/efl/webaudio_decoder_browser_gstreamer.cc
similarity index 95%
rename from tizen_src/impl/content/browser/media/tizen/webaudio_decoder_browser_gstreamer.cc
rename to tizen_src/chromium_impl/content/browser/media/efl/webaudio_decoder_browser_gstreamer.cc
index 5bb192c..1d0a6e0 100644
--- a/tizen_src/impl/content/browser/media/tizen/webaudio_decoder_browser_gstreamer.cc
+++ b/tizen_src/chromium_impl/content/browser/media/efl/webaudio_decoder_browser_gstreamer.cc
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "content/browser/media/tizen/webaudio_decoder_browser_gstreamer.h"
+#include "content/browser/media/efl/webaudio_decoder_browser_gstreamer.h"
#include "base/bind.h"
#include "base/strings/string_util.h"
@@ -11,7 +11,7 @@
#include "gst/audio/audio.h"
#include "media/base/audio_bus.h"
#include "media/base/limits.h"
-#include "media/base/tizen/webaudio_media_codec_info_tizen.h"
+#include "media/base/efl/webaudio_media_codec_info_efl.h"
#include "third_party/WebKit/public/platform/WebAudioBus.h"
namespace content {
@@ -51,7 +51,7 @@ void GSTDecoder::InitializeGstDestination(int pcm_output,
uint16_t number_of_channels,
uint32_t sample_rate,
size_t number_of_frames) {
- struct media::WebAudioMediaCodecInfoTizen info = {
+ struct media::WebAudioMediaCodecInfoEfl info = {
static_cast(number_of_channels),
static_cast(sample_rate),
static_cast(number_of_frames)
@@ -331,6 +331,8 @@ GstFlowReturn GSTDecoder::cb_new_buffer (GstAppSink* sink, gpointer user_data) {
ret &= gst_structure_get_int(str, "rate", &rate);
#if !(GST_VERSION_MAJOR == 1)
ret &= gst_structure_get_int(str, "width", &width);
+#else
+ (void)width;
#endif
}
@@ -406,21 +408,21 @@ GstBusSyncReply GSTDecoder::cb_pipeline_message(GstBus* bus,
}
////////////////////////////////////////
-// BrowserMessageFilterTizen class
+// BrowserMessageFilterEfl class
// static
-BrowserMessageFilterTizen* BrowserMessageFilterTizen::GetInstance() {
- return Singleton::get();
+BrowserMessageFilterEfl* BrowserMessageFilterEfl::GetInstance() {
+ return Singleton::get();
}
-BrowserMessageFilterTizen::BrowserMessageFilterTizen()
+BrowserMessageFilterEfl::BrowserMessageFilterEfl()
: gst_thread_("GstThread") {
}
-BrowserMessageFilterTizen::~BrowserMessageFilterTizen() {
+BrowserMessageFilterEfl::~BrowserMessageFilterEfl() {
}
-void BrowserMessageFilterTizen::DecodeUsingGST(
+void BrowserMessageFilterEfl::DecodeUsingGST(
base::SharedMemoryHandle foreign_memory_handle,
base::FileDescriptor pcm_output,
uint32_t data_size) {
@@ -436,7 +438,7 @@ void BrowserMessageFilterTizen::DecodeUsingGST(
data->encodeddata_ = (uint8_t*) (malloc(data_size));
if (!data->encodeddata_) {
- LOG(ERROR) << "BrowserMessageFilterTizen::"<<__FUNCTION__
+ LOG(ERROR) << "BrowserMessageFilterEfl::"<<__FUNCTION__
<< " - encodeddata malloc failed";
delete data;
return;
@@ -463,19 +465,19 @@ void BrowserMessageFilterTizen::DecodeUsingGST(
delete data;
}
-void BrowserMessageFilterTizen::EncodedDataReceived(
+void BrowserMessageFilterEfl::EncodedDataReceived(
base::SharedMemoryHandle foreign_memory_handle,
base::FileDescriptor pcm_output,
uint32_t data_size) {
if (!gst_thread_.IsRunning() && !gst_thread_.Start()) {
- LOG(ERROR) << "BrowserMessageFilterTizen::"<<__FUNCTION__
+ LOG(ERROR) << "BrowserMessageFilterEfl::"<<__FUNCTION__
<< " - Starting GStreamer thread failed";
return;
}
gst_thread_.message_loop()->PostTask(FROM_HERE,
- base::Bind(&BrowserMessageFilterTizen::DecodeUsingGST,
+ base::Bind(&BrowserMessageFilterEfl::DecodeUsingGST,
base::Unretained(this), foreign_memory_handle,
pcm_output, data_size));
}
diff --git a/tizen_src/impl/content/browser/media/tizen/webaudio_decoder_browser_gstreamer.h b/tizen_src/chromium_impl/content/browser/media/efl/webaudio_decoder_browser_gstreamer.h
similarity index 83%
rename from tizen_src/impl/content/browser/media/tizen/webaudio_decoder_browser_gstreamer.h
rename to tizen_src/chromium_impl/content/browser/media/efl/webaudio_decoder_browser_gstreamer.h
index 22d29e8..019a0c6 100644
--- a/tizen_src/impl/content/browser/media/tizen/webaudio_decoder_browser_gstreamer.h
+++ b/tizen_src/chromium_impl/content/browser/media/efl/webaudio_decoder_browser_gstreamer.h
@@ -43,26 +43,26 @@ typedef struct _GstAppData {
GSTDecoder *gst_decoder_;
} GstAppData;
-// BrowserMessageFilterTizen class
-class CONTENT_EXPORT BrowserMessageFilterTizen {
+// BrowserMessageFilterEfl class
+class CONTENT_EXPORT BrowserMessageFilterEfl {
public:
- static BrowserMessageFilterTizen* GetInstance();
+ static BrowserMessageFilterEfl* GetInstance();
void EncodedDataReceived(base::SharedMemoryHandle foreign_memory_handle,
base::FileDescriptor pcm_output,
uint32_t data_size);
private:
- friend struct DefaultSingletonTraits;
- BrowserMessageFilterTizen();
- virtual ~BrowserMessageFilterTizen();
+ friend struct DefaultSingletonTraits;
+ BrowserMessageFilterEfl();
+ virtual ~BrowserMessageFilterEfl();
void DecodeUsingGST(base::SharedMemoryHandle foreign_memory_handle,
base::FileDescriptor pcm_output,
uint32_t data_size);
base::Thread gst_thread_;
- DISALLOW_COPY_AND_ASSIGN(BrowserMessageFilterTizen);
+ DISALLOW_COPY_AND_ASSIGN(BrowserMessageFilterEfl);
};
} // namespace content
diff --git a/tizen_src/impl/content/browser/media/media_web_contents_observer_tizen.cc b/tizen_src/chromium_impl/content/browser/media/media_web_contents_observer_efl.cc
similarity index 63%
rename from tizen_src/impl/content/browser/media/media_web_contents_observer_tizen.cc
rename to tizen_src/chromium_impl/content/browser/media/media_web_contents_observer_efl.cc
index dbc5fdb..75b0750 100644
--- a/tizen_src/impl/content/browser/media/media_web_contents_observer_tizen.cc
+++ b/tizen_src/chromium_impl/content/browser/media/media_web_contents_observer_efl.cc
@@ -2,70 +2,70 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "content/browser/media/media_web_contents_observer_tizen.h"
+#include "content/browser/media/media_web_contents_observer_efl.h"
-#include "content/browser/media/tizen/browser_media_player_manager_tizen.h"
+#include "content/browser/media/efl/browser_media_player_manager_efl.h"
#include "content/browser/renderer_host/render_process_host_impl.h"
-#include "content/common/media/tizen/media_player_messages_tizen.h"
+#include "content/common/media/efl/media_player_messages_efl.h"
#include "content/public/browser/render_frame_host.h"
#include "content/public/browser/web_contents.h"
#include "ipc/ipc_message_macros.h"
namespace content {
-MediaWebContentsObserverTizen::MediaWebContentsObserverTizen(
+MediaWebContentsObserverEfl::MediaWebContentsObserverEfl(
RenderViewHost* render_view_host)
: WebContentsObserver(WebContents::FromRenderViewHost(render_view_host)) {
}
-MediaWebContentsObserverTizen::~MediaWebContentsObserverTizen() {
+MediaWebContentsObserverEfl::~MediaWebContentsObserverEfl() {
}
-void MediaWebContentsObserverTizen::RenderFrameDeleted(
+void MediaWebContentsObserverEfl::RenderFrameDeleted(
RenderFrameHost* render_frame_host) {
uintptr_t key = reinterpret_cast(render_frame_host);
media_player_managers_.erase(key);
}
-bool MediaWebContentsObserverTizen::OnMessageReceived(const IPC::Message& msg,
+bool MediaWebContentsObserverEfl::OnMessageReceived(const IPC::Message& msg,
RenderFrameHost* render_frame_host) {
return OnMediaPlayerMessageReceived(msg, render_frame_host);
}
-bool MediaWebContentsObserverTizen::OnMediaPlayerMessageReceived(
+bool MediaWebContentsObserverEfl::OnMediaPlayerMessageReceived(
const IPC::Message& msg,
RenderFrameHost* render_frame_host) {
bool handled = true;
- IPC_BEGIN_MESSAGE_MAP(MediaWebContentsObserverTizen, msg)
+ IPC_BEGIN_MESSAGE_MAP(MediaWebContentsObserverEfl, msg)
IPC_MESSAGE_FORWARD(MediaPlayerGstHostMsg_Init,
GetMediaPlayerManager(render_frame_host),
- BrowserMediaPlayerManagerTizen::OnInitialize)
+ BrowserMediaPlayerManagerEfl::OnInitialize)
IPC_MESSAGE_FORWARD(MediaPlayerGstHostMsg_DeInit,
GetMediaPlayerManager(render_frame_host),
- BrowserMediaPlayerManagerTizen::OnDestroy)
+ BrowserMediaPlayerManagerEfl::OnDestroy)
IPC_MESSAGE_FORWARD(MediaPlayerGstHostMsg_Play,
GetMediaPlayerManager(render_frame_host),
- BrowserMediaPlayerManagerTizen::OnPlay)
+ BrowserMediaPlayerManagerEfl::OnPlay)
IPC_MESSAGE_FORWARD(MediaPlayerGstHostMsg_Pause,
GetMediaPlayerManager(render_frame_host),
- BrowserMediaPlayerManagerTizen::OnPause)
+ BrowserMediaPlayerManagerEfl::OnPause)
IPC_MESSAGE_FORWARD(MediaPlayerGstHostMsg_SetVolume,
GetMediaPlayerManager(render_frame_host),
- BrowserMediaPlayerManagerTizen::OnSetVolume)
+ BrowserMediaPlayerManagerEfl::OnSetVolume)
IPC_MESSAGE_FORWARD(MediaPlayerGstHostMsg_SetRate,
GetMediaPlayerManager(render_frame_host),
- BrowserMediaPlayerManagerTizen::OnSetRate)
+ BrowserMediaPlayerManagerEfl::OnSetRate)
IPC_MESSAGE_FORWARD(MediaPlayerGstHostMsg_Seek,
GetMediaPlayerManager(render_frame_host),
- BrowserMediaPlayerManagerTizen::OnSeek)
+ BrowserMediaPlayerManagerEfl::OnSeek)
IPC_MESSAGE_UNHANDLED(handled = false)
@@ -73,15 +73,15 @@ bool MediaWebContentsObserverTizen::OnMediaPlayerMessageReceived(
return handled;
}
-BrowserMediaPlayerManagerTizen*
- MediaWebContentsObserverTizen::GetMediaPlayerManager(
+BrowserMediaPlayerManagerEfl*
+ MediaWebContentsObserverEfl::GetMediaPlayerManager(
RenderFrameHost* render_frame_host) {
uintptr_t key = reinterpret_cast(render_frame_host);
if (!media_player_managers_.contains(key)) {
media_player_managers_.set(
key,
make_scoped_ptr(
- BrowserMediaPlayerManagerTizen::Create(render_frame_host)));
+ BrowserMediaPlayerManagerEfl::Create(render_frame_host)));
}
return media_player_managers_.get(key);
}
diff --git a/tizen_src/impl/content/browser/media/media_web_contents_observer_tizen.h b/tizen_src/chromium_impl/content/browser/media/media_web_contents_observer_efl.h
similarity index 73%
rename from tizen_src/impl/content/browser/media/media_web_contents_observer_tizen.h
rename to tizen_src/chromium_impl/content/browser/media/media_web_contents_observer_efl.h
index 928b39a..909a767 100644
--- a/tizen_src/impl/content/browser/media/media_web_contents_observer_tizen.h
+++ b/tizen_src/chromium_impl/content/browser/media/media_web_contents_observer_efl.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef CONTENT_BROWSER_MEDIA_MEDIA_WEB_CONTENTS_OBSERVER_TIZEN_H_
-#define CONTENT_BROWSER_MEDIA_MEDIA_WEB_CONTENTS_OBSERVER_TIZEN_H_
+#ifndef CONTENT_BROWSER_MEDIA_MEDIA_WEB_CONTENTS_OBSERVER_EFL_H_
+#define CONTENT_BROWSER_MEDIA_MEDIA_WEB_CONTENTS_OBSERVER_EFL_H_
#include "base/compiler_specific.h"
#include "base/containers/scoped_ptr_hash_map.h"
@@ -12,18 +12,18 @@
namespace content {
-class BrowserMediaPlayerManagerTizen;
+class BrowserMediaPlayerManagerEfl;
class RenderViewHost;
// This class manages all RenderFrame based media related managers at the
// browser side. It receives IPC messages from media RenderFrameObservers and
// forwards them to the corresponding managers. The managers are responsible
// for sending IPCs back to the RenderFrameObservers at the render side.
-class CONTENT_EXPORT MediaWebContentsObserverTizen
+class CONTENT_EXPORT MediaWebContentsObserverEfl
: public WebContentsObserver {
public:
- explicit MediaWebContentsObserverTizen(RenderViewHost* render_view_host);
- virtual ~MediaWebContentsObserverTizen();
+ explicit MediaWebContentsObserverEfl(RenderViewHost* render_view_host);
+ virtual ~MediaWebContentsObserverEfl();
// WebContentsObserver implementations.
virtual void RenderFrameDeleted(RenderFrameHost* render_frame_host) override;
@@ -37,18 +37,18 @@ class CONTENT_EXPORT MediaWebContentsObserverTizen
// Gets the media player manager associated with |render_frame_host|. Creates
// a new one if it doesn't exist. The caller doesn't own the returned pointer.
- BrowserMediaPlayerManagerTizen* GetMediaPlayerManager(
+ BrowserMediaPlayerManagerEfl* GetMediaPlayerManager(
RenderFrameHost* render_frame_host);
private:
- // Map from RenderFrameHost* to BrowserMediaPlayerManagerTizen.
- typedef base::ScopedPtrHashMap
+ // Map from RenderFrameHost* to BrowserMediaPlayerManagerEfl.
+ typedef base::ScopedPtrHashMap
MediaPlayerManagerMap;
MediaPlayerManagerMap media_player_managers_;
- DISALLOW_COPY_AND_ASSIGN(MediaWebContentsObserverTizen);
+ DISALLOW_COPY_AND_ASSIGN(MediaWebContentsObserverEfl);
};
} // namespace content
-#endif // CONTENT_BROWSER_MEDIA_MEDIA_WEB_CONTENTS_OBSERVER_TIZEN_H_
+#endif // CONTENT_BROWSER_MEDIA_MEDIA_WEB_CONTENTS_OBSERVER_EFL_H_
diff --git a/tizen_src/impl/cache_params_efl.h b/tizen_src/chromium_impl/content/common/cache_params_efl.h
similarity index 100%
rename from tizen_src/impl/cache_params_efl.h
rename to tizen_src/chromium_impl/content/common/cache_params_efl.h
diff --git a/tizen_src/impl/content/common/gpu/media/tizen/tizen_video_decode_accelerator.cc b/tizen_src/chromium_impl/content/common/gpu/media/efl/tizen_video_decode_accelerator.cc
similarity index 98%
rename from tizen_src/impl/content/common/gpu/media/tizen/tizen_video_decode_accelerator.cc
rename to tizen_src/chromium_impl/content/common/gpu/media/efl/tizen_video_decode_accelerator.cc
index d79e7e6..a7b7ce5 100644
--- a/tizen_src/impl/content/common/gpu/media/tizen/tizen_video_decode_accelerator.cc
+++ b/tizen_src/chromium_impl/content/common/gpu/media/efl/tizen_video_decode_accelerator.cc
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "content/common/gpu/media/tizen/tizen_video_decode_accelerator.h"
+#include "content/common/gpu/media/efl/tizen_video_decode_accelerator.h"
#include
#include
@@ -39,17 +39,21 @@ struct GstElementDeleter {
};
// Gstreamer elements and names.
+#if defined(OS_TIZEN)
const char* kDecoderName = "decoder";
#if GST_VERSION_MAJOR == 1
const char* kDecoderGstElement = "omxh264dec";
#else
const char* kDecoderGstElement = "omx_h264dec";
#endif
+#endif // OS_TIZEN
// Generating Unique Key from given width and height.
+#if defined(TIZEN_MULTIMEDIA_PIXMAP_SUPPORT)
int32 ConvertWidthAndHeightToKey(int width, int height) {
return ((width << 16) | height);
}
+#endif // TIZEN_MULTIMEDIA_PIXMAP_SUPPORT
} // namespace
namespace content {
@@ -113,8 +117,8 @@ struct TizenVideoDecodeAccelerator::Impl {
sink_(NULL),
appsrc_(NULL),
io_message_loop_proxy_(base::MessageLoopProxy::current()),
- bitstream_buffer_id_(0),
- gst_thread_("TizenDecoderThreadGst")
+ gst_thread_("TizenDecoderThreadGst"),
+ bitstream_buffer_id_(0)
#if defined(TIZEN_MULTIMEDIA_PIXMAP_SUPPORT)
,pixmap_id_(0),
gst_width_(0),
@@ -251,13 +255,15 @@ bool TizenVideoDecodeAccelerator::Initialize(
GError* error = NULL;
GstCaps* video_caps = NULL;
GstElement* gst_decoder = NULL;
- GstElement* gst_parser = NULL;
GstBus* gst_bus = NULL;
+#if defined(OS_TIZEN)
GstPad* video_sink_pad = NULL;
+ GstElement* gst_parser = NULL;
#if !defined(TIZEN_MULTIMEDIA_PIXMAP_SUPPORT)
GstElement* video_filter_ = NULL;
GstElement* gst_converter = NULL;
#endif
+#endif
scoped_ptr gst_pipeline;
static GstAppSrcCallbacks appsrc_callbacks =
{&Impl::StartFeed, &Impl::StopFeed, NULL};
@@ -692,7 +698,7 @@ GstFlowReturn TizenVideoDecodeAccelerator::Impl::OnDecoded(
void TizenVideoDecodeAccelerator::Impl::CreateAppSinkElement() {
GstAppSinkCallbacks appsink_callbacks =
- {NULL, NULL, &OnDecoded, NULL};
+ { NULL, NULL, &OnDecoded };
if (!(sink_ = gst_element_factory_make("appsink", "sink"))) {
LOG(ERROR) << __FUNCTION__ << "Appsink could not be created";
@@ -916,7 +922,7 @@ void TizenVideoDecodeAccelerator::OnDecode(
}
// lifecycle of buffer_ref will be handled by gstreamer.
- buffer_ref.release();
+ (void)buffer_ref.release();
}
void TizenVideoDecodeAccelerator::NotifyError(
diff --git a/tizen_src/impl/content/common/gpu/media/tizen/tizen_video_decode_accelerator.h b/tizen_src/chromium_impl/content/common/gpu/media/efl/tizen_video_decode_accelerator.h
similarity index 100%
rename from tizen_src/impl/content/common/gpu/media/tizen/tizen_video_decode_accelerator.h
rename to tizen_src/chromium_impl/content/common/gpu/media/efl/tizen_video_decode_accelerator.h
diff --git a/tizen_src/impl/content/common/gpu/media/tizen/tizen_video_encode_accelerator.cc b/tizen_src/chromium_impl/content/common/gpu/media/efl/tizen_video_encode_accelerator.cc
similarity index 99%
rename from tizen_src/impl/content/common/gpu/media/tizen/tizen_video_encode_accelerator.cc
rename to tizen_src/chromium_impl/content/common/gpu/media/efl/tizen_video_encode_accelerator.cc
index 2db7941..cd76329 100644
--- a/tizen_src/impl/content/common/gpu/media/tizen/tizen_video_encode_accelerator.cc
+++ b/tizen_src/chromium_impl/content/common/gpu/media/efl/tizen_video_encode_accelerator.cc
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "content/common/gpu/media/tizen/tizen_video_encode_accelerator.h"
+#include "content/common/gpu/media/efl/tizen_video_encode_accelerator.h"
#include
#include
@@ -518,7 +518,6 @@ bool TizenVideoEncodeAccelerator::StartEncoder() {
GError* error = NULL;
GstCaps* appsrc_caps = NULL;
GstElement* gst_appsink = NULL;
- gboolean retval = FALSE;
scoped_ptr gst_pipeline;
guint64 max_input_buffer =
@@ -529,7 +528,7 @@ bool TizenVideoEncodeAccelerator::StartEncoder() {
&TizenVideoEncodeAccelerator::Impl::StopFeed,
NULL };
GstAppSinkCallbacks appsink_callbacks =
- { NULL, NULL, &TizenVideoEncodeAccelerator::Impl::OnEncoded, NULL };
+ { NULL, NULL, &TizenVideoEncodeAccelerator::Impl::OnEncoded };
if (impl_->pipeline_ != NULL) {
return false;
diff --git a/tizen_src/impl/content/common/gpu/media/tizen/tizen_video_encode_accelerator.h b/tizen_src/chromium_impl/content/common/gpu/media/efl/tizen_video_encode_accelerator.h
similarity index 100%
rename from tizen_src/impl/content/common/gpu/media/tizen/tizen_video_encode_accelerator.h
rename to tizen_src/chromium_impl/content/common/gpu/media/efl/tizen_video_encode_accelerator.h
diff --git a/tizen_src/impl/content/common/media/tizen/media_player_messages_tizen.h b/tizen_src/chromium_impl/content/common/media/efl/media_player_messages_efl.h
similarity index 92%
rename from tizen_src/impl/content/common/media/tizen/media_player_messages_tizen.h
rename to tizen_src/chromium_impl/content/common/media/efl/media_player_messages_efl.h
index 3e7fa97..02fc757 100644
--- a/tizen_src/impl/content/common/media/tizen/media_player_messages_tizen.h
+++ b/tizen_src/chromium_impl/content/common/media/efl/media_player_messages_efl.h
@@ -8,17 +8,17 @@
#include "content/common/content_export.h"
#include "ipc/ipc_message_macros.h"
#include "media/base/media_keys.h"
-#include "media/base/tizen/demuxer_stream_player_params_tizen.h"
-#include "media/base/tizen/media_player_manager_tizen.h"
+#include "media/base/efl/demuxer_stream_player_params_efl.h"
+#include "media/base/efl/media_player_manager_efl.h"
#include "ui/gfx/rect_f.h"
#undef IPC_MESSAGE_EXPORT
#define IPC_MESSAGE_EXPORT CONTENT_EXPORT
-#define IPC_MESSAGE_START MediaPlayerTizenMsgStart
+#define IPC_MESSAGE_START MediaPlayerEflMsgStart
IPC_ENUM_TRAITS(media::AudioCodec)
-IPC_ENUM_TRAITS(media::MediaPlayerTizen::ReadyState)
-IPC_ENUM_TRAITS(media::MediaPlayerTizen::NetworkState)
+IPC_ENUM_TRAITS(media::MediaPlayerEfl::ReadyState)
+IPC_ENUM_TRAITS(media::MediaPlayerEfl::NetworkState)
IPC_ENUM_TRAITS(media::DemuxerStream::Status)
IPC_ENUM_TRAITS(media::DemuxerStream::Type)
IPC_ENUM_TRAITS(media::VideoCodec)
@@ -53,7 +53,7 @@ IPC_STRUCT_TRAITS_BEGIN(media::SubsampleEntry)
IPC_STRUCT_TRAITS_MEMBER(cypher_bytes)
IPC_STRUCT_TRAITS_END()
-IPC_STRUCT_TRAITS_BEGIN(media::MediaPlayerTizen::TimeRanges)
+IPC_STRUCT_TRAITS_BEGIN(media::MediaPlayerEfl::TimeRanges)
IPC_STRUCT_TRAITS_MEMBER(start)
IPC_STRUCT_TRAITS_MEMBER(end)
IPC_STRUCT_TRAITS_END()
@@ -111,7 +111,7 @@ IPC_MESSAGE_ROUTED2(MediaPlayerGstMsg_OnSeekStateChange,
// Current buffer range.
IPC_MESSAGE_ROUTED2(MediaPlayerGstMsg_BufferUpdate,
int /* player_id */,
- std::vector /*buffer_range*/)
+ std::vector /*buffer_range*/)
// Playback completed.
IPC_MESSAGE_ROUTED1(MediaPlayerGstMsg_TimeChanged,
@@ -120,12 +120,12 @@ IPC_MESSAGE_ROUTED1(MediaPlayerGstMsg_TimeChanged,
// Ready state change.
IPC_MESSAGE_ROUTED2(MediaPlayerGstMsg_ReadyStateChange,
int /* player_id */,
- media::MediaPlayerTizen::ReadyState /* state */)
+ media::MediaPlayerEfl::ReadyState /* state */)
// Network state change.
IPC_MESSAGE_ROUTED2(MediaPlayerGstMsg_NetworkStateChange,
int /* player_id */,
- media::MediaPlayerTizen::NetworkState /* state */)
+ media::MediaPlayerEfl::NetworkState /* state */)
// Gst media data has changed.
IPC_MESSAGE_ROUTED5(MediaPlayerGstMsg_MediaDataChanged,
diff --git a/tizen_src/impl/content/common/media/tizen/media_player_messages_enums_tizen.h b/tizen_src/chromium_impl/content/common/media/efl/media_player_messages_enums_efl.h
similarity index 62%
rename from tizen_src/impl/content/common/media/tizen/media_player_messages_enums_tizen.h
rename to tizen_src/chromium_impl/content/common/media/efl/media_player_messages_enums_efl.h
index c6f9f8f..efb7701 100644
--- a/tizen_src/impl/content/common/media/tizen/media_player_messages_enums_tizen.h
+++ b/tizen_src/chromium_impl/content/common/media/efl/media_player_messages_enums_efl.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef CONTENT_COMMON_MEDIA_MEDIA_PLAYER_MESSAGES_ENUMS_TIZEN_H_
-#define CONTENT_COMMON_MEDIA_MEDIA_PLAYER_MESSAGES_ENUMS_TIZEN_H_
+#ifndef CONTENT_COMMON_MEDIA_MEDIA_PLAYER_MESSAGES_ENUMS_EFL_H_
+#define CONTENT_COMMON_MEDIA_MEDIA_PLAYER_MESSAGES_ENUMS_EFL_H_
// Dictates which type of media playback is being initialized.
enum MediaPlayerHostMsg_Initialize_Type {
@@ -11,4 +11,4 @@ enum MediaPlayerHostMsg_Initialize_Type {
MEDIA_PLAYER_TYPE_MEDIA_SOURCE,
};
-#endif // CONTENT_COMMON_MEDIA_MEDIA_PLAYER_MESSAGES_ENUMS_TIZEN_H_
+#endif // CONTENT_COMMON_MEDIA_MEDIA_PLAYER_MESSAGES_ENUMS_EFL_H_
diff --git a/tizen_src/impl/common/message_generator_efl.cc b/tizen_src/chromium_impl/content/common/message_generator_efl.cc
similarity index 70%
rename from tizen_src/impl/common/message_generator_efl.cc
rename to tizen_src/chromium_impl/content/common/message_generator_efl.cc
index b30c518..570a9fb 100644
--- a/tizen_src/impl/common/message_generator_efl.cc
+++ b/tizen_src/chromium_impl/content/common/message_generator_efl.cc
@@ -4,30 +4,30 @@
// Get basic type definitions.
#define IPC_MESSAGE_IMPL
-#include "common/message_generator_efl.h"
+#include "content/common/message_generator_efl.h"
// Generate constructors.
#include "ipc/struct_constructor_macros.h"
-#include "common/message_generator_efl.h"
+#include "content/common/message_generator_efl.h"
// Generate destructors.
#include "ipc/struct_destructor_macros.h"
-#include "common/message_generator_efl.h"
+#include "content/common/message_generator_efl.h"
// Generate param traits write methods.
#include "ipc/param_traits_write_macros.h"
namespace IPC {
-#include "common/message_generator_efl.h"
+#include "content/common/message_generator_efl.h"
} // namespace IPC
// Generate param traits read methods.
#include "ipc/param_traits_read_macros.h"
namespace IPC {
-#include "common/message_generator_efl.h"
+#include "content/common/message_generator_efl.h"
} // namespace IPC
// Generate param traits log methods.
#include "ipc/param_traits_log_macros.h"
namespace IPC {
-#include "common/message_generator_efl.h"
+#include "content/common/message_generator_efl.h"
} // namespace IPC
diff --git a/tizen_src/impl/common/message_generator_efl.h b/tizen_src/chromium_impl/content/common/message_generator_efl.h
old mode 100755
new mode 100644
similarity index 73%
rename from tizen_src/impl/common/message_generator_efl.h
rename to tizen_src/chromium_impl/content/common/message_generator_efl.h
index abf206e..3a03df0
--- a/tizen_src/impl/common/message_generator_efl.h
+++ b/tizen_src/chromium_impl/content/common/message_generator_efl.h
@@ -5,8 +5,10 @@
// Multiply-included file, hence no include guard.
// efl message generator
-#include "common/render_messages_efl.h"
+#include "content/common/render_messages_efl.h"
+#if !defined(EWK_BRINGUP)
#include "components/editing/content/common/editing_messages.h"
+#endif
#if defined(OS_TIZEN_MOBILE)
-#include "common/tts_messages_efl.h"
+#include "content/common/tts_messages_efl.h"
#endif
diff --git a/tizen_src/chromium_impl/content/common/navigation_policy_params.cc b/tizen_src/chromium_impl/content/common/navigation_policy_params.cc
new file mode 100644
index 0000000..461cc24
--- /dev/null
+++ b/tizen_src/chromium_impl/content/common/navigation_policy_params.cc
@@ -0,0 +1,23 @@
+// Copyright 2014 Samsung Electronics. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "content/common/navigation_policy_params.h"
+
+#include "third_party/WebKit/public/web/WebNavigationPolicy.h"
+
+namespace content {
+
+NavigationPolicyParams::NavigationPolicyParams()
+ : render_view_id(-1)
+ , policy(blink::WebNavigationPolicyIgnore)
+ , type(blink::WebNavigationTypeOther)
+ , should_replace_current_entry(false)
+ , is_main_frame(false)
+ , is_redirect(false) {
+}
+
+NavigationPolicyParams::~NavigationPolicyParams() {
+}
+
+} // namespace content
diff --git a/tizen_src/impl/navigation_policy_params.h b/tizen_src/chromium_impl/content/common/navigation_policy_params.h
similarity index 89%
rename from tizen_src/impl/navigation_policy_params.h
rename to tizen_src/chromium_impl/content/common/navigation_policy_params.h
index d35be98..97aecc9 100644
--- a/tizen_src/impl/navigation_policy_params.h
+++ b/tizen_src/chromium_impl/content/common/navigation_policy_params.h
@@ -11,7 +11,12 @@
#include "third_party/WebKit/public/platform/WebString.h"
#include "url/gurl.h"
+namespace content {
+
struct NavigationPolicyParams {
+ NavigationPolicyParams();
+ ~NavigationPolicyParams();
+
int render_view_id;
GURL url;
std::string httpMethod;
@@ -25,4 +30,6 @@ struct NavigationPolicyParams {
bool is_redirect;
};
+} // namespace content
+
#endif /* POLICY_NAVIGATION_PARAMS_H_ */
diff --git a/tizen_src/impl/common/render_messages_efl.h b/tizen_src/chromium_impl/content/common/render_messages_efl.h
similarity index 92%
rename from tizen_src/impl/common/render_messages_efl.h
rename to tizen_src/chromium_impl/content/common/render_messages_efl.h
index f30b4a3..0de8633 100644
--- a/tizen_src/impl/common/render_messages_efl.h
+++ b/tizen_src/chromium_impl/content/common/render_messages_efl.h
@@ -7,25 +7,29 @@
#include "base/values.h"
#include "ipc/ipc_message_macros.h"
#include "ipc/ipc_channel_handle.h"
+#include "content/common/cache_params_efl.h"
+#include "content/common/navigation_policy_params.h"
#include "content/public/common/common_param_traits.h"
#include "content/public/common/referrer.h"
+#include "content/renderer/print_pages_params.h"
#include "ui/gfx/ipc/gfx_param_traits.h"
+#if !defined(EWK_BRINGUP)
#include "API/ewk_hit_test_private.h"
#include "API/ewk_text_style_private.h"
-#include "cache_params_efl.h"
-#include "navigation_policy_params.h"
-#include "renderer/print_pages_params.h"
+#endif // !EWK_BRINGUP
#include "third_party/WebKit/public/web/WebNavigationPolicy.h"
#include "third_party/WebKit/public/web/WebNavigationType.h"
#include "third_party/WebKit/public/web/WebViewModeEnums.h"
#include "ui/gfx/ipc/gfx_param_traits.h"
#include "url/gurl.h"
+#if !defined(EWK_BRINGUP)
#include "tizen_webview/public/tw_content_security_policy.h"
#include "tizen_webview/public/tw_error.h"
#include "tizen_webview/public/tw_hit_test.h"
#include "tizen_webview/public/tw_settings.h"
#include "tizen_webview/public/tw_wrt.h"
+#endif // !EWK_BRINGUP
#include
#include