It looks like the premake5 "v5.0.0-beta3" tag isn't compatible with
Sequoia 15.4.1. Bump our tag to v5.0.0-beta7 and update the deprecated
features we had been using.
Also fix the script to rebuild if the premake5 binary doesn't exist.
Before it only checked if the parent "premake-core" directory existed,
so if a build had failed previously, build_rive.sh would fail forever
without ever attempting to build premake5 again.
Co-authored-by: Chris Dalton <99840794+csmartdalton@users.noreply.github.com>
Co-authored-by: Jonathon Copeland <jcopela4@gmail.com>
* added filter type to draw batch
* c++ implementation of ImageSamplerOptions
* image sampler options now pushes correct for RiveRenderPaint
* wip
* OpenGL uses correct sample options
* now only one filter option that accounts for mip map
* d3d now uses sampler states options
* better way to get the filter option
* added mirror and inverse mirror options
* started using helper functions for retreiving sampler optiojnhs
* workaround for vulkn semaphore issue
* wip
* added filter type to draw batch
* c++ implementation of ImageSamplerOptions
* image sampler options now pushes correct for RiveRenderPaint
* wip
* OpenGL uses correct sample options
* now only one filter option that accounts for mip map
* d3d now uses sampler states options
* better way to get the filter option
* added mirror and inverse mirror options
* started using helper functions for retreiving sampler optiojnhs
* workaround for vulkn semaphore issue
* wip
* undo deleting empty descriptor
* properly packed image options
* removed uneeded checks
* more unit tests
* unreal image_filter_options integration, gm for image filters
* properly implement new draw functions for cgrender
* finish mege conflicts
* merge vulkan sampler options
* cherry-picked vulkan imp into branch
* initial metal
* clang-format
* d3d12 image filter options
* fixed d3d
* clang-format
* fixed mip filter for metal
* made every filter option act as similiar as possible
* addressed pr changes
* fixed tests
* empty commit to fix github
* fix: webgl renderers
* started addressing PR comments
* metal change for pr
* more pr stuff
* final PR address
* shader update per PR request
* rhi updat e
* added gm requested in pr
* made d3d12 work with more then 2000 sampler changes per flush
* pr comments
Co-authored-by: Chris Dalton <chris@rive.app>
Co-authored-by: Jonathon Copeland <jcopela4@gmail.com>
Co-authored-by: Luigi Rosso <luigi.rosso@gmail.com>
Addresses this issue: https://2dimensions.slack.com/archives/C07VD44ASE5/p1739456802968219
Rive's RenderPath steals the memory for the RawPath the runtime builds, which is usually fine apart from cases where we expect to use the RawPath after drawing with it. For example, with inner feather we want to be able to compute the bounds of the RawPath after it has been drawn. If during animation a user turns on inner feathering on a path which has not changed recently, which need to be able to compute its bounds, we can't if the RawPath is now gone.
This also can happen with trim paths and dash paths which are re-trimmed/dashed after having being rendered a few frames. Right now we force rebuild the whole path to re-trim it because we lose the RawPath.
This PR allows the ShapePaintPath to hold on to its RawPath by adding RenderPath::addRawPath. This is optimized memory usage but not having the runtime need to re-alloc the RawPath whenever it animates, but it means we're further from making RenderPaths immutable.
For the future: It'd be good to chat about a long term solution that can accommodate all goals of allocating less memory (prior to this change we were re-allocating RawPath memory every frame when animating), not rebuilding paths as often, and still allow for immutability.
Diffs=
9058a3fdad Add RenderPath::addRawPath (#9038)
Co-authored-by: Luigi Rosso <luigi-rosso@users.noreply.github.com>
Made lite rtti now use compile time hashes that use the name of the class with rtti enabled as the hash string.
Every use of rtti now needs to be a macro. but other then that, usage of lite rtti is unchanged.
Diffs=
2be44a0f45 Deterministic lite rtti (#8349)
Co-authored-by: Jonathon Copeland <jcopela4@gmail.com>
This gives better support for smaller screens and side-by-side windows.
Also standardize the formatting check on GitHub on version 17.
Diffs=
e52e9fff29 Drop the ColumnLimit to 80 for clang-format (#8320)
Co-authored-by: Chris Dalton <99840794+csmartdalton@users.noreply.github.com>
Also delete TestingWindow::Renderer (it's always tied to the TestingWindow subclass now), and delete the Skia renderers. This drastically speeds up link times.
Diffs=
9b755ed5b Unlink skia from goldens (#7991)
Co-authored-by: Chris Dalton <99840794+csmartdalton@users.noreply.github.com>
Follow up to #7048!
I nuked the custom defines and the miniaudio include. I think this fixes the need for miniaudio and the custom defines @mjtalbot! Give it a shot 🔫
Diffs=
89053041a add out of band audio support ios - abstracted audio! (#7079)
Co-authored-by: Luigi Rosso <luigi-rosso@users.noreply.github.com>
Co-authored-by: Maxwell Talbot <talbot.maxwell@gmail.com>
We need to be more robust if a user tries to use mismatched factories and renderers. This PR creates a simple "lite_rtti" utility and applies it to every Render object. The renderers now abort early instead of crashing if they are given a Render object for the wrong renderer.
Diffs=
c357e7aa7 Add a "lite_rtti" utility and use it with Render objects (#6311)
Co-authored-by: Chris Dalton <99840794+csmartdalton@users.noreply.github.com>
Ok, got this passing testes, which I guess is a step in the right direction.
Before changing unique pointers to rcp, we could only use an image once, as soon as we assigned a new image, the old image would get garbage collected. (this is the actual problem we are trying to solve)
This "solves" the problem and allows us to add images to a cache in wasm, and then cycle through the cache, swapping out the render image to be displayed for a given fileAsset. We can replace images & fonts on the fly this way.
Problems:
1. overwriting ref & unref in RenderImage, shows that is being reffed and un-reffed constantly (when viewing the attached file with the viewer). Is that expected? doing something similar for Font does not show up the same. I suspect this is related to how we use images when it comes to rendering, just figured i'd check
2. We dont seem to "leak" anything as detectable by our tests, which is good, but our wasm examples show that neither our fonts nor our render images get collected. presumably thats because we would need to manually tell wasm via js that we want to let go of an image?
Also @csmartdalton @umberto-sonnino & @luigi-rosso it would be great to see what else is concerning.
example file
[just_a_box_with_a_tree.riv.zip](https://github.com/rive-app/rive/files/13042414/just_a_box_with_a_tree.riv.zip)
Diffs=
1506b069c Outofbandcache (#6049)
Co-authored-by: Maxwell Talbot <talbot.maxwell@gmail.com>
Some systems we want to integrate with expect these features.
Diffs=
d65b239c5 Add options to build with rtti and exceptions (#6121)
Co-authored-by: Chris Dalton <99840794+csmartdalton@users.noreply.github.com>