Files
tomato/src/chat_gui/image_viewer_popup.hpp
Green Sky 2dbce14e5e
Some checks failed
ContinuousDelivery / linux-ubuntu (push) Has been cancelled
ContinuousDelivery / android (map[ndk_abi:arm64-v8a vcpkg_toolkit:arm64-android-23]) (push) Has been cancelled
ContinuousDelivery / android (map[ndk_abi:armeabi-v7a vcpkg_toolkit:arm-neon-android-23]) (push) Has been cancelled
ContinuousDelivery / android (map[ndk_abi:x86_64 vcpkg_toolkit:x64-android-23]) (push) Has been cancelled
ContinuousDelivery / windows (windows-2022, ) (push) Has been cancelled
ContinuousDelivery / windows (windows-2022, asan) (push) Has been cancelled
ContinuousIntegration / on ubuntu-24.04-arm (push) Has been cancelled
ContinuousIntegration / asan on ubuntu-24.04-arm (push) Has been cancelled
ContinuousIntegration / on ubuntu-latest (push) Has been cancelled
ContinuousIntegration / asan on ubuntu-latest (push) Has been cancelled
ContinuousIntegration / android (map[ndk_abi:arm64-v8a vcpkg_toolkit:arm64-android-23]) (push) Has been cancelled
ContinuousIntegration / android (map[ndk_abi:armeabi-v7a vcpkg_toolkit:arm-neon-android-23]) (push) Has been cancelled
ContinuousIntegration / android (map[ndk_abi:x86_64 vcpkg_toolkit:x64-android-23]) (push) Has been cancelled
ContinuousIntegration / macos (push) Has been cancelled
ContinuousIntegration / windows (push) Has been cancelled
ContinuousDelivery / dumpsyms (push) Has been cancelled
ContinuousDelivery / release (push) Has been cancelled
make texture cache scale down images on load to the requested size
2025-12-04 15:56:39 +01:00

36 lines
674 B
C++

#pragma once
#include <solanaceae/message3/registry_message_model.hpp>
#include "./texture_cache_defs.hpp"
#include <entt/entity/registry.hpp>
#include <entt/entity/handle.hpp>
struct ImageViewerPopup {
MessageTextureCache& _mtc;
Message3Handle _m{};
float _scale {1.f};
// keep track of full size from last frame
uint32_t _width {0};
uint32_t _height {0};
bool _open_popup {false};
//void reset(void);
public:
ImageViewerPopup(MessageTextureCache& mtc);
// open popup with (image) message
//void view(ObjectHandle o);
void view(Message3Handle m);
// call this each frame
void render(float time_delta);
// TODO: events (destroy/update)
};