| Flutter Linux Embedder |

Functions
fl_engine.h File Reference
`#include <glib-object.h>`
`#include <gmodule.h>`
`#include "fl_binary_messenger.h"`
`#include "fl_dart_project.h"`
`#include "fl_texture_registrar.h"`

Go to the source code of this file.

## Functions
G_BEGIN_DECLS G_MODULE_EXPORT FlEngine * | fl_engine_new (FlDartProject *project)
FlEngine * | fl_engine_new_headless (FlDartProject *project)
FlBinaryMessenger * | fl_engine_get_binary_messenger (FlEngine *engine)
FlTextureRegistrar * | fl_engine_get_texture_registrar (FlEngine *engine)

## Function Documentation

## ◆ fl_engine_get_binary_messenger()

FlBinaryMessenger* fl_engine_get_binary_messenger | ( | FlEngine * | engine | ) |

fl_engine_get_binary_messenger: @engine: an #FlEngine.

Gets the messenger to communicate with this engine.

Returns: an #FlBinaryMessenger.

Definition at line 995 of file fl_engine.cc.

996 {
997 g_return_val_if_fail(FL_IS_ENGINE(self), nullptr);
998 return self->binary_messenger;
999 }

Referenced by create_context_cb(), fl_settings_handler_new(), fl_view_get_registrar_for_plugin(), fl_view_keyboard_delegate_iface_init(), init_keyboard(), realize_cb(), and TEST().

## ◆ fl_engine_get_texture_registrar()

FlTextureRegistrar* fl_engine_get_texture_registrar | ( | FlEngine * | engine | ) |

fl_engine_get_texture_registrar: @engine: an #FlEngine.

Gets the texture registrar for registering textures.

Returns: an #FlTextureRegistrar.

Definition at line 1011 of file fl_engine.cc.

1012 {
1013 g_return_val_if_fail(FL_IS_ENGINE(self), nullptr);
1014 return self->texture_registrar;
1015 }

Referenced by fl_view_get_registrar_for_plugin().

## ◆ fl_engine_new()

G_BEGIN_DECLS G_MODULE_EXPORT FlEngine* fl_engine_new | ( | FlDartProject * | project | ) |

FlEngine:

#FlEngine is an object that contains a running Flutter engine. fl_engine_new: @project: an #FlDartProject.

Creates new Flutter engine.

Returns: a new #FlEngine.

Definition at line 494 of file fl_engine.cc.

494 {
495 g_autoptr(FlRendererGdk) renderer = fl_renderer_gdk_new();
496 return fl_engine_new_with_renderer(project, FL_RENDERER(renderer));
497 }

References fl_engine_new_with_renderer(), and fl_renderer_gdk_new().

Referenced by fl_view_new().

## ◆ fl_engine_new_headless()

FlEngine* fl_engine_new_headless | ( | FlDartProject * | project | ) |

fl_engine_new_headless: @project: an #FlDartProject.

Creates new Flutter engine running in headless mode.

Returns: a new #FlEngine.

Definition at line 499 of file fl_engine.cc.

499 {
500 g_autoptr(FlRendererHeadless) renderer = fl_renderer_headless_new();
501 return fl_engine_new_with_renderer(project, FL_RENDERER(renderer));
502 }

References fl_engine_new_with_renderer(), and fl_renderer_headless_new().

fl_engine_new_with_renderer
FlEngine * fl_engine_new_with_renderer(FlDartProject *project, FlRenderer *renderer)
Definition: fl_engine.cc:479
fl_renderer_headless_new
FlRendererHeadless * fl_renderer_headless_new()
Definition: fl_renderer_headless.cc:38
fl_renderer_gdk_new
FlRendererGdk * fl_renderer_gdk_new()
Definition: fl_renderer_gdk.cc:82