MCPcopy Create free account
hub / github.com/KhronosGroup/Vulkan-Samples / AndroidPlatform

Class AndroidPlatform

framework/platform/android/android_platform.h:26–68  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

24namespace vkb
25{
26class AndroidPlatform : public Platform
27{
28 public:
29 AndroidPlatform(const PlatformContext &context);
30
31 virtual ~AndroidPlatform() = default;
32
33 virtual ExitCode initialize(const std::vector<Plugin *> &plugins) override;
34
35 virtual void terminate(ExitCode code) override;
36
37 /**
38 * @brief Sends a notification in the task bar
39 * @param message The message to display
40 */
41 void send_notification(const std::string &message);
42
43 /**
44 * @brief Sends an error notification in the task bar
45 * @param message The message to display
46 */
47 void send_error_notification(const std::string &message);
48
49 android_app *get_android_app();
50
51 GameActivity *get_activity();
52
53 void set_surface_ready();
54
55 void process_android_input_events(void);
56
57 private:
58 virtual void create_window(const Window::Properties &properties) override;
59
60 private:
61 android_app *app{nullptr};
62
63 std::string log_output;
64
65 virtual std::vector<spdlog::sink_ptr> get_platform_sinks() override;
66
67 bool surface_ready{false};
68};
69
70/**
71 * @brief Process android lifecycle events

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected