Skip to content

Commit 38721da

Browse files
committed
Remove ExternalTexture stub files (#164)
* Remove ExternalTexture stub files * Create a dummy external_texture_surface_gl_linux.cc
1 parent 22effc3 commit 38721da

7 files changed

+15
-58
lines changed

shell/platform/tizen/BUILD.gn

+3-4
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,7 @@ template("embedder") {
119119
"channels/platform_view_channel.cc",
120120
"channels/settings_channel.cc",
121121
"channels/text_input_channel.cc",
122+
"external_texture_pixel_gl.cc",
122123
"flutter_project_bundle.cc",
123124
"flutter_tizen.cc",
124125
"flutter_tizen_engine.cc",
@@ -156,8 +157,7 @@ template("embedder") {
156157
"channels/app_control_channel.cc",
157158
"channels/platform_channel_tizen.cc",
158159
"channels/settings_channel_tizen.cc",
159-
"external_texture_pixel_gl.cc",
160-
"external_texture_surface_gl.cc",
160+
"external_texture_surface_gl_tizen.cc",
161161
"system_utils_tizen.cc",
162162
]
163163

@@ -180,8 +180,7 @@ template("embedder") {
180180
sources += [
181181
"channels/platform_channel_linux.cc",
182182
"channels/settings_channel_linux.cc",
183-
"external_texture_pixel_gl_stub.cc",
184-
"external_texture_surface_gl_stub.cc",
183+
"external_texture_surface_gl_linux.cc",
185184
"system_utils_linux.cc",
186185
]
187186
}

shell/platform/tizen/external_texture_pixel_gl.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
#ifdef TIZEN_RENDERER_EVAS_GL
88
#undef EFL_BETA_API_SUPPORT
9-
#include <Evas_GL_GLES3_Helpers.h>
9+
#include "tizen_evas_gl_helper.h"
1010
extern Evas_GL* g_evas_gl;
1111
EVAS_GL_GLOBAL_GLES3_DECLARE();
1212
#else

shell/platform/tizen/external_texture_pixel_gl_stub.cc

-29
This file was deleted.

shell/platform/tizen/external_texture_surface_gl_stub.cc renamed to shell/platform/tizen/external_texture_surface_gl_linux.cc

+8-7
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,12 @@
22
// Use of this source code is governed by a BSD-style license that can be
33
// found in the LICENSE file.
44

5+
#pragma clang diagnostic push
6+
#pragma clang diagnostic ignored "-Wunused-private-field"
57
#include "external_texture_surface_gl.h"
8+
#pragma clang diagnostic pop
9+
10+
#include "flutter/shell/platform/tizen/logger.h"
611

712
namespace flutter {
813

@@ -16,23 +21,19 @@ ExternalTextureSurfaceGL::ExternalTextureSurfaceGL(
1621
user_data_(user_data) {}
1722

1823
ExternalTextureSurfaceGL::~ExternalTextureSurfaceGL() {
19-
state_.release();
24+
FT_UNIMPLEMENTED();
2025
}
2126

2227
bool ExternalTextureSurfaceGL::PopulateTexture(
2328
size_t width,
2429
size_t height,
2530
FlutterOpenGLTexture* opengl_texture) {
26-
if (texture_callback_ && destruction_callback_ && user_data_) {
27-
return true;
28-
}
31+
FT_UNIMPLEMENTED();
2932
return false;
3033
}
3134

3235
void ExternalTextureSurfaceGL::OnDestruction() {
33-
if (destruction_callback_) {
34-
destruction_callback_(user_data_);
35-
}
36+
FT_UNIMPLEMENTED();
3637
}
3738

3839
} // namespace flutter

shell/platform/tizen/external_texture_surface_gl.cc renamed to shell/platform/tizen/external_texture_surface_gl_tizen.cc

+1-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
#ifdef TIZEN_RENDERER_EVAS_GL
88
#undef EFL_BETA_API_SUPPORT
9-
#include <Evas_GL_GLES3_Helpers.h>
9+
#include "tizen_evas_gl_helper.h"
1010
extern Evas_GL* g_evas_gl;
1111
EVAS_GL_GLOBAL_GLES3_DECLARE();
1212
#else
@@ -18,7 +18,6 @@ EVAS_GL_GLOBAL_GLES3_DECLARE();
1818

1919
#include <tbm_surface.h>
2020

21-
#include "flutter/shell/platform/common/public/flutter_texture_registrar.h"
2221
#include "flutter/shell/platform/tizen/logger.h"
2322

2423
namespace flutter {

shell/platform/tizen/tizen_evas_gl_helper.h

+2-11
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,5 @@
1-
// Copyright 2021 Samsung Electronics Co., Ltd. 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-
5-
// This file has same content as tizen's file(Evas_GL_GLES3_Helpers.h).
6-
// https://docs.tizen.org/application/native/api/mobile/6.0/group__Evas__GL__GLES3__Helpers.html
7-
8-
#ifndef EMBEDDER_TIZEN_EVAS_GL_HELPER_H_
9-
#define EMBEDDER_TIZEN_EVAS_GL_HELPER_H_
1+
// This file is a copy of Tizen's Evas_GL_GLES3_Helpers.h file.
2+
// https://docs.tizen.org/application/native/api/wearable/5.5/group__Evas__GL__GLES3__Helpers.html
103

114
/**
125
* @file Evas_GL_GLES3_Helpers.h
@@ -683,5 +676,3 @@ evgl_init(...)
683676
*/
684677

685678
#endif
686-
687-
#endif // EMBEDDER_TIZEN_EVAS_GL_HELPER_H_

shell/platform/tizen/tizen_renderer_evas_gl.cc

-4
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,7 @@
44

55
#include "tizen_renderer_evas_gl.h"
66

7-
#ifdef __X64_SHELL__
87
#include "tizen_evas_gl_helper.h"
9-
#else
10-
#include <Evas_GL_GLES3_Helpers.h>
11-
#endif
128
Evas_GL* g_evas_gl = nullptr;
139
EVAS_GL_GLOBAL_GLES3_DEFINE();
1410

0 commit comments

Comments
 (0)