cast_egl_platform_default.cc 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. // Copyright 2014 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #include "chromecast/public/cast_egl_platform.h"
  5. #include "chromecast/public/cast_egl_platform_shlib.h"
  6. namespace chromecast {
  7. namespace {
  8. // Default/stub CastEglPlatform implementation so that we can link
  9. // successfully.
  10. class EglPlatformDefault : public CastEglPlatform {
  11. public:
  12. ~EglPlatformDefault() override {}
  13. const int* GetEGLSurfaceProperties(const int* desired) override {
  14. return desired;
  15. }
  16. bool InitializeHardware() override { return true; }
  17. void* GetEglLibrary() override { return nullptr; }
  18. void* GetGles2Library() override { return nullptr; }
  19. GLGetProcAddressProc GetGLProcAddressProc() override { return nullptr; }
  20. NativeDisplayType CreateDisplayType(const Size& size) override {
  21. return nullptr;
  22. }
  23. NativeWindowType CreateWindow(NativeDisplayType display_type,
  24. const Size& size) override {
  25. return nullptr;
  26. }
  27. };
  28. } // namespace
  29. CastEglPlatform* CastEglPlatformShlib::Create(
  30. const std::vector<std::string>& argv) {
  31. return new EglPlatformDefault();
  32. }
  33. } // namespace chromecast