This updates more code that was using RelativeToParent() to use the
stacking context helper's ToRelativeWr* functions instead. This get us
closer to breaking the assumption that the WR stacking context order maps
1:1 to the layer tree structure.
MozReview-Commit-ID: HQrbvCgPOW4
Update for blob image and yuv image interface changes.
The implementation of the blob image renderer is empty now. It will need to be
updated in another commit. This also adds wr_dp_push_yuv_*_image() functions in
WebRenderAPI.
There is no change for |./mach vendor rust|.
MozReview-Commit-ID: Kk2rPAmt3vF
The new parameter "channel index" is used to select the specific channel data from a multiple channel textureHost(e.g. yuv format textureHost).
MozReview-Commit-ID: Ey1cA25Z6WH
In addition to updating the Cargo.toml/Cargo.lock files and generated FFI header,
this patch also:
- Updates a couple of field names in the IPC serialization code as a result
of webrender cset 8ca10a8
- Removes z-index related goop, since it's no longer needed as of webrender
cset c872232
Apparently passing a nullptr to slice::from_raw_parts is unsafe. So we
wrap those calls into a helper function that returns an empty slice
instead.
MozReview-Commit-ID: EAp90FKb8cQ
In addition to regenerating the FFI header and re-vendoring third-party rust
dependencies, this includes the following changes to webrender_bindings code:
- removal of release callback function as a result of changes in 86d4255
- update callback functions for new parameter added in d733af2
- update calls to add_raw_font for API change in 21f2946
The new rustfmt.toml is based off servo/rustfmt.toml with some
tweaks to match the existing code in webrender_bindings
MozReview-Commit-ID: 7LbXC6qyjan
--HG--
extra : amend_source : 436e49dbd3d3fd72aab0f1791cf6e0d3fcc348b4
Types also implement Copy, Clone now to make this easier.
MozReview-Commit-ID: GEVsCEw2o6K
--HG--
extra : rebase_source : b42ddaab3b7ab0a31006e78aff45ddb6e4160845
extra : amend_source : 82a7e1d272b397c8ab1d0346fd5a708117b897a3
This also includes changes to webrender_bindings:
- push_scroll_layer was renamed to push_clip_node in eb4a04b
- Update call to push_text for API change in f040e81.
MozReview-Commit-ID: ILHylvSkco2
Note that in upstream WR the push_scroll_layer API has already been
renamed to push_clip_node, so conceptually the same API covers both
"scrolling clips" (aka scroll layers) and non-scrolling clips. So using
the same underlying API for two different WebRenderAPI.h functions makes
sense.
MozReview-Commit-ID: He7jBVqZuLn
This commit adds some directives to help cbindgen generate correct
structs and functions, removes some old FFI code that isn't needed
anymore, and regenerates webrender_ffi_generated.h
MozReview-Commit-ID: KZSEZEN671A
--HG--
extra : rebase_source : 23a07dd11037943156983d9facc039bb7af51c95
This is only temporary as ExternalImageId has been made repr(C) upstream.
MozReview-Commit-ID: 1On7fRbNI4o
--HG--
extra : rebase_source : 91cb93829de5ccf0a6f0a05ed0d2169268b6c18c
This helps cbindgen know to generate a opaque struct for WrRenderedEpochs.
MozReview-Commit-ID: 7moOEBjjbOO
--HG--
extra : rebase_source : 49b3887ae21f659ac353b861f3566cc2817103b0
This removes the call to push_scroll_layer in wr_push_stacking_context, so that
it's now possible to push a stacking context without necessarily pushing a
scroll layer. There is already a separate function to push a scroll layer so the
call sites can do that. This patch just changes all the call sites that were
pushing a stacking context to also push a scroll layer, so there should be no
functional change. Future patches can remove the spurious scroll layers.
MozReview-Commit-ID: FtCkc9JQd8l
This includes:
- updating calls to push_scroll_layer for API change in 7253e2f.
- updating calls to push_stacking_context for API change in be249f6.
- updating for changes to gradient APIs in 05c4293.
Right now we just cast from a float* on the C++ side to a LayoutTransform on
the Rust side, except the LayoutTransform isn't a repr(C) storage type, so
there's no guarantee that it will actually have the same layout. Adding an
explicit type and conversion code ensure that we are able to pass the matrix
across the boundary safely.
MozReview-Commit-ID: H3gK3g0K3xz
The WrExternalImageId is currently a struct wrapping a uint64_t on the C++ side,
which is unnecessary as we can just typedef it directly to a uint64_t. On the
Rust side it's a tuple of (u64).
Also the WrExternalImageIdType enum should be WrExternalImageType for consistency.
MozReview-Commit-ID: DgOf4xfY9h3
The binding generator just takes the Rust field names and uses that in the
generated C++ structs. So installing the autogenerated bindings is easier if
we make sure the names are the same ahead of time.
MozReview-Commit-ID: 6cuzmtI5Qqw
This patch:
- adds a type alias for ExternalImageId and updates uses.
- renames WrExternalImageStruct to drop the "Struct" suffix which is redundant
and not present in the corresponding C++ struct.
- updates the delete-font function to use aliases I added previously.
MozReview-Commit-ID: ILsFihkMlIw
On the C++ side the enum extends from uint32_t, like all the other enums across
the WR FFI boundary. So the Rust side they should be repr(u32).
MozReview-Commit-ID: JOf44I154ea