summaryrefslogtreecommitdiffstats
path: root/gpu
diff options
context:
space:
mode:
authorapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-03-08 01:54:04 +0000
committerapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-03-08 01:54:04 +0000
commit9ad566288f5f4972570cd52cf6258d2ab0fe5090 (patch)
tree7b209924d32e0c46322893540f1a0f0dc9a389c6 /gpu
parent8544565b68121f3808f612550c9044962aab98f4 (diff)
downloadchromium_src-9ad566288f5f4972570cd52cf6258d2ab0fe5090.zip
chromium_src-9ad566288f5f4972570cd52cf6258d2ab0fe5090.tar.gz
chromium_src-9ad566288f5f4972570cd52cf6258d2ab0fe5090.tar.bz2
Reland r76840 with fix for webkit_gpu dependencies.
Removed GPU plugin. Pepper 3D v2 does not use the GPU plugin. It is integrated with the accelerated compositor. TEST=PPAPI 3D v2 still works, trybots BUG=none Review URL: http://codereview.chromium.org/6635026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@77228 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu')
-rw-r--r--gpu/gpu.gyp20
-rw-r--r--gpu/gpu_plugin/gpu_plugin.cc144
-rw-r--r--gpu/gpu_plugin/gpu_plugin.h31
3 files changed, 0 insertions, 195 deletions
diff --git a/gpu/gpu.gyp b/gpu/gpu.gyp
index 87b17a7..0fb7581 100644
--- a/gpu/gpu.gyp
+++ b/gpu/gpu.gyp
@@ -221,26 +221,6 @@
],
},
{
- 'target_name': 'gpu_plugin',
- 'type': 'static_library',
- 'dependencies': [
- '../base/base.gyp:base',
- 'command_buffer_service',
- ],
- 'include_dirs': [
- '..',
- ],
- 'all_dependent_settings': {
- 'include_dirs': [
- '..',
- ],
- },
- 'sources': [
- 'gpu_plugin/gpu_plugin.cc',
- 'gpu_plugin/gpu_plugin.h',
- ],
- },
- {
'target_name': 'gpu_unittests',
'type': 'executable',
'dependencies': [
diff --git a/gpu/gpu_plugin/gpu_plugin.cc b/gpu/gpu_plugin/gpu_plugin.cc
deleted file mode 100644
index 89be438..0000000
--- a/gpu/gpu_plugin/gpu_plugin.cc
+++ /dev/null
@@ -1,144 +0,0 @@
-// Copyright (c) 2009 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#if defined(OS_WIN)
-#include <windows.h>
-#endif
-
-#include "build/build_config.h"
-#include "gpu/gpu_plugin/gpu_plugin.h"
-#include "third_party/npapi/bindings/nphostapi.h"
-
-namespace gpu_plugin {
-
-// Definitions of NPAPI plugin entry points.
-
-namespace {
-
-// TODO(apatrick): move this to platform specific source files.
-#if defined(OS_WIN)
-class PluginObject {
- public:
- PluginObject();
- ~PluginObject();
-
- void SetWindow(HWND hwnd);
-
- private:
- HWND hwnd_;
-
- DISALLOW_COPY_AND_ASSIGN(PluginObject);
-};
-
-const wchar_t* const kPluginObject = L"GPUPluginObject";
-
-PluginObject::PluginObject() : hwnd_(NULL) {
-}
-
-PluginObject::~PluginObject() {
-}
-
-void PluginObject::SetWindow(HWND hwnd) {
- hwnd_ = hwnd;
- if (hwnd_) {
- // TODO: convert this to using app::win::ScopedProp.
- // Store plugin object in window property.
- SetProp(hwnd_, kPluginObject, reinterpret_cast<HANDLE>(this));
-
- // Disable plugin window so mouse messages are passed to the parent window.
- EnableWindow(hwnd_, false);
- } else {
- // Clean up properties.
- RemoveProp(hwnd_, kPluginObject);
- }
-}
-
-#endif // defined(OS_WIN)
-
-NPError NPP_New(NPMIMEType plugin_type, NPP instance,
- uint16 mode, int16 argc, char* argn[],
- char* argv[], NPSavedData* saved) {
- if (!instance)
- return NPERR_INVALID_INSTANCE_ERROR;
-
-#if defined(OS_WIN)
- instance->pdata = new PluginObject;
-#endif
-
- return NPERR_NO_ERROR;
-}
-
-NPError NPP_Destroy(NPP instance, NPSavedData** saved) {
- if (!instance)
- return NPERR_INVALID_INSTANCE_ERROR;
-
-#if defined(OS_WIN)
- delete static_cast<PluginObject*>(instance->pdata);
-#endif
-
- return NPERR_NO_ERROR;
-}
-
-NPError NPP_SetWindow(NPP instance, NPWindow* window) {
-#if defined(OS_WIN)
- PluginObject* plugin_object = static_cast<PluginObject*>(instance->pdata);
- plugin_object->SetWindow(reinterpret_cast<HWND>(window->window));
-#endif
-
- return NPERR_NO_ERROR;
-}
-
-int16 NPP_HandleEvent(NPP instance, void* event) {
- return 0;
-}
-
-NPError NPP_GetValue(NPP instance, NPPVariable variable, void *value) {
- if (!instance)
- return NPERR_INVALID_INSTANCE_ERROR;
- switch (variable) {
- case NPPVpluginNeedsXEmbed:
- *static_cast<NPBool *>(value) = 1;
- return NPERR_NO_ERROR;
- default:
- return NPERR_INVALID_PARAM;
- }
-}
-
-NPError NPP_SetValue(NPP instance, NPNVariable variable, void *value) {
- return NPERR_NO_ERROR;
-}
-
-} // namespace
-
-NPError API_CALL NP_GetEntryPoints(NPPluginFuncs* funcs) {
- funcs->newp = NPP_New;
- funcs->destroy = NPP_Destroy;
- funcs->setwindow = NPP_SetWindow;
- funcs->event = NPP_HandleEvent;
- funcs->getvalue = NPP_GetValue;
- funcs->setvalue = NPP_SetValue;
- return NPERR_NO_ERROR;
-}
-
-#if defined(OS_POSIX) && !defined(OS_MACOSX)
-NPError API_CALL NP_Initialize(NPNetscapeFuncs *browser_funcs,
- NPPluginFuncs* plugin_funcs) {
-#else
-NPError API_CALL NP_Initialize(NPNetscapeFuncs *browser_funcs) {
-#endif
- if (!browser_funcs)
- return NPERR_INVALID_FUNCTABLE_ERROR;
-
-#if defined(OS_POSIX) && !defined(OS_MACOSX)
- NP_GetEntryPoints(plugin_funcs);
-#endif
-
- return NPERR_NO_ERROR;
-}
-
-NPError API_CALL NP_Shutdown() {
- return NPERR_NO_ERROR;
-}
-
-} // namespace gpu_plugin
diff --git a/gpu/gpu_plugin/gpu_plugin.h b/gpu/gpu_plugin/gpu_plugin.h
deleted file mode 100644
index 05c98a9..0000000
--- a/gpu/gpu_plugin/gpu_plugin.h
+++ /dev/null
@@ -1,31 +0,0 @@
-// Copyright (c) 2009 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef GPU_GPU_PLUGIN_GPU_PLUGIN_H_
-#define GPU_GPU_PLUGIN_GPU_PLUGIN_H_
-
-#include "third_party/npapi/bindings/npapi.h"
-#include "third_party/npapi/bindings/npruntime.h"
-
-typedef struct _NPPluginFuncs NPPluginFuncs;
-typedef struct _NPNetscapeFuncs NPNetscapeFuncs;
-
-namespace gpu_plugin {
-
-// Declarations of NPAPI plugin entry points.
-
-NPError API_CALL NP_GetEntryPoints(NPPluginFuncs* funcs);
-
-#if defined(OS_POSIX) && !defined(OS_MACOSX)
-NPError API_CALL NP_Initialize(NPNetscapeFuncs *browser_funcs,
- NPPluginFuncs* plugin_funcs);
-#else
-NPError API_CALL NP_Initialize(NPNetscapeFuncs* browser_funcs);
-#endif
-
-NPError API_CALL NP_Shutdown();
-
-} // namespace gpu_plugin
-
-#endif // GPU_GPU_PLUGIN_GPU_PLUGIN_H_