cleanup EGL/D3D texture rendering
This commit is contained in:
@@ -1,24 +1,35 @@
|
||||
#ifndef _EGL_CONTEXT_H
|
||||
#define _EGL_CONTEXT_H
|
||||
|
||||
#include <Windows.h>
|
||||
|
||||
#include <flutter/method_channel.h>
|
||||
#include <flutter/plugin_registrar_windows.h>
|
||||
#include <flutter/standard_method_codec.h>
|
||||
#include <flutter/texture_registrar.h>
|
||||
|
||||
#include "flutter_angle_texture.h"
|
||||
#include "backend/platforms/PlatformEGL.h"
|
||||
#include "flutter_render_context.h"
|
||||
|
||||
namespace flutter_filament {
|
||||
|
||||
class EGLContext : public FlutterRenderingContext {
|
||||
class FlutterEGLContext : public FlutterRenderContext {
|
||||
public:
|
||||
EGLContext(flutter::PluginRegistrarWindows* pluginRegistrar, flutter::TextureRegistrar* textureRegistrar);
|
||||
FlutterEGLContext(flutter::PluginRegistrarWindows* pluginRegistrar, flutter::TextureRegistrar* textureRegistrar);
|
||||
void* GetSharedContext();
|
||||
void RenderCallback();
|
||||
void* GetPlatform();
|
||||
void CreateRenderingSurface(uint32_t width, uint32_t height, std::unique_ptr<flutter::MethodResult<flutter::EncodableValue>> result, uint32_t left, uint32_t top );
|
||||
|
||||
private:
|
||||
EGLContext _context = NULL;
|
||||
void* _context = nullptr;
|
||||
EGLConfig _eglConfig = NULL;
|
||||
EGLDisplay _eglDisplay = NULL;
|
||||
std::unique_ptr<FlutterAngleTexture> _active = nullptr;
|
||||
std::unique_ptr<FlutterAngleTexture> _inactive = nullptr;
|
||||
ID3D11Device* _D3D11Device = nullptr;
|
||||
ID3D11DeviceContext* _D3D11DeviceContext = nullptr;
|
||||
filament::backend::Platform* _platform = nullptr;
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user