Loading services/surfaceflinger/LayerDim.cpp +1 −26 Original line number Original line Diff line number Diff line Loading @@ -30,29 +30,12 @@ namespace android { namespace android { // --------------------------------------------------------------------------- // --------------------------------------------------------------------------- bool LayerDim::sUseTexture; GLuint LayerDim::sTexId; EGLImageKHR LayerDim::sImage; int32_t LayerDim::sWidth; int32_t LayerDim::sHeight; // --------------------------------------------------------------------------- LayerDim::LayerDim(SurfaceFlinger* flinger, DisplayID display, LayerDim::LayerDim(SurfaceFlinger* flinger, DisplayID display, const sp<Client>& client) const sp<Client>& client) : LayerBaseClient(flinger, display, client) : LayerBaseClient(flinger, display, client) { { } } void LayerDim::initDimmer(SurfaceFlinger* flinger, uint32_t w, uint32_t h) { sTexId = -1; sImage = EGL_NO_IMAGE_KHR; sWidth = w; sHeight = h; sUseTexture = false; } LayerDim::~LayerDim() LayerDim::~LayerDim() { { } } Loading Loading @@ -84,15 +67,7 @@ void LayerDim::onDraw(const Region& clip) const #endif #endif glDisable(GL_TEXTURE_2D); glDisable(GL_TEXTURE_2D); GLshort w = sWidth; glVertexPointer(2, GL_FLOAT, 0, mVertices); GLshort h = sHeight; const GLshort vertices[4][2] = { { 0, 0 }, { 0, h }, { w, h }, { w, 0 } }; glVertexPointer(2, GL_SHORT, 0, vertices); while (it != end) { while (it != end) { const Rect& r = *it++; const Rect& r = *it++; Loading services/surfaceflinger/LayerDim.h +0 −7 Original line number Original line Diff line number Diff line Loading @@ -31,11 +31,6 @@ namespace android { class LayerDim : public LayerBaseClient class LayerDim : public LayerBaseClient { { static bool sUseTexture; static GLuint sTexId; static EGLImageKHR sImage; static int32_t sWidth; static int32_t sHeight; public: public: LayerDim(SurfaceFlinger* flinger, DisplayID display, LayerDim(SurfaceFlinger* flinger, DisplayID display, const sp<Client>& client); const sp<Client>& client); Loading @@ -45,8 +40,6 @@ public: virtual bool needsBlending() const { return true; } virtual bool needsBlending() const { return true; } virtual bool isSecure() const { return false; } virtual bool isSecure() const { return false; } virtual const char* getTypeId() const { return "LayerDim"; } virtual const char* getTypeId() const { return "LayerDim"; } static void initDimmer(SurfaceFlinger* flinger, uint32_t w, uint32_t h); }; }; // --------------------------------------------------------------------------- // --------------------------------------------------------------------------- Loading services/surfaceflinger/SurfaceFlinger.cpp +0 −2 Original line number Original line Diff line number Diff line Loading @@ -259,8 +259,6 @@ status_t SurfaceFlinger::readyToRun() glLoadIdentity(); glLoadIdentity(); glOrthof(0, w, h, 0, 0, 1); glOrthof(0, w, h, 0, 0, 1); LayerDim::initDimmer(this, w, h); mReadyToRunBarrier.open(); mReadyToRunBarrier.open(); /* /* Loading Loading
services/surfaceflinger/LayerDim.cpp +1 −26 Original line number Original line Diff line number Diff line Loading @@ -30,29 +30,12 @@ namespace android { namespace android { // --------------------------------------------------------------------------- // --------------------------------------------------------------------------- bool LayerDim::sUseTexture; GLuint LayerDim::sTexId; EGLImageKHR LayerDim::sImage; int32_t LayerDim::sWidth; int32_t LayerDim::sHeight; // --------------------------------------------------------------------------- LayerDim::LayerDim(SurfaceFlinger* flinger, DisplayID display, LayerDim::LayerDim(SurfaceFlinger* flinger, DisplayID display, const sp<Client>& client) const sp<Client>& client) : LayerBaseClient(flinger, display, client) : LayerBaseClient(flinger, display, client) { { } } void LayerDim::initDimmer(SurfaceFlinger* flinger, uint32_t w, uint32_t h) { sTexId = -1; sImage = EGL_NO_IMAGE_KHR; sWidth = w; sHeight = h; sUseTexture = false; } LayerDim::~LayerDim() LayerDim::~LayerDim() { { } } Loading Loading @@ -84,15 +67,7 @@ void LayerDim::onDraw(const Region& clip) const #endif #endif glDisable(GL_TEXTURE_2D); glDisable(GL_TEXTURE_2D); GLshort w = sWidth; glVertexPointer(2, GL_FLOAT, 0, mVertices); GLshort h = sHeight; const GLshort vertices[4][2] = { { 0, 0 }, { 0, h }, { w, h }, { w, 0 } }; glVertexPointer(2, GL_SHORT, 0, vertices); while (it != end) { while (it != end) { const Rect& r = *it++; const Rect& r = *it++; Loading
services/surfaceflinger/LayerDim.h +0 −7 Original line number Original line Diff line number Diff line Loading @@ -31,11 +31,6 @@ namespace android { class LayerDim : public LayerBaseClient class LayerDim : public LayerBaseClient { { static bool sUseTexture; static GLuint sTexId; static EGLImageKHR sImage; static int32_t sWidth; static int32_t sHeight; public: public: LayerDim(SurfaceFlinger* flinger, DisplayID display, LayerDim(SurfaceFlinger* flinger, DisplayID display, const sp<Client>& client); const sp<Client>& client); Loading @@ -45,8 +40,6 @@ public: virtual bool needsBlending() const { return true; } virtual bool needsBlending() const { return true; } virtual bool isSecure() const { return false; } virtual bool isSecure() const { return false; } virtual const char* getTypeId() const { return "LayerDim"; } virtual const char* getTypeId() const { return "LayerDim"; } static void initDimmer(SurfaceFlinger* flinger, uint32_t w, uint32_t h); }; }; // --------------------------------------------------------------------------- // --------------------------------------------------------------------------- Loading
services/surfaceflinger/SurfaceFlinger.cpp +0 −2 Original line number Original line Diff line number Diff line Loading @@ -259,8 +259,6 @@ status_t SurfaceFlinger::readyToRun() glLoadIdentity(); glLoadIdentity(); glOrthof(0, w, h, 0, 0, 1); glOrthof(0, w, h, 0, 0, 1); LayerDim::initDimmer(this, w, h); mReadyToRunBarrier.open(); mReadyToRunBarrier.open(); /* /* Loading