Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Impeller] remove unused shader, format malioc diff #40230

Merged
merged 4 commits into from
Mar 10, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions ci/licenses_golden/licenses_flutter
Original file line number Diff line number Diff line change
Expand Up @@ -1251,7 +1251,6 @@ ORIGIN: ../../../flutter/impeller/entity/shaders/linear_to_srgb_filter.frag + ..
ORIGIN: ../../../flutter/impeller/entity/shaders/linear_to_srgb_filter.vert + ../../../flutter/LICENSE
ORIGIN: ../../../flutter/impeller/entity/shaders/morphology_filter.frag + ../../../flutter/LICENSE
ORIGIN: ../../../flutter/impeller/entity/shaders/morphology_filter.vert + ../../../flutter/LICENSE
ORIGIN: ../../../flutter/impeller/entity/shaders/position.vert + ../../../flutter/LICENSE
ORIGIN: ../../../flutter/impeller/entity/shaders/position_color.vert + ../../../flutter/LICENSE
ORIGIN: ../../../flutter/impeller/entity/shaders/position_uv.vert + ../../../flutter/LICENSE
ORIGIN: ../../../flutter/impeller/entity/shaders/radial_gradient_fill.frag + ../../../flutter/LICENSE
Expand Down Expand Up @@ -3781,7 +3780,6 @@ FILE: ../../../flutter/impeller/entity/shaders/linear_to_srgb_filter.frag
FILE: ../../../flutter/impeller/entity/shaders/linear_to_srgb_filter.vert
FILE: ../../../flutter/impeller/entity/shaders/morphology_filter.frag
FILE: ../../../flutter/impeller/entity/shaders/morphology_filter.vert
FILE: ../../../flutter/impeller/entity/shaders/position.vert
FILE: ../../../flutter/impeller/entity/shaders/position_color.vert
FILE: ../../../flutter/impeller/entity/shaders/position_uv.vert
FILE: ../../../flutter/impeller/entity/shaders/radial_gradient_fill.frag
Expand Down
1 change: 0 additions & 1 deletion impeller/entity/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ impeller_shaders("entity_shaders") {
"shaders/morphology_filter.vert",
"shaders/position_color.vert",
"shaders/position_uv.vert",
"shaders/position.vert",
"shaders/radial_gradient_fill.frag",
"shaders/rrect_blur.vert",
"shaders/rrect_blur.frag",
Expand Down
2 changes: 0 additions & 2 deletions impeller/entity/contents/content_context.cc
Original file line number Diff line number Diff line change
Expand Up @@ -276,8 +276,6 @@ ContentContext::ContentContext(std::shared_ptr<Context> context)
CreateDefaultPipeline<GlyphAtlasSdfPipeline>(*context_);
geometry_color_pipelines_[{}] =
CreateDefaultPipeline<GeometryColorPipeline>(*context_);
geometry_position_pipelines_[{}] =
CreateDefaultPipeline<GeometryPositionPipeline>(*context_);
yuv_to_rgb_filter_pipelines_[{}] =
CreateDefaultPipeline<YUVToRGBFilterPipeline>(*context_);

Expand Down
9 changes: 0 additions & 9 deletions impeller/entity/contents/content_context.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@
#include "impeller/renderer/pipeline.h"
#include "impeller/scene/scene_context.h"

#include "impeller/entity/position.vert.h"
#include "impeller/entity/position_color.vert.h"

#include "impeller/scene/scene_context.h"
Expand Down Expand Up @@ -152,8 +151,6 @@ using GlyphAtlasSdfPipeline =
using ClipPipeline =
RenderPipelineT<SolidFillVertexShader, SolidFillFragmentShader>;

using GeometryPositionPipeline =
RenderPipelineT<PositionVertexShader, VerticesFragmentShader>;
using GeometryColorPipeline =
RenderPipelineT<PositionColorVertexShader, VerticesFragmentShader>;
using YUVToRGBFilterPipeline =
Expand Down Expand Up @@ -427,11 +424,6 @@ class ContentContext {
return GetPipeline(geometry_color_pipelines_, opts);
}

std::shared_ptr<Pipeline<PipelineDescriptor>> GetGeometryPositionPipeline(
ContentContextOptions opts) const {
return GetPipeline(geometry_position_pipelines_, opts);
}

std::shared_ptr<Pipeline<PipelineDescriptor>> GetYUVToRGBFilterPipeline(
ContentContextOptions opts) const {
return GetPipeline(yuv_to_rgb_filter_pipelines_, opts);
Expand Down Expand Up @@ -661,7 +653,6 @@ class ContentContext {
mutable Variants<ClipPipeline> clip_pipelines_;
mutable Variants<GlyphAtlasPipeline> glyph_atlas_pipelines_;
mutable Variants<GlyphAtlasSdfPipeline> glyph_atlas_sdf_pipelines_;
mutable Variants<GeometryPositionPipeline> geometry_position_pipelines_;
mutable Variants<GeometryColorPipeline> geometry_color_pipelines_;
mutable Variants<YUVToRGBFilterPipeline> yuv_to_rgb_filter_pipelines_;
// Advanced blends.
Expand Down
1 change: 0 additions & 1 deletion impeller/entity/contents/vertices_contents.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
#include "impeller/entity/contents/filters/color_filter_contents.h"
#include "impeller/entity/contents/filters/filter_contents.h"
#include "impeller/entity/contents/texture_contents.h"
#include "impeller/entity/position.vert.h"
#include "impeller/entity/position_color.vert.h"
#include "impeller/entity/vertices.frag.h"
#include "impeller/geometry/color.h"
Expand Down
21 changes: 0 additions & 21 deletions impeller/entity/shaders/position.vert

This file was deleted.

7,429 changes: 7,428 additions & 1 deletion impeller/tools/malioc.json

Large diffs are not rendered by default.

4 changes: 3 additions & 1 deletion impeller/tools/malioc_diff.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,8 @@ def read_malioc_file(malioc_tree, json_file):
filename = os.path.relpath(shader['filename'], build_gen_dir)
if filename.startswith('../..'):
filename = filename[6:]
if filename.startswith('../'):
filename = filename[3:]
result['filename'] = filename
result['core'] = shader['hardware']['core']
result['type'] = shader['shader']['type']
Expand Down Expand Up @@ -266,7 +268,7 @@ def main(argv):
if args.update:
# Write the new results to the file given by --before, then exit.
with open(args.before, 'w') as file:
json.dump(after_json, file, sort_keys=True)
json.dump(after_json, file, sort_keys=True, indent=2)
return 0

with open(args.before, 'r') as file:
Expand Down