收藏
回答

iOS平台,Canvas画布颜色很暗

框架类型 问题类型 API/组件名称 终端类型 微信版本 基础库版本
小程序 Bug Canvas 客户端 6.7.3 2.4.0

- 当前 Bug 的表现(可附上截图)



- 预期表现

Canvas画布绘制出来的图形,看起来像是被覆盖在mask之下了,颜色太暗了

- 复现路径





- 提供一个最简复现 Demo

<map class='map'></map>

<cover-view class='mask'></cover-view>

<canvas class="progress_bg" canvas-id="progress_bg"> </canvas>

 <canvas class="progress_fg" canvas-id="progress_fg"> </canvas>


.mask {

 background: rgba(0, 0, 0, 0.4);

 width: 100%;

 height: 100%;

 z-index: 6;

 position: fixed;

}

.progress_bg {

 /* background: floralwhite; */

 width: 100%;

 height: 40%;

 position: fixed;

 z-index: 9;

}


.progress_fg {

 width: 100%;

 height: 40%;

 position: fixed;

 z-index: 10;

}

.map {

 width: 100%;

 position: fixed;

 z-index: 0;

 height: 100%;

}
















回答关注问题邀请回答
收藏

1 个回答

登录 后发表内容