CanvasImageSmoothing.h 675 B

123456789101112131415161718192021222324252627
  1. /*
  2. * Copyright (c) 2023, Andreas Kling <kling@serenityos.org>
  3. *
  4. * SPDX-License-Identifier: BSD-2-Clause
  5. */
  6. #pragma once
  7. #include <LibWeb/HTML/ImageData.h>
  8. namespace Web::HTML {
  9. // https://html.spec.whatwg.org/multipage/canvas.html#canvasimagesmoothing
  10. class CanvasImageSmoothing {
  11. public:
  12. virtual ~CanvasImageSmoothing() = default;
  13. virtual bool image_smoothing_enabled() const = 0;
  14. virtual void set_image_smoothing_enabled(bool) = 0;
  15. virtual Bindings::ImageSmoothingQuality image_smoothing_quality() const = 0;
  16. virtual void set_image_smoothing_quality(Bindings::ImageSmoothingQuality) = 0;
  17. protected:
  18. CanvasImageSmoothing() = default;
  19. };
  20. }