WIP: Revert "[drape] Render semi-transparent areas after opaque areas and lines " #8272

Closed
vng wants to merge 3 commits from revert-7969-pastk-drape-transparent-areas into master
7 changed files with 5 additions and 12 deletions

File diff suppressed because one or more lines are too long

Binary file not shown.

View file

@ -56,8 +56,7 @@ void AreaShape::DrawArea(ref_ptr<dp::GraphicsContext> context, ref_ptr<dp::Batch
for (m2::PointD const & vertex : m_vertexes)
vertexes.emplace_back(ToShapeVertex3(vertex), uv);
auto const areaProgram = m_params.m_color.GetAlpha() == 255 ? gpu::Program::Area : gpu::Program::TransparentArea;
auto state = CreateRenderState(areaProgram, DepthLayer::GeometryLayer);
auto state = CreateRenderState(gpu::Program::Area, DepthLayer::GeometryLayer);
state.SetDepthTestEnabled(m_params.m_depthTestEnabled);
state.SetColorTexture(texture);

View file

@ -12,11 +12,10 @@ AreaOutline area.vsh.glsl solid_color.fsh.glsl
Area3d area3d.vsh.glsl texturing3d.fsh.glsl
Area3dOutline area3d_outline.vsh.glsl solid_color.fsh.glsl
Line line.vsh.glsl line.fsh.glsl
CapJoin circle.vsh.glsl circle.fsh.glsl
TransitCircle transit_circle.vsh.glsl transit_circle.fsh.glsl
DashedLine dashed_line.vsh.glsl dashed_line.fsh.glsl
PathSymbol path_symbol.vsh.glsl texturing.fsh.glsl
TransparentArea area.vsh.glsl solid_color.fsh.glsl
CapJoin circle.vsh.glsl circle.fsh.glsl
HatchingArea hatching_area.vsh.glsl hatching_area.fsh.glsl
TexturingGui texturing_gui.vsh.glsl texturing.fsh.glsl
Ruler ruler.vsh.glsl texturing.fsh.glsl

View file

@ -61,11 +61,10 @@ std::array<ProgramInfo, static_cast<size_t>(Program::ProgramsCount)> const kMeta
ProgramInfo("vsArea3d", "fsArea3d", {{0, 2}}), // Area3d
ProgramInfo("vsArea3dOutline", "fsArea", {{0, 1}}), // Area3dOutline
ProgramInfo("vsLine", "fsLine", {{0, 2}}), // Line
ProgramInfo("vsCapJoin", "fsCapJoin", {{0, 2}}), // CapJoin
ProgramInfo("vsTransitCircle", "fsTransitCircle", {{0, 2}}), // TransitCircle
ProgramInfo("vsDashedLine", "fsDashedLine", {{0, 3}}), // DashedLine
ProgramInfo("vsPathSymbol", "fsPathSymbol", {{0, 2}}), // PathSymbol
ProgramInfo("vsArea", "fsArea", {{0, 1}}), // TransparentArea
ProgramInfo("vsCapJoin", "fsCapJoin", {{0, 2}}), // CapJoin
ProgramInfo("vsHatchingArea", "fsHatchingArea", {{0, 2}}), // HatchingArea
ProgramInfo("vsTexturingGui", "fsTexturingGui", {{0, 1}}), // TexturingGui
ProgramInfo("vsRuler", "fsRuler", {{0, 2}}), // Ruler

View file

@ -73,7 +73,6 @@ struct ALIGNMENT MapProgramParams
Program::ColoredSymbol,
Program::ColoredSymbolBillboard,
Program::DashedLine,
Program::TransparentArea,
Program::HatchingArea,
Program::Line,
Program::MaskedTexturing,

View file

@ -7,7 +7,6 @@
namespace gpu
{
// Programs in enum are in the order of rendering priority.
// Each program should have shaders assigned in GL/shader_index.txt and metal_program_pool.mm
enum class Program
{
ColoredSymbol = 0,
@ -24,11 +23,10 @@ enum class Program
Area3d,
Area3dOutline,
Line,
CapJoin,
TransitCircle,
DashedLine,
PathSymbol,
TransparentArea,
CapJoin,
HatchingArea,
TexturingGui,
Ruler,
@ -91,7 +89,6 @@ inline std::string DebugPrint(Program p)
case Program::TransitCircle: return "TransitCircle";
case Program::DashedLine: return "DashedLine";
case Program::PathSymbol: return "PathSymbol";
case Program::TransparentArea: return "TransparentArea";
case Program::HatchingArea: return "HatchingArea";
case Program::TexturingGui: return "TexturingGui";
case Program::Ruler: return "Ruler";