Commit Graph
1090 Commits
Author SHA1 Message Date
RobertBeekman 5ddd50b4a8 Core - Fix node script and pin bugs found by the tests (#911)
* Core - Keep nodes of missing plugins and the connection an input reads from in node scripts

- Saving a script keeps nodes whose plugin is missing, and their connections, so they come back once the plugin is available again
- Loading keeps the first connection of an input, the one it reads from
- Disabling a node provider only removes the nodes it created, not those of another provider registering the same type
- RemoveNode only raises NodeRemoved for nodes that were in the script

* Core - Fix pin connections, null values and failing nodes

- Connecting pins that are already connected no longer adds a second connection
- Untyped pins turn null into the default value for value types, as intended
- A new InputPin<T> reads its connection right away instead of after its first reset
- Matching a specific enum to a pin of any enum now depends on forgivingEnumMatching
- A node that fails to evaluate sets its outputs to their default values, so it is evaluated once per run and old values don't flow on

* Core - Round Numeric to long and clamp it to the range of an sbyte
2026-10-24 16:22:44 +02:00
RobertBeekman 83cf6da830 Core - Fix profile service, storage and device bugs found by the tests (#912)
* Core - Fix default headset layouts and the z-index of devices placed by the auto-arrange fallback

- Headsets with 2 or 4 LEDs get their default layout, the files are named "... LEDs headset.xml"
- Devices placed by the auto-arrange fallback get the z-index of their type

* Core - Fall back to the default value passed to GetSetting when a stored setting can't be read

* Core - Fix storing, cloning and migrating profiles

- New profiles are stored at the current migration version, so they're no longer migrated on every start and can be duplicated right away
- A category created at the top is listed first right away, so its profiles render on top
- CloneProfileConfiguration makes a copy of the stored data, saving a clone stores its profile through the original
- Importing a profile raises ProfileAdded
- A profile configuration that isn't valid JSON is logged and skipped instead of stopping all migrations
- A stored profile without a version is migrated from version 0, like an imported one
- ProfileCategoryRepository.IsUnique returns true when the name is free
- M0001 and M0004 leave a missing node type or storage out instead of writing null
- M0003 also unwraps a list that is an item of another list
2026-10-24 16:19:23 +02:00
RobertBeekman 295038f338 Profile editor - Fix undo and editor service bugs found by the tests (#913)
* Profile editor - Fix undoing profile editor commands

- Undoing a change to an existing keyframe's value restores the value instead of deleting the keyframe
- Undoing "remove effect" puts the effect back in its place instead of below the next one
- Undoing "toggle keyframes" restores what it was before
- Undoing a brush change on a layer that had no brush removes the brush again, using the new Layer.RemoveLayerBrush
- Undoing "add element" disables the element again
- Undoing an event path change back to no path goes back to an event start node, like a new condition
- MoveProfileElement says "Move folder" for folders
- UpdateLayerProperty without a time no longer calls itself "Add ... keyframe"

* Profile editor - Fix auto-saving, failing commands, suspended editing and smaller editor issues

- A failed auto-save no longer stops auto-saving for the rest of the session
- A failing command is no longer also reported to ReactiveUI as unhandled, on top of the error dialog
- Resuming editing applies the editor's time again right away
- Nothing is focused while editing is suspended
- A layer created on another layer gets a name that isn't in use next to it
- CanUndo and CanRedo start out false, so new subscribers know the state right away
- An empty command scope doesn't add an undo step
- New subscribers to History get the current history once
- Expanding the keyframe selection with an already selected keyframe doesn't add it twice
- Snapping can snap to a snap time of zero
2026-10-24 16:17:05 +02:00
RobertBeekman 63186ee06d Core - Fix color gradient and utility bugs found by the tests (#914)
* Profile adaption - Fix arrow keys section including Page Down

- The arrow keys keyboard section now starts at Arrow Up instead of the key before it (Page Down)
- Updated the keyboard section test to expect only the four arrow keys

* Color quantizer - Let fully saturated colors be vibrant and grays be muted

- The saturation limits of the color types are now inclusive, so 100% saturated colors count as vibrant and 0% saturated colors count as muted
- The lightness limits stay exclusive so pure black and white are still left out
- Updated the quantizer tests to match

* Color gradients - Fix stop placement, seamless toggling and list events

- Stops on an occupied position now move down 0.001 instead of 0.002 (rounding error in the distance check)
- Flip, rotate, spread and interpolate move all stops together, so a stop can take a position another stop is leaving
- Spreading or randomizing a single stop puts it at 0 instead of NaN
- ToggleSeamless does nothing on an empty gradient and caps stretched stops at 1 instead of 100
- RemoveAt reports the removed stop and its index
- Insert links the stop like Add does and raises the add before the move
- Remove, RemoveAt, Clear and replacing a stop through the indexer unlink and stop listening to the actual removed stop
- Copying from a list of stops sorts them by position
- Obsolete GetPositionsArray no longer skips the seamless positions, obsolete GetColor picks the right colors after a repeat
- Updated the gradient tests to match

* Core - Fix small color, enum, string and type utility bugs

- Darken keeps the alpha of the color
- GetAllValuesAndDescriptions(Type) uses the [Description] attribute like the generic version
- UrlFriendly cuts titles at 80 characters instead of 81
- RemapInternationalCharToAscii knows both cases of r, l, d, thorn, sharp s, h and j with accents
- IsGenericType returns false instead of throwing when the base type is not generic
- IsCastableFrom also finds conversion operators declared on the target type
- GetDisplayName keeps the brackets of array types when humanizing
- Updated the utility tests to match
2026-10-24 15:53:52 +02:00
RobertBeekman 6df81b19b1 Core - Fix data model and event condition bugs found by the tests (#910)
* Core - Fix removing dynamic children and checking which properties are in use

- DataModel.RemoveDynamicChild compared the value of each child with the
  child that was passed in, so it never removed anything.
- IsPropertyInUse with includeChildren matched paths by their start, so
  a path to "Integers" made "Integer" count as in use. Children are now
  matched on what follows a dot.

* Core - Fix data model paths around saving, removed children and stored types

- The constructors saved the path before setting it up, while it was
  still invalid, so a new path stored nothing and didn't follow its data
  model leaving and returning to the store until it was saved.
- Removing the dynamic child a path points to left the path valid and
  reading a default value, it now becomes invalid like when the child
  was never there.
- The stored type of a path is now also looked up in all loaded
  assemblies, Type.GetType only found it in Artemis.Core and the .NET
  libraries, not in plugins or SkiaSharp.

* Core - Only let event conditions react to what happens after they start watching

- A trigger from before the condition watched its event, for example
  long before the profile was activated, counted as new and played the
  element once. Triggers now count from the moment the condition starts
  watching its path.
- A condition on a plain value treated the first value it saw as a
  change and played the element on the first frame. The first value is
  now taken as the starting value.
2026-10-20 13:46:06 +02:00
RobertBeekman a25d0f0c9c Core - Fix profile rendering and timeline bugs found by the tests (#909)
* Core - Keep the name of renamed layer effects when loading

BaseLayerEffect.Load checked HasBeenRenamed before reading it from the entity, so renamed effects always fell back to the descriptor's display name.

* Core - Apply layer effect filters once on layers

Layer.DelegateRendering composited the layer with the pre-processed paint and also handed that paint to the brush, so color and image filters of effects applied to the brush output and again when compositing. The brush now gets a copy of the paint without those filters, like folders which apply them once.

* Core - Disable folders that get suspended while enabled

Layer.Update disables a suspended layer but Folder.Update only disabled a folder once its timeline finished, so a folder suspended outside of the editor kept rendering its children.

* Core - Update device LEDs when rotating or scaling a device

The Rotation and Scale setters only updated the RGB.NET device, the Artemis LED rectangles and the device path kept their old positions and DeviceUpdated wasn't raised until X or Y was set.

* Core - Correct the docs of the Layer and Folder constructors

They claimed the new element adds itself to the child collection of the parent, it doesn't and callers rely on adding it themselves.

* Core - Apply layer opacity once for brushes that draw with the paint

Brushes drawing with a shader or image keep the alpha of the paint they are given, so the layer opacity and opacity effects applied to the brush output and again when compositing, 50% opacity rendered at 25%. The brush now gets an opaque paint, per-LED brushes already overrode the color. The solid color test brush now draws with a shader like the real solid brush so the opacity tests cover this.

* Tests - Describe expected faded colors by their opacity

Adds an AtOpacity helper so assertions read as red at 50% over black instead of a hand-computed 127, and uses it for layer opacity, opacity effects, folder fades, the profile fade and semi-transparent drawing.

* Core - Wrap timelines around by how far they went past the main segment

Repeating timelines wrapped around by the frame time rather than by how
far they went past the end of the main segment, so wrapping could be off
by up to a frame. A timeline that was already past the end, like the
finished timeline new layers start with, still starts the main segment
over.

* Tests - Mention the defaults the timeline wrap-around tests depend on
2026-10-20 13:30:04 +02:00
RobertBeekman 504845c7d2 Tests - Add Artemis.Core and profile editor test suites (#907) 2026-10-20 09:22:10 +02:00
RobertBeekman 6e7fae16d2 Merge pull request #903 from senposage/codex/close-process-query-handles
Close process query handles
2026-10-17 21:12:15 +02:00
RobertBeekman ce5fa00aed Core - Stop sampling SKTexture after disposal 2026-10-17 20:38:30 +02:00
rjc862003 02dd7df5dd Reduce per-frame texture readback allocations 2026-10-17 20:38:30 +02:00
RobertBeekman e1357f1bf0 Core - Keep small LEDs addressable at reduced render scales
Sample each LED from its unsnapped absolute boundary instead of the
render-grid-aligned AbsoluteRectangle, ensuring at least one pixel and
clamping to the texture. Also apply the saved render scale at startup.
2026-10-17 20:38:30 +02:00
rjc862003 2b29c15cf1 Close process query handles 2026-10-01 23:49:22 -04:00
Robert 9bc4eca7f9 UI - Fix back-button not always working (I blame you, Avalonia)
Workshop - Add a EF migration to fix entry types based on metadata
2025-12-27 21:42:09 +01:00
Robert efd893c209 Workshop - Fix misalignment in EntryTypes causing plugins to not load
Core - Downgrade SkiaSharp back to what Avalonia likes, 2.88.9
2025-12-23 20:53:39 +01:00
Robert 6bf5a11108 Workshop - Improved workshop entry compatibility handling
Workshop - Added minimum Artemis version to releases
2025-12-22 20:13:49 +01:00
Robert 86f2426f37 Core - Remove API versioning, we have MinimumVersion to achieve the same thing 2025-12-19 23:11:27 +01:00
Robert 55dca6cebb Upgrade packages
Update namespaces
Clean up unused imports
Replace Avalonia.ReactiveUI with ReactiveUI.Avalonia 🙄
2025-12-16 22:28:16 +01:00
Robert bda247d3c3 Streamlines plugin management and installation
Refactors plugin handling for improved reliability and user experience.

- Removes built-in plugin copying, migrating to workshop-based installation
- Introduces a dedicated service for plugin interactions (enabling, disabling, removal, settings)
- Simplifies plugin enabling/disabling logic in the UI, centralizing the logic
2025-12-12 18:29:24 +01:00
Robert 06c5294e88 Profile editor - Fix race condition causing the editor to fail to activate on suspended profiles
Surface editor - Implemented left-handed preset
2025-12-11 22:55:31 +01:00
Robert 3c8d8b2387 Plugins - Allow config window to be mandatory
UI - Move profile editor into Profile screen, profile page no longer always has to show the editor
2025-12-09 20:42:13 +01:00
Robert 565647f1ed Workshop - Improves default entry handling in workshop
Core - Modifies the Artemis data folder path based on the build configuration.
Plugins - Adds a confirmation dialog to prompt the user to restart if a plugin requires admin rights.
Startup wizard - Updates the installation progress bar in the startup wizard.
Workshop - Changes category retrieval to be based on EntryType.
Workshop - Adds the ability to include default entries when searching the workshop.
2025-12-08 22:27:18 +01:00
Robert 6d1e39c1cc Try HotReload 3.0 2025-11-22 00:01:11 +01:00
Robert b351f685f7 Add AXAML hot reload (debug only)
Major progress on default entries too I guess lmao
2025-11-15 15:07:54 +01:00
Robert 10a10b9149 Plugin Settings - When searching, search in plugin and features
Plugin Settings - Never scroll inside feature list, just show everything if a plugin has many features
2025-02-16 17:06:22 +01:00
Robert 37b8c2c3e9 Webserver - Add option to enable remote access 2025-02-16 12:05:26 +01:00
RobertBeekman 17e6c655ff Core - Replace EmbedIO with GenHTTP
Replace EmbedIO with GenHTTP
2025-02-15 16:53:05 +01:00
Robert fcf00af130 Add missing status handler, add TODO 2025-02-15 16:52:26 +01:00
Robert 7176aba0d6 Nodes - Inform nodes they are being loaded using the new IsLoading property 2025-02-14 22:15:03 +01:00
Robert 0a26319914 Remove unneccesary error handler 2025-02-14 18:20:54 +01:00
Robert eb4a6ceafb Finish implementing GenHTTP 2025-02-13 21:35:35 +01:00
Robert e09389c6db Replace EmbedIO with GenHTTP 2025-02-08 22:48:51 +01:00
Robert cfdcbe44c9 Meta - Update dependencies 2025-02-04 20:52:09 +01:00
Robert d725234d56 Storage - Downgrade EF for now to latest 8.x
Core - Include backwards compatible color quantizer methods
2024-11-14 14:58:54 +01:00
Robert 37f973b093 Core - Removed scripting providers
Meta - Updated packages
2024-11-14 14:09:51 +01:00
Robert 7691af95b9 Merge remote-tracking branch 'origin/RGB.NET_v3' into development 2024-11-14 13:30:08 +01:00
DarthAffe 5d82c159e1 Replaced the quantization code and with the HPPH implementation 2024-07-22 23:52:50 +02:00
DarthAffe db84f1dc75 Major upgrade of RGB.NET to v3 2024-07-22 23:26:53 +02:00
Robert a793a08213 Merge branch 'development' 2024-07-22 11:02:05 +02:00
Robert 99d11e1921 Workshop - Redesigned library
Workshop - Limit screen width to keep main content at 1000px
Workshop - Auto-updating WIP
2024-07-13 20:25:40 +02:00
Robert bd904178c8 Merge branch 'development' 2024-07-04 20:16:21 +02:00
Robert 00948de9d6 Workshop - Fix installing new versions of profiles 2024-07-02 22:34:25 +02:00
Robert 648b7765ef Core - Added API for retrieving current suspended device providers
Core - Added events for plugin removal, entry installlation/uninstallation
Workshop - Remove the related workshop entry when manually removing a plugin or profile
Workshop - Prevent installing profiles with missing plugins and show a dialog with which plugins are missing
2024-06-30 09:42:41 +02:00
Robert 7052ee38b6 Merge branch 'development' 2024-05-18 13:32:53 +02:00
RobertBeekman 3022c7df65 Core - Add device provider suspension system 2024-05-16 20:40:45 +02:00
Robert d9a3a238af Merge branch 'development' 2024-05-03 21:08:48 +02:00
Robert 10ad1d6a58 Core - Remove DataModelPath equality override 2024-05-03 21:08:39 +02:00
RobertBeekman 957bfde0af Workshop - Added layout finder 2024-05-02 20:02:12 +02:00
Robert 058513fd2a Merge branch 'development' 2024-04-14 16:00:08 +02:00
Robert f152812064 Device properties - Show layout error state 2024-03-30 20:28:01 +01:00
RobertBeekman e5cb058152 Merge branch 'development' 2024-03-21 20:15:58 +01:00