Skip to content

Commit

Permalink
Add registerTextureWithType interface to proc table
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaowei-guan committed Apr 25, 2024
1 parent f88fa33 commit ace9a97
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
2 changes: 2 additions & 0 deletions shell/platform/embedder/embedder.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3255,6 +3255,8 @@ FlutterEngineResult FlutterEngineGetProcAddresses(
SET_PROC(SendPlatformMessageResponse,
FlutterEngineSendPlatformMessageResponse);
SET_PROC(RegisterExternalTexture, FlutterEngineRegisterExternalTexture);
SET_PROC(RegisterExternalTextureWithType,
FlutterEngineRegisterExternalTextureWithType);
SET_PROC(UnregisterExternalTexture, FlutterEngineUnregisterExternalTexture);
SET_PROC(MarkExternalTextureFrameAvailable,
FlutterEngineMarkExternalTextureFrameAvailable);
Expand Down
10 changes: 9 additions & 1 deletion shell/platform/embedder/embedder.h
Original file line number Diff line number Diff line change
Expand Up @@ -2649,7 +2649,8 @@ FlutterEngineResult FlutterEngineRegisterExternalTexture(
FLUTTER_EXPORT
FlutterEngineResult FlutterEngineRegisterExternalTextureWithType(
FLUTTER_API_SYMBOL(FlutterEngine) engine,
int64_t texture_identifier, FlutterTextureType type);
int64_t texture_identifier,
FlutterTextureType type);

//------------------------------------------------------------------------------
/// @brief Unregister a previous texture registration.
Expand Down Expand Up @@ -3103,6 +3104,11 @@ typedef FlutterEngineResult (*FlutterEngineSendPlatformMessageResponseFnPtr)(
typedef FlutterEngineResult (*FlutterEngineRegisterExternalTextureFnPtr)(
FLUTTER_API_SYMBOL(FlutterEngine) engine,
int64_t texture_identifier);
typedef FlutterEngineResult (
*FlutterEngineRegisterExternalTextureWithTypeFnPtr)(
FLUTTER_API_SYMBOL(FlutterEngine) engine,
int64_t texture_identifier,
FlutterTextureType type);
typedef FlutterEngineResult (*FlutterEngineUnregisterExternalTextureFnPtr)(
FLUTTER_API_SYMBOL(FlutterEngine) engine,
int64_t texture_identifier);
Expand Down Expand Up @@ -3189,6 +3195,8 @@ typedef struct {
PlatformMessageReleaseResponseHandle;
FlutterEngineSendPlatformMessageResponseFnPtr SendPlatformMessageResponse;
FlutterEngineRegisterExternalTextureFnPtr RegisterExternalTexture;
FlutterEngineRegisterExternalTextureWithTypeFnPtr
RegisterExternalTextureWithType;
FlutterEngineUnregisterExternalTextureFnPtr UnregisterExternalTexture;
FlutterEngineMarkExternalTextureFrameAvailableFnPtr
MarkExternalTextureFrameAvailable;
Expand Down

0 comments on commit ace9a97

Please sign in to comment.