Commit graph

560 commits

Author SHA1 Message Date
Sabin Regmi
5a6eacd7ef
ft floating panel on macos (#945) 2026-03-14 12:12:35 +01:00
offline-ant
8189d8eab2
compositor: add projected quad and offscreen surface primitives (#947)
* draw: add draw-list transform helpers for projected composition

* draw: unroll rounded box shadow sampling in SDF shader

* platform: honor per-draw depth_write across backends

* compositor: add projected quad and offscreen surface primitives

---------

Co-authored-by: ant <ant@offline.click>
2026-03-14 12:12:05 +01:00
Admin
f040a2f2a6 hands back! 2026-03-12 16:57:25 +01:00
Admin
bca911513d xr otw 2026-03-12 15:51:30 +01:00
Sabin Regmi
3242b11afc
Windows Blur, System Composition (#940)
* Initial plan

* feat(platform): add window visuals API and M1 backdrop wiring

Co-authored-by: wheregmis <26774729+wheregmis@users.noreply.github.com>

* feat(uizoo): add M2 GlassPanel widget and demo tab

Co-authored-by: wheregmis <26774729+wheregmis@users.noreply.github.com>

* blue example

* Apply backdrop intensity and transparency

macOS: apply visuals.backdrop_intensity to the NSVisualEffectView alpha (clamped) so backdrop intensity affects the effect view.

Windows: honor visuals.backdrop_intensity by computing an alpha-packed accent color, toggle WS_EX_LAYERED for transparent windows, call SetLayeredWindowAttributes and DwmExtendFrameIntoClientArea when needed, and set the AccentPolicy accordingly (enable blur for transparent or non-none backdrops, set gradient_color based on intensity, and set accent_flags depending on DWM attribute result).

Tests: update expected backdrop_intensity in a unit test from 4.0/1.0 to 0.25 and assert a platform op is emitted. These changes ensure backdrop intensity and transparency settings are respected across platforms.

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: wheregmis <26774729+wheregmis@users.noreply.github.com>
2026-03-12 14:57:09 +01:00
Admin
61a70d0ebd xr 2026-03-12 13:30:40 +01:00
Admin
cde02e2e48 fix 2026-03-11 18:15:12 +01:00
Admin
928521e994 mipmapping 2026-03-09 09:18:33 +01:00
Admin
def4c5f6e6 fix script mods 2026-03-08 18:20:07 +01:00
Admin
e79e374375 live reloading 2026-03-08 17:25:27 +01:00
Admin
38d08cab0b bootstrap change 2026-03-08 13:36:58 +01:00
offline-ant
7c7d91b8ad
platform: video/camera subsystem with media plugin architecture (#929)
Video playback: extended API with volume, playback rate, seek ranges,
buffered ranges, can_play_type, audio-only mode. Unified player wrapping
native backend (AVPlayer/GStreamer/MediaFoundation) with software fallback.
YUV shader pipeline (BT.601/709/2020, NV12 biplanar, rotation).

Camera: V4L2 backend (Linux), expanded NDK Camera2 (Android), AVCapture
stream refactor (iOS/macOS) with shared session architecture. NV12
zero-copy paths on iOS (CVMetalTextureCache) and Android (AImage planes).
Camera preview modes (texture/native/auto).

Video encoding: H264 hardware encode on Apple (VideoToolbox) and Android
(MediaCodec). Camera-to-encoder pipeline with pixel buffer passthrough.

Media plugin system: externalized codec implementation via MediaPlugin
trait. MsePlayer, VideoFrameDecoder, MediaVideoEncoder, SoftwareVideoPlayer
interfaces. Runtime codec capability query and merge.

Includes camera example app.

Co-authored-by: ant <ant@offline.click>
2026-03-08 13:10:58 +01:00
offline-ant
814fe4d9cd
platform: native mobile selection handles (#930)
* platform: popup window API with X11/Wayland support

- Add popup window type for context menus and dropdowns
- Wayland: xdg_popup with grab for compositor-driven dismiss
- X11: override-redirect windows with pointer grab
- Explicit-close semantics: app must handle PopupDismissed
- Fix Wayland crash on repeated context menu open/close
- Emit WindowClosed before PopupDismissed in PopupDone

* platform: native mobile selection handles

iOS: custom UIView selection handles with UIPanGestureRecognizer (all versions),
UITextSelectionDisplayInteraction for native highlights (iOS 16+),
MakepadSelectionRect for UITextInput protocol.

Android: custom SelectionHandleView with GradientDrawable oval, touch drag
listeners, JNI bridge for handle drag events.

Widgets: TextFlow clipboard action integration (show on touch up with selection,
hide on touch down/focus lost, TextCut handler), PortalList select-all and
clipboard actions, selection bounding rect computation for popup positioning.

Includes text_selection example app.

---------

Co-authored-by: ant <ant@offline.click>
2026-03-08 12:15:31 +01:00
Admin
24a9b0627d remove apprs 2026-03-08 10:28:40 +01:00
Admin
923a554e49 fixing 2026-03-08 09:20:34 +01:00
Admin
b64a83fa15 oops. uids 2026-03-08 08:42:49 +01:00
Admin
9124a025af exr 2026-03-07 15:01:34 +01:00
Admin
e61e3bfbce Harden widget tree refresh and require explicit widget uids 2026-03-07 11:23:22 +01:00
Admin
7c5c0edeba fix shader compiler 2026-03-06 18:49:24 +01:00
Admin
42a45913d6 drumroll 2026-03-06 17:21:17 +01:00
Admin
0846e575b0 split f32 + uniformbuffers 2026-03-06 17:21:17 +01:00
Admin
d5f198d126 fix 2026-03-06 09:26:02 +01:00
Admin
05238ee39d widget tree change 2026-03-03 21:22:58 +01:00
Admin
81483d4555 y flip webgl rendertartet 2026-03-03 09:42:54 +01:00
Admin
4f38c0c324 finall fix render glitch 2026-03-02 20:16:29 +01:00
Admin
524ac9186d cleanup 2026-03-01 23:15:39 +01:00
Admin
79ac8d834f makepad studio old 2026-02-28 22:42:57 +01:00
Admin
a8599a4b22 fix 2026-02-28 12:48:06 +01:00
Admin
952e6134a9 plaintext error 2026-02-28 11:40:11 +01:00
Julián Montes de Oca
0675c98cc8
Restore StackNavigation widget, add examples to ui-zoo (#892) 2026-02-26 13:54:36 +01:00
Admin
813844becc counter splash example 2026-02-26 10:08:25 +01:00
Kevin Boos
3db5766d33
Fix circle view (#887)
* Fix `CircleView` shader, support true circle shader behavior

Add CircleView examples w/ variety to `uizoo`

* splash example: fix popup notification behavior
2026-02-26 08:17:49 +01:00
admin
ddca609ad8 api 2026-02-25 17:14:39 +01:00
Kevin Boos
d1737883da
FIx Icon, improve to support IconRotated, expose geom in draw_svg (#883)
* Fix draw_svg to support a rotated Icon. Add `IconRotated` widget.

Fix icon resource paths in `splash` example

* Expose geometry in draw_svg to make icon/svg rotation more efficient

simplifies the code too
2026-02-25 13:05:14 +01:00
Sabin Regmi
ec983c982a
Remove left margin from window caption label (#884)
* Remove left margin from window caption label

Delete the hardcoded Inset{left: 100} margin on the caption Label in widgets/src/window.rs so the label can be centered by the parent layout. This cleans up alignment and removes an unnecessary offset in the window header.

* Use window title in caption; format button click

Apply the configured window title to the window caption and make a small UI code cleanup.

- examples/splash: set window.title to "Splash Example" and reformat the tooltip button click check to a multiline expression for readability.
- widgets/src/window.rs: import label::* and update ensure_initialized to copy cx.windows[window_id].create_title into the caption_label when non-empty so the window chrome shows the configured title.
2026-02-25 13:04:46 +01:00
Admin
33eeb0d244 little glitches in script engine 2026-02-24 23:32:56 +01:00
Admin
677d2ba934 cleanup warnings 2026-02-24 21:40:08 +01:00
Admin
d75499e215 edmx 2026-02-24 21:40:08 +01:00
Admin
688da80e11 fix gc issues 2026-02-24 21:40:08 +01:00
Kevin Boos
c0082cc323
Fix Tooltip behavior and structure. Add CalloutTooltip widget (#881)
The CalloutTooltip is a fancier wrapper atop Tooltip that allows
the user to display a tooltip with a callout triangle that points
at a particular widget, making it clearer what the tooltip
corresponds to. It also supports a custom text color, background color,
positioning suggestion (top, right, left, bottom), full text wrapping,
and dynamically resize and re-orient itself to fit within the app screen.
2026-02-24 19:43:06 +01:00
Admin
ca17ee8baa splice out a makepad-network crate 2026-02-23 23:21:31 +01:00
Admin
aa056e8053 fix dx11 memleak 2026-02-23 18:30:26 +01:00
Admin
7dc1249b4f fix up uizoo 2026-02-23 18:00:19 +01:00
Julián Montes de Oca
6bc8fde866
Video Widget: Support on MacOS & iOS (#863)
* Add macOS video playback support using AVPlayer + CVMetalTextureCache

Extends the Video widget from Android-only to also support macOS with
hardware-accelerated, zero-copy video rendering through Metal. Uses
AVPlayer for decoding and CVMetalTextureCache to map decoded frames
directly to MTLTextures without CPU copies.

Key changes:
- New AppleVideoPlayer module (AVPlayer + CVPixelBuffer → MTLTexture pipeline)
- FFI bindings for CVMetalTextureCache, CMTime, and related Apple APIs
- Video frame polling integrated into macOS paint cycle
- TextureFormat::VideoRGB ungated from Android-only to all platforms
- Video widget made cross-platform (TextureHandleReady wait is Android-only)
- Fixed shader aspect ratio bug (&&→|| for non-positive dimension check)
- Added video demo to uizoo and scratchpad examples

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Add iOS video playback support

* Enhance video playback functionality with seek support and current position tracking

Key changes:
- Added `seek_video_playback` operation to allow seeking to specific timestamps.
- Introduced `current_position_ms` field in `VideoTextureUpdatedEvent` for tracking playback position.
- Implemented seeking functionality across iOS, macOS, and Android platforms.
- Updated Video widget to support new controls and indicators for seeking.

* Improve error handling for unsupported texture pixel formats

* Make volume icon drawing  use fixed width

* Make play/pause drawing use fixed width

* Remove video from scratchpad

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-23 15:19:21 +01:00
admin
b6dea262e2 automated click animation 2026-02-22 13:34:00 +01:00
admin
ec56475706 theme cleanup 2026-02-21 15:40:12 +01:00
admin
2d8754eea9 fix up theme hook 2026-02-21 15:21:27 +01:00
Admin
a98c49dadd sortable drawcalls 2026-02-21 10:05:07 +01:00
Admin
f6bafb9a82 splats without sort yet 2026-02-21 08:43:52 +01:00
Admin
7cc23e477e fix 2026-02-20 23:58:48 +01:00