Backed out changeset 928f5840c78d (bug 1392200) for Windows bustage at gfx/layers/d3d11/TextureD3D11.cpp(1132). r=backout

This commit is contained in:
Sebastian Hengst 2017-09-20 18:13:39 +02:00
Родитель 6ba627d8ce
Коммит ccf82e3842
4 изменённых файлов: 36 добавлений и 127 удалений

Просмотреть файл

@ -663,8 +663,7 @@ DisplayListBuilder::PushStackingContext(const wr::LayoutRect& aBounds,
wr::TransformStyle aTransformStyle,
const gfx::Matrix4x4* aPerspective,
const wr::MixBlendMode& aMixBlendMode,
const nsTArray<wr::WrFilterOp>& aFilters,
bool aIsBackfaceVisible)
const nsTArray<wr::WrFilterOp>& aFilters)
{
wr::LayoutTransform matrix;
if (aTransform) {
@ -680,7 +679,7 @@ DisplayListBuilder::PushStackingContext(const wr::LayoutRect& aBounds,
aTransform ? Stringify(*aTransform).c_str() : "none");
wr_dp_push_stacking_context(mWrState, aBounds, aAnimationId, aOpacity,
maybeTransform, aTransformStyle, maybePerspective,
aMixBlendMode, aFilters.Elements(), aFilters.Length(), aIsBackfaceVisible);
aMixBlendMode, aFilters.Elements(), aFilters.Length());
}
void
@ -801,20 +800,18 @@ DisplayListBuilder::PopClipAndScrollInfo()
void
DisplayListBuilder::PushRect(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::ColorF& aColor)
{
WRDL_LOG("PushRect b=%s cl=%s c=%s\n", mWrState,
Stringify(aBounds).c_str(),
Stringify(aClip).c_str(),
Stringify(aColor).c_str());
wr_dp_push_rect(mWrState, aBounds, aClip, aIsBackfaceVisible, aColor);
wr_dp_push_rect(mWrState, aBounds, aClip, aColor);
}
void
DisplayListBuilder::PushLinearGradient(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::LayoutPoint& aStartPoint,
const wr::LayoutPoint& aEndPoint,
const nsTArray<wr::GradientStop>& aStops,
@ -823,7 +820,7 @@ DisplayListBuilder::PushLinearGradient(const wr::LayoutRect& aBounds,
const wr::LayoutSize aTileSpacing)
{
wr_dp_push_linear_gradient(mWrState,
aBounds, aClip, aIsBackfaceVisible,
aBounds, aClip,
aStartPoint, aEndPoint,
aStops.Elements(), aStops.Length(),
aExtendMode,
@ -833,7 +830,6 @@ DisplayListBuilder::PushLinearGradient(const wr::LayoutRect& aBounds,
void
DisplayListBuilder::PushRadialGradient(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::LayoutPoint& aCenter,
const wr::LayoutSize& aRadius,
const nsTArray<wr::GradientStop>& aStops,
@ -842,7 +838,7 @@ DisplayListBuilder::PushRadialGradient(const wr::LayoutRect& aBounds,
const wr::LayoutSize aTileSpacing)
{
wr_dp_push_radial_gradient(mWrState,
aBounds, aClip, aIsBackfaceVisible,
aBounds, aClip,
aCenter, aRadius,
aStops.Elements(), aStops.Length(),
aExtendMode,
@ -852,20 +848,18 @@ DisplayListBuilder::PushRadialGradient(const wr::LayoutRect& aBounds,
void
DisplayListBuilder::PushImage(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
wr::ImageRendering aFilter,
wr::ImageKey aImage)
{
wr::LayoutSize size;
size.width = aBounds.size.width;
size.height = aBounds.size.height;
PushImage(aBounds, aClip, aIsBackfaceVisible, size, size, aFilter, aImage);
PushImage(aBounds, aClip, size, size, aFilter, aImage);
}
void
DisplayListBuilder::PushImage(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::LayoutSize& aStretchSize,
const wr::LayoutSize& aTileSpacing,
wr::ImageRendering aFilter,
@ -875,13 +869,12 @@ DisplayListBuilder::PushImage(const wr::LayoutRect& aBounds,
Stringify(aBounds).c_str(),
Stringify(aClip).c_str(), Stringify(aStretchSize).c_str(),
Stringify(aTileSpacing).c_str());
wr_dp_push_image(mWrState, aBounds, aClip, aIsBackfaceVisible, aStretchSize, aTileSpacing, aFilter, aImage);
wr_dp_push_image(mWrState, aBounds, aClip, aStretchSize, aTileSpacing, aFilter, aImage);
}
void
DisplayListBuilder::PushYCbCrPlanarImage(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
wr::ImageKey aImageChannel0,
wr::ImageKey aImageChannel1,
wr::ImageKey aImageChannel2,
@ -891,7 +884,6 @@ DisplayListBuilder::PushYCbCrPlanarImage(const wr::LayoutRect& aBounds,
wr_dp_push_yuv_planar_image(mWrState,
aBounds,
aClip,
aIsBackfaceVisible,
aImageChannel0,
aImageChannel1,
aImageChannel2,
@ -902,7 +894,6 @@ DisplayListBuilder::PushYCbCrPlanarImage(const wr::LayoutRect& aBounds,
void
DisplayListBuilder::PushNV12Image(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
wr::ImageKey aImageChannel0,
wr::ImageKey aImageChannel1,
wr::WrYuvColorSpace aColorSpace,
@ -911,7 +902,6 @@ DisplayListBuilder::PushNV12Image(const wr::LayoutRect& aBounds,
wr_dp_push_yuv_NV12_image(mWrState,
aBounds,
aClip,
aIsBackfaceVisible,
aImageChannel0,
aImageChannel1,
aColorSpace,
@ -921,7 +911,6 @@ DisplayListBuilder::PushNV12Image(const wr::LayoutRect& aBounds,
void
DisplayListBuilder::PushYCbCrInterleavedImage(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
wr::ImageKey aImageChannel0,
wr::WrYuvColorSpace aColorSpace,
wr::ImageRendering aRendering)
@ -929,7 +918,6 @@ DisplayListBuilder::PushYCbCrInterleavedImage(const wr::LayoutRect& aBounds,
wr_dp_push_yuv_interleaved_image(mWrState,
aBounds,
aClip,
aIsBackfaceVisible,
aImageChannel0,
aColorSpace,
aRendering);
@ -937,16 +925,14 @@ DisplayListBuilder::PushYCbCrInterleavedImage(const wr::LayoutRect& aBounds,
void
DisplayListBuilder::PushIFrame(const wr::LayoutRect& aBounds,
bool aIsBackfaceVisible,
PipelineId aPipeline)
{
wr_dp_push_iframe(mWrState, aBounds, aIsBackfaceVisible, aPipeline);
wr_dp_push_iframe(mWrState, aBounds, aPipeline);
}
void
DisplayListBuilder::PushBorder(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::BorderWidths& aWidths,
const Range<const wr::BorderSide>& aSides,
const wr::BorderRadius& aRadius)
@ -955,14 +941,13 @@ DisplayListBuilder::PushBorder(const wr::LayoutRect& aBounds,
if (aSides.length() != 4) {
return;
}
wr_dp_push_border(mWrState, aBounds, aClip, aIsBackfaceVisible,
wr_dp_push_border(mWrState, aBounds, aClip,
aWidths, aSides[0], aSides[1], aSides[2], aSides[3], aRadius);
}
void
DisplayListBuilder::PushBorderImage(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::BorderWidths& aWidths,
wr::ImageKey aImage,
const wr::NinePatchDescriptor& aPatch,
@ -970,7 +955,7 @@ DisplayListBuilder::PushBorderImage(const wr::LayoutRect& aBounds,
const wr::RepeatMode& aRepeatHorizontal,
const wr::RepeatMode& aRepeatVertical)
{
wr_dp_push_border_image(mWrState, aBounds, aClip, aIsBackfaceVisible,
wr_dp_push_border_image(mWrState, aBounds, aClip,
aWidths, aImage, aPatch, aOutset,
aRepeatHorizontal, aRepeatVertical);
}
@ -978,7 +963,6 @@ DisplayListBuilder::PushBorderImage(const wr::LayoutRect& aBounds,
void
DisplayListBuilder::PushBorderGradient(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::BorderWidths& aWidths,
const wr::LayoutPoint& aStartPoint,
const wr::LayoutPoint& aEndPoint,
@ -986,7 +970,7 @@ DisplayListBuilder::PushBorderGradient(const wr::LayoutRect& aBounds,
wr::ExtendMode aExtendMode,
const wr::SideOffsets2D_f32& aOutset)
{
wr_dp_push_border_gradient(mWrState, aBounds, aClip, aIsBackfaceVisible,
wr_dp_push_border_gradient(mWrState, aBounds, aClip,
aWidths, aStartPoint, aEndPoint,
aStops.Elements(), aStops.Length(),
aExtendMode, aOutset);
@ -995,7 +979,6 @@ DisplayListBuilder::PushBorderGradient(const wr::LayoutRect& aBounds,
void
DisplayListBuilder::PushBorderRadialGradient(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::BorderWidths& aWidths,
const wr::LayoutPoint& aCenter,
const wr::LayoutSize& aRadius,
@ -1004,7 +987,7 @@ DisplayListBuilder::PushBorderRadialGradient(const wr::LayoutRect& aBounds,
const wr::SideOffsets2D_f32& aOutset)
{
wr_dp_push_border_radial_gradient(
mWrState, aBounds, aClip, aIsBackfaceVisible, aWidths, aCenter,
mWrState, aBounds, aClip, aWidths, aCenter,
aRadius, aStops.Elements(), aStops.Length(),
aExtendMode, aOutset);
}
@ -1012,13 +995,12 @@ DisplayListBuilder::PushBorderRadialGradient(const wr::LayoutRect& aBounds,
void
DisplayListBuilder::PushText(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const gfx::Color& aColor,
wr::FontInstanceKey aFontKey,
Range<const wr::GlyphInstance> aGlyphBuffer,
const wr::GlyphOptions* aGlyphOptions)
{
wr_dp_push_text(mWrState, aBounds, aClip, aIsBackfaceVisible,
wr_dp_push_text(mWrState, aBounds, aClip,
ToColorF(aColor),
aFontKey,
&aGlyphBuffer[0], aGlyphBuffer.length(),
@ -1027,10 +1009,9 @@ DisplayListBuilder::PushText(const wr::LayoutRect& aBounds,
void
DisplayListBuilder::PushLine(const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::Line& aLine)
{
wr_dp_push_line(mWrState, aClip, aIsBackfaceVisible, aLine.baseline, aLine.start, aLine.end,
wr_dp_push_line(mWrState, aClip, aLine.baseline, aLine.start, aLine.end,
aLine.orientation, aLine.width, aLine.color, aLine.style);
/* TODO(Gankro): remove this
@ -1054,10 +1035,9 @@ DisplayListBuilder::PushLine(const wr::LayoutRect& aClip,
void
DisplayListBuilder::PushTextShadow(const wr::LayoutRect& aRect,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::TextShadow& aShadow)
{
wr_dp_push_text_shadow(mWrState, aRect, aClip, aIsBackfaceVisible, aShadow);
wr_dp_push_text_shadow(mWrState, aRect, aClip, aShadow);
}
void
@ -1069,7 +1049,6 @@ DisplayListBuilder::PopTextShadow()
void
DisplayListBuilder::PushBoxShadow(const wr::LayoutRect& aRect,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::LayoutRect& aBoxBounds,
const wr::LayoutVector2D& aOffset,
const wr::ColorF& aColor,
@ -1078,7 +1057,7 @@ DisplayListBuilder::PushBoxShadow(const wr::LayoutRect& aRect,
const float& aBorderRadius,
const wr::BoxShadowClipMode& aClipMode)
{
wr_dp_push_box_shadow(mWrState, aRect, aClip, aIsBackfaceVisible,
wr_dp_push_box_shadow(mWrState, aRect, aClip,
aBoxBounds, aOffset, aColor,
aBlurRadius, aSpreadRadius, aBorderRadius,
aClipMode);

Просмотреть файл

@ -219,8 +219,7 @@ public:
wr::TransformStyle aTransformStyle,
const gfx::Matrix4x4* aPerspective,
const wr::MixBlendMode& aMixBlendMode,
const nsTArray<wr::WrFilterOp>& aFilters,
bool aIsBackfaceVisible);
const nsTArray<wr::WrFilterOp>& aFilters);
void PopStackingContext();
wr::WrClipId DefineClip(const wr::LayoutRect& aClipRect,
@ -244,12 +243,10 @@ public:
void PushRect(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::ColorF& aColor);
void PushLinearGradient(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::LayoutPoint& aStartPoint,
const wr::LayoutPoint& aEndPoint,
const nsTArray<wr::GradientStop>& aStops,
@ -259,7 +256,6 @@ public:
void PushRadialGradient(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::LayoutPoint& aCenter,
const wr::LayoutSize& aRadius,
const nsTArray<wr::GradientStop>& aStops,
@ -269,13 +265,11 @@ public:
void PushImage(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
wr::ImageRendering aFilter,
wr::ImageKey aImage);
void PushImage(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::LayoutSize& aStretchSize,
const wr::LayoutSize& aTileSpacing,
wr::ImageRendering aFilter,
@ -283,7 +277,6 @@ public:
void PushYCbCrPlanarImage(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
wr::ImageKey aImageChannel0,
wr::ImageKey aImageChannel1,
wr::ImageKey aImageChannel2,
@ -292,7 +285,6 @@ public:
void PushNV12Image(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
wr::ImageKey aImageChannel0,
wr::ImageKey aImageChannel1,
wr::WrYuvColorSpace aColorSpace,
@ -300,27 +292,23 @@ public:
void PushYCbCrInterleavedImage(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
wr::ImageKey aImageChannel0,
wr::WrYuvColorSpace aColorSpace,
wr::ImageRendering aFilter);
void PushIFrame(const wr::LayoutRect& aBounds,
bool aIsBackfaceVisible,
wr::PipelineId aPipeline);
// XXX WrBorderSides are passed with Range.
// It is just to bypass compiler bug. See Bug 1357734.
void PushBorder(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::BorderWidths& aWidths,
const Range<const wr::BorderSide>& aSides,
const wr::BorderRadius& aRadius);
void PushBorderImage(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::BorderWidths& aWidths,
wr::ImageKey aImage,
const wr::NinePatchDescriptor& aPatch,
@ -330,7 +318,6 @@ public:
void PushBorderGradient(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::BorderWidths& aWidths,
const wr::LayoutPoint& aStartPoint,
const wr::LayoutPoint& aEndPoint,
@ -340,7 +327,6 @@ public:
void PushBorderRadialGradient(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::BorderWidths& aWidths,
const wr::LayoutPoint& aCenter,
const wr::LayoutSize& aRadius,
@ -350,19 +336,16 @@ public:
void PushText(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const gfx::Color& aColor,
wr::FontInstanceKey aFontKey,
Range<const wr::GlyphInstance> aGlyphBuffer,
const wr::GlyphOptions* aGlyphOptions = nullptr);
void PushLine(const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::Line& aLine);
void PushTextShadow(const wr::LayoutRect& aBounds,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::TextShadow& aShadow);
void PopTextShadow();
@ -371,7 +354,6 @@ public:
void PushBoxShadow(const wr::LayoutRect& aRect,
const wr::LayoutRect& aClip,
bool aIsBackfaceVisible,
const wr::LayoutRect& aBoxBounds,
const wr::LayoutVector2D& aOffset,
const wr::ColorF& aColor,

Просмотреть файл

@ -1114,8 +1114,7 @@ pub extern "C" fn wr_dp_push_stacking_context(state: &mut WrState,
perspective: *const LayoutTransform,
mix_blend_mode: MixBlendMode,
filters: *const WrFilterOp,
filter_count: usize,
is_backface_visible: bool) {
filter_count: usize) {
assert!(unsafe { !is_in_render_thread() });
let c_filters = make_slice(filters, filter_count);
@ -1157,9 +1156,7 @@ pub extern "C" fn wr_dp_push_stacking_context(state: &mut WrState,
None => None,
};
let mut prim_info = LayoutPrimitiveInfo::new(bounds);
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::new(bounds);
state.frame_builder
.dl_builder
.push_stacking_context(&prim_info,
@ -1275,12 +1272,10 @@ pub extern "C" fn wr_dp_pop_clip_and_scroll_info(state: &mut WrState) {
#[no_mangle]
pub extern "C" fn wr_dp_push_iframe(state: &mut WrState,
rect: LayoutRect,
is_backface_visible: bool,
pipeline_id: WrPipelineId) {
assert!(unsafe { is_in_main_thread() });
let mut prim_info = LayoutPrimitiveInfo::new(rect);
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::new(rect);
state.frame_builder.dl_builder.push_iframe(&prim_info, pipeline_id);
}
@ -1288,12 +1283,10 @@ pub extern "C" fn wr_dp_push_iframe(state: &mut WrState,
pub extern "C" fn wr_dp_push_rect(state: &mut WrState,
rect: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
color: ColorF) {
assert!(unsafe { !is_in_render_thread() });
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
state.frame_builder.dl_builder.push_rect(&prim_info,
color);
}
@ -1302,15 +1295,13 @@ pub extern "C" fn wr_dp_push_rect(state: &mut WrState,
pub extern "C" fn wr_dp_push_image(state: &mut WrState,
bounds: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
stretch_size: LayoutSize,
tile_spacing: LayoutSize,
image_rendering: ImageRendering,
key: WrImageKey) {
assert!(unsafe { is_in_main_thread() || is_in_compositor_thread() });
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
state.frame_builder
.dl_builder
.push_image(&prim_info,
@ -1325,7 +1316,6 @@ pub extern "C" fn wr_dp_push_image(state: &mut WrState,
pub extern "C" fn wr_dp_push_yuv_planar_image(state: &mut WrState,
bounds: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
image_key_0: WrImageKey,
image_key_1: WrImageKey,
image_key_2: WrImageKey,
@ -1333,8 +1323,7 @@ pub extern "C" fn wr_dp_push_yuv_planar_image(state: &mut WrState,
image_rendering: ImageRendering) {
assert!(unsafe { is_in_main_thread() || is_in_compositor_thread() });
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
state.frame_builder
.dl_builder
.push_yuv_image(&prim_info,
@ -1348,15 +1337,13 @@ pub extern "C" fn wr_dp_push_yuv_planar_image(state: &mut WrState,
pub extern "C" fn wr_dp_push_yuv_NV12_image(state: &mut WrState,
bounds: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
image_key_0: WrImageKey,
image_key_1: WrImageKey,
color_space: WrYuvColorSpace,
image_rendering: ImageRendering) {
assert!(unsafe { is_in_main_thread() || is_in_compositor_thread() });
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
state.frame_builder
.dl_builder
.push_yuv_image(&prim_info,
@ -1370,14 +1357,12 @@ pub extern "C" fn wr_dp_push_yuv_NV12_image(state: &mut WrState,
pub extern "C" fn wr_dp_push_yuv_interleaved_image(state: &mut WrState,
bounds: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
image_key_0: WrImageKey,
color_space: WrYuvColorSpace,
image_rendering: ImageRendering) {
assert!(unsafe { is_in_main_thread() || is_in_compositor_thread() });
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
state.frame_builder
.dl_builder
.push_yuv_image(&prim_info,
@ -1390,7 +1375,6 @@ pub extern "C" fn wr_dp_push_yuv_interleaved_image(state: &mut WrState,
pub extern "C" fn wr_dp_push_text(state: &mut WrState,
bounds: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
color: ColorF,
font_key: WrFontInstanceKey,
glyphs: *const GlyphInstance,
@ -1400,8 +1384,7 @@ pub extern "C" fn wr_dp_push_text(state: &mut WrState,
let glyph_slice = make_slice(glyphs, glyph_count as usize);
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
state.frame_builder
.dl_builder
.push_text(&prim_info,
@ -1415,12 +1398,10 @@ pub extern "C" fn wr_dp_push_text(state: &mut WrState,
pub extern "C" fn wr_dp_push_text_shadow(state: &mut WrState,
bounds: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
shadow: TextShadow) {
assert!(unsafe { is_in_main_thread() });
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(bounds, clip.into());
state.frame_builder.dl_builder.push_text_shadow(&prim_info, shadow.into());
}
@ -1434,7 +1415,6 @@ pub extern "C" fn wr_dp_pop_text_shadow(state: &mut WrState) {
#[no_mangle]
pub extern "C" fn wr_dp_push_line(state: &mut WrState,
clip: LayoutRect,
is_backface_visible: bool,
baseline: f32,
start: f32,
end: f32,
@ -1444,8 +1424,7 @@ pub extern "C" fn wr_dp_push_line(state: &mut WrState,
style: LineStyle) {
assert!(unsafe { is_in_main_thread() });
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(LayoutRect::zero(), clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(LayoutRect::zero(), clip.into());
state.frame_builder
.dl_builder
.push_line(&prim_info,
@ -1463,7 +1442,6 @@ pub extern "C" fn wr_dp_push_line(state: &mut WrState,
pub extern "C" fn wr_dp_push_border(state: &mut WrState,
rect: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
widths: BorderWidths,
top: BorderSide,
right: BorderSide,
@ -1479,8 +1457,7 @@ pub extern "C" fn wr_dp_push_border(state: &mut WrState,
bottom: bottom.into(),
radius: radius.into(),
});
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
state.frame_builder
.dl_builder
.push_border(&prim_info,
@ -1492,7 +1469,6 @@ pub extern "C" fn wr_dp_push_border(state: &mut WrState,
pub extern "C" fn wr_dp_push_border_image(state: &mut WrState,
rect: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
widths: BorderWidths,
image: WrImageKey,
patch: NinePatchDescriptor,
@ -1509,8 +1485,7 @@ pub extern "C" fn wr_dp_push_border_image(state: &mut WrState,
repeat_horizontal: repeat_horizontal.into(),
repeat_vertical: repeat_vertical.into(),
});
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
state.frame_builder
.dl_builder
.push_border(&prim_info,
@ -1522,7 +1497,6 @@ pub extern "C" fn wr_dp_push_border_image(state: &mut WrState,
pub extern "C" fn wr_dp_push_border_gradient(state: &mut WrState,
rect: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
widths: BorderWidths,
start_point: LayoutPoint,
end_point: LayoutPoint,
@ -1545,8 +1519,7 @@ pub extern "C" fn wr_dp_push_border_gradient(state: &mut WrState,
extend_mode.into()),
outset: outset.into(),
});
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
state.frame_builder
.dl_builder
.push_border(&prim_info,
@ -1558,7 +1531,6 @@ pub extern "C" fn wr_dp_push_border_gradient(state: &mut WrState,
pub extern "C" fn wr_dp_push_border_radial_gradient(state: &mut WrState,
rect: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
widths: BorderWidths,
center: LayoutPoint,
radius: LayoutSize,
@ -1582,8 +1554,7 @@ pub extern "C" fn wr_dp_push_border_radial_gradient(state: &mut WrState,
extend_mode.into()),
outset: outset.into(),
});
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
state.frame_builder
.dl_builder
.push_border(&prim_info,
@ -1595,7 +1566,6 @@ pub extern "C" fn wr_dp_push_border_radial_gradient(state: &mut WrState,
pub extern "C" fn wr_dp_push_linear_gradient(state: &mut WrState,
rect: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
start_point: LayoutPoint,
end_point: LayoutPoint,
stops: *const GradientStop,
@ -1614,8 +1584,7 @@ pub extern "C" fn wr_dp_push_linear_gradient(state: &mut WrState,
end_point.into(),
stops_vector,
extend_mode.into());
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
state.frame_builder
.dl_builder
.push_gradient(&prim_info,
@ -1628,7 +1597,6 @@ pub extern "C" fn wr_dp_push_linear_gradient(state: &mut WrState,
pub extern "C" fn wr_dp_push_radial_gradient(state: &mut WrState,
rect: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
center: LayoutPoint,
radius: LayoutSize,
stops: *const GradientStop,
@ -1647,8 +1615,7 @@ pub extern "C" fn wr_dp_push_radial_gradient(state: &mut WrState,
radius.into(),
stops_vector,
extend_mode.into());
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
state.frame_builder
.dl_builder
.push_radial_gradient(&prim_info,
@ -1661,7 +1628,6 @@ pub extern "C" fn wr_dp_push_radial_gradient(state: &mut WrState,
pub extern "C" fn wr_dp_push_box_shadow(state: &mut WrState,
rect: LayoutRect,
clip: LayoutRect,
is_backface_visible: bool,
box_bounds: LayoutRect,
offset: LayoutVector2D,
color: ColorF,
@ -1671,8 +1637,7 @@ pub extern "C" fn wr_dp_push_box_shadow(state: &mut WrState,
clip_mode: BoxShadowClipMode) {
assert!(unsafe { is_in_main_thread() });
let mut prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
prim_info.is_backface_visible = is_backface_visible;
let prim_info = LayoutPrimitiveInfo::with_clip_rect(rect, clip.into());
state.frame_builder
.dl_builder
.push_box_shadow(&prim_info,

Просмотреть файл

@ -886,7 +886,6 @@ WR_INLINE
void wr_dp_push_border(WrState *aState,
LayoutRect aRect,
LayoutRect aClip,
bool aIsBackfaceVisible,
BorderWidths aWidths,
BorderSide aTop,
BorderSide aRight,
@ -899,7 +898,6 @@ WR_INLINE
void wr_dp_push_border_gradient(WrState *aState,
LayoutRect aRect,
LayoutRect aClip,
bool aIsBackfaceVisible,
BorderWidths aWidths,
LayoutPoint aStartPoint,
LayoutPoint aEndPoint,
@ -913,7 +911,6 @@ WR_INLINE
void wr_dp_push_border_image(WrState *aState,
LayoutRect aRect,
LayoutRect aClip,
bool aIsBackfaceVisible,
BorderWidths aWidths,
WrImageKey aImage,
NinePatchDescriptor aPatch,
@ -926,7 +923,6 @@ WR_INLINE
void wr_dp_push_border_radial_gradient(WrState *aState,
LayoutRect aRect,
LayoutRect aClip,
bool aIsBackfaceVisible,
BorderWidths aWidths,
LayoutPoint aCenter,
LayoutSize aRadius,
@ -940,7 +936,6 @@ WR_INLINE
void wr_dp_push_box_shadow(WrState *aState,
LayoutRect aRect,
LayoutRect aClip,
bool aIsBackfaceVisible,
LayoutRect aBoxBounds,
LayoutVector2D aOffset,
ColorF aColor,
@ -970,7 +965,6 @@ WR_FUNC;
WR_INLINE
void wr_dp_push_iframe(WrState *aState,
LayoutRect aRect,
bool aIsBackfaceVisible,
WrPipelineId aPipelineId)
WR_FUNC;
@ -978,7 +972,6 @@ WR_INLINE
void wr_dp_push_image(WrState *aState,
LayoutRect aBounds,
LayoutRect aClip,
bool aIsBackfaceVisible,
LayoutSize aStretchSize,
LayoutSize aTileSpacing,
ImageRendering aImageRendering,
@ -988,7 +981,6 @@ WR_FUNC;
WR_INLINE
void wr_dp_push_line(WrState *aState,
LayoutRect aClip,
bool aIsBackfaceVisible,
float aBaseline,
float aStart,
float aEnd,
@ -1002,7 +994,6 @@ WR_INLINE
void wr_dp_push_linear_gradient(WrState *aState,
LayoutRect aRect,
LayoutRect aClip,
bool aIsBackfaceVisible,
LayoutPoint aStartPoint,
LayoutPoint aEndPoint,
const GradientStop *aStops,
@ -1016,7 +1007,6 @@ WR_INLINE
void wr_dp_push_radial_gradient(WrState *aState,
LayoutRect aRect,
LayoutRect aClip,
bool aIsBackfaceVisible,
LayoutPoint aCenter,
LayoutSize aRadius,
const GradientStop *aStops,
@ -1030,7 +1020,6 @@ WR_INLINE
void wr_dp_push_rect(WrState *aState,
LayoutRect aRect,
LayoutRect aClip,
bool aIsBackfaceVisible,
ColorF aColor)
WR_FUNC;
@ -1049,15 +1038,13 @@ void wr_dp_push_stacking_context(WrState *aState,
const LayoutTransform *aPerspective,
MixBlendMode aMixBlendMode,
const WrFilterOp *aFilters,
size_t aFilterCount,
bool aIsBackfaceVisible)
size_t aFilterCount)
WR_FUNC;
WR_INLINE
void wr_dp_push_text(WrState *aState,
LayoutRect aBounds,
LayoutRect aClip,
bool aIsBackfaceVisible,
ColorF aColor,
WrFontInstanceKey aFontKey,
const GlyphInstance *aGlyphs,
@ -1069,7 +1056,6 @@ WR_INLINE
void wr_dp_push_text_shadow(WrState *aState,
LayoutRect aBounds,
LayoutRect aClip,
bool aIsBackfaceVisible,
TextShadow aShadow)
WR_FUNC;
@ -1078,7 +1064,6 @@ WR_INLINE
void wr_dp_push_yuv_NV12_image(WrState *aState,
LayoutRect aBounds,
LayoutRect aClip,
bool aIsBackfaceVisible,
WrImageKey aImageKey0,
WrImageKey aImageKey1,
WrYuvColorSpace aColorSpace,
@ -1090,7 +1075,6 @@ WR_INLINE
void wr_dp_push_yuv_interleaved_image(WrState *aState,
LayoutRect aBounds,
LayoutRect aClip,
bool aIsBackfaceVisible,
WrImageKey aImageKey0,
WrYuvColorSpace aColorSpace,
ImageRendering aImageRendering)
@ -1101,7 +1085,6 @@ WR_INLINE
void wr_dp_push_yuv_planar_image(WrState *aState,
LayoutRect aBounds,
LayoutRect aClip,
bool aIsBackfaceVisible,
WrImageKey aImageKey0,
WrImageKey aImageKey1,
WrImageKey aImageKey2,