зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1688983 - Rename shared member in WebRender shaders r=gw
just a rename Differential Revision: https://phabricator.services.mozilla.com/D103103
This commit is contained in:
Родитель
0367ee057d
Коммит
291f86a68e
|
@ -24,14 +24,14 @@ PER_INSTANCE in ivec2 aStretchMode;
|
|||
PER_INSTANCE in vec4 aClipDestRect;
|
||||
|
||||
struct ClipMaskInstanceBoxShadow {
|
||||
ClipMaskInstanceCommon shared;
|
||||
ClipMaskInstanceCommon base;
|
||||
ivec2 resource_address;
|
||||
};
|
||||
|
||||
ClipMaskInstanceBoxShadow fetch_clip_item() {
|
||||
ClipMaskInstanceBoxShadow cmi;
|
||||
|
||||
cmi.shared = fetch_clip_item_common();
|
||||
cmi.base = fetch_clip_item_common();
|
||||
cmi.resource_address = aClipDataResourceAddress;
|
||||
|
||||
return cmi;
|
||||
|
@ -58,8 +58,8 @@ BoxShadowData fetch_data() {
|
|||
|
||||
void main(void) {
|
||||
ClipMaskInstanceBoxShadow cmi = fetch_clip_item();
|
||||
Transform clip_transform = fetch_transform(cmi.shared.clip_transform_id);
|
||||
Transform prim_transform = fetch_transform(cmi.shared.prim_transform_id);
|
||||
Transform clip_transform = fetch_transform(cmi.base.clip_transform_id);
|
||||
Transform prim_transform = fetch_transform(cmi.base.prim_transform_id);
|
||||
BoxShadowData bs_data = fetch_data();
|
||||
ImageResource res = fetch_image_resource_direct(cmi.resource_address);
|
||||
|
||||
|
@ -69,10 +69,10 @@ void main(void) {
|
|||
dest_rect,
|
||||
prim_transform,
|
||||
clip_transform,
|
||||
cmi.shared.sub_rect,
|
||||
cmi.shared.task_origin,
|
||||
cmi.shared.screen_origin,
|
||||
cmi.shared.device_pixel_scale
|
||||
cmi.base.sub_rect,
|
||||
cmi.base.task_origin,
|
||||
cmi.base.screen_origin,
|
||||
cmi.base.device_pixel_scale
|
||||
);
|
||||
vLayer = res.layer;
|
||||
vClipMode = float(bs_data.clip_mode);
|
||||
|
|
|
@ -17,7 +17,7 @@ PER_INSTANCE in ivec2 aClipDataResourceAddress;
|
|||
PER_INSTANCE in vec4 aClipLocalRect;
|
||||
|
||||
struct ClipMaskInstanceImage {
|
||||
ClipMaskInstanceCommon shared;
|
||||
ClipMaskInstanceCommon base;
|
||||
RectWithSize tile_rect;
|
||||
ivec2 resource_address;
|
||||
RectWithSize local_rect;
|
||||
|
@ -26,7 +26,7 @@ struct ClipMaskInstanceImage {
|
|||
ClipMaskInstanceImage fetch_clip_item() {
|
||||
ClipMaskInstanceImage cmi;
|
||||
|
||||
cmi.shared = fetch_clip_item_common();
|
||||
cmi.base = fetch_clip_item_common();
|
||||
|
||||
cmi.tile_rect = RectWithSize(aClipTileRect.xy, aClipTileRect.zw);
|
||||
cmi.resource_address = aClipDataResourceAddress;
|
||||
|
@ -37,18 +37,18 @@ ClipMaskInstanceImage fetch_clip_item() {
|
|||
|
||||
void main(void) {
|
||||
ClipMaskInstanceImage cmi = fetch_clip_item();
|
||||
Transform clip_transform = fetch_transform(cmi.shared.clip_transform_id);
|
||||
Transform prim_transform = fetch_transform(cmi.shared.prim_transform_id);
|
||||
Transform clip_transform = fetch_transform(cmi.base.clip_transform_id);
|
||||
Transform prim_transform = fetch_transform(cmi.base.prim_transform_id);
|
||||
ImageResource res = fetch_image_resource_direct(cmi.resource_address);
|
||||
|
||||
ClipVertexInfo vi = write_clip_tile_vertex(
|
||||
cmi.local_rect,
|
||||
prim_transform,
|
||||
clip_transform,
|
||||
cmi.shared.sub_rect,
|
||||
cmi.shared.task_origin,
|
||||
cmi.shared.screen_origin,
|
||||
cmi.shared.device_pixel_scale
|
||||
cmi.base.sub_rect,
|
||||
cmi.base.task_origin,
|
||||
cmi.base.screen_origin,
|
||||
cmi.base.device_pixel_scale
|
||||
);
|
||||
vLocalPos = vi.local_pos;
|
||||
vClipMaskImageUv = (vi.local_pos.xy - cmi.tile_rect.p0 * vi.local_pos.w) / cmi.tile_rect.size;
|
||||
|
|
|
@ -31,14 +31,14 @@ PER_INSTANCE in vec4 aClipRect_BR;
|
|||
PER_INSTANCE in vec4 aClipRadii_BR;
|
||||
|
||||
struct ClipMaskInstanceRect {
|
||||
ClipMaskInstanceCommon shared;
|
||||
ClipMaskInstanceCommon base;
|
||||
vec2 local_pos;
|
||||
};
|
||||
|
||||
ClipMaskInstanceRect fetch_clip_item() {
|
||||
ClipMaskInstanceRect cmi;
|
||||
|
||||
cmi.shared = fetch_clip_item_common();
|
||||
cmi.base = fetch_clip_item_common();
|
||||
cmi.local_pos = aClipLocalPos;
|
||||
|
||||
return cmi;
|
||||
|
@ -76,8 +76,8 @@ ClipData fetch_clip() {
|
|||
|
||||
void main(void) {
|
||||
ClipMaskInstanceRect cmi = fetch_clip_item();
|
||||
Transform clip_transform = fetch_transform(cmi.shared.clip_transform_id);
|
||||
Transform prim_transform = fetch_transform(cmi.shared.prim_transform_id);
|
||||
Transform clip_transform = fetch_transform(cmi.base.clip_transform_id);
|
||||
Transform prim_transform = fetch_transform(cmi.base.prim_transform_id);
|
||||
ClipData clip = fetch_clip();
|
||||
|
||||
RectWithSize local_rect = clip.rect.rect;
|
||||
|
@ -87,10 +87,10 @@ void main(void) {
|
|||
local_rect,
|
||||
prim_transform,
|
||||
clip_transform,
|
||||
cmi.shared.sub_rect,
|
||||
cmi.shared.task_origin,
|
||||
cmi.shared.screen_origin,
|
||||
cmi.shared.device_pixel_scale
|
||||
cmi.base.sub_rect,
|
||||
cmi.base.task_origin,
|
||||
cmi.base.screen_origin,
|
||||
cmi.base.device_pixel_scale
|
||||
);
|
||||
|
||||
vClipMode = clip.rect.mode;
|
||||
|
|
Загрузка…
Ссылка в новой задаче