LayerDim.h 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. /*
  2. * Copyright (C) 2007 The Android Open Source Project
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. */
  16. #ifndef ANDROID_LAYER_DIM_H
  17. #define ANDROID_LAYER_DIM_H
  18. #include <stdint.h>
  19. #include <sys/types.h>
  20. #include "Layer.h"
  21. // ---------------------------------------------------------------------------
  22. namespace android {
  23. class LayerDim : public Layer
  24. {
  25. public:
  26. LayerDim(SurfaceFlinger* flinger, const sp<Client>& client,
  27. const String8& name, uint32_t w, uint32_t h, uint32_t flags);
  28. virtual ~LayerDim();
  29. virtual const char* getTypeId() const { return "LayerDim"; }
  30. virtual void onDraw(const sp<const DisplayDevice>& hw, const Region& clip,
  31. bool useIdentityTransform);
  32. virtual bool isOpaque(const Layer::State&) const { return false; }
  33. virtual bool isSecure() const { return false; }
  34. virtual bool isFixedSize() const { return true; }
  35. virtual bool isVisible() const;
  36. virtual void setPerFrameData(const sp<const DisplayDevice>& hw,
  37. HWComposer::HWCLayerInterface& layer);
  38. };
  39. // ---------------------------------------------------------------------------
  40. }; // namespace android
  41. #endif // ANDROID_LAYER_DIM_H