|
|
|
|
|
|
} |
|
|
|
|
|
|
|
if (clipBounds.isEmpty) { |
|
|
|
this._drawPathDrawMeshQuit(mesh); |
|
|
|
this._drawPathDrawMeshQuit(mesh, textMesh); |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
this._drawPathDrawMeshQuit(mesh); |
|
|
|
this._drawPathDrawMeshQuit(mesh, textMesh); |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
if (maskBounds.isEmpty) { |
|
|
|
this._drawPathDrawMeshQuit(mesh); |
|
|
|
this._drawPathDrawMeshQuit(mesh, textMesh); |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
else { |
|
|
|
uiPaint paintWithWhite = new uiPaint(p); |
|
|
|
paintWithWhite.color = uiColor.white; |
|
|
|
if (EmojiUtils.image == null) return; |
|
|
|
layer.draws.Add(CanvasShader.tex(layer, paintWithWhite, textMesh.resolveMesh(), EmojiUtils.image)); |
|
|
|
if (EmojiUtils.image == null) { |
|
|
|
ObjectPool<TextBlobMesh>.release(textMesh); |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|
var raw_mesh = textMesh.resolveMesh(); |
|
|
|
var meshmesh = raw_mesh.duplicate(); |
|
|
|
ObjectPool<TextBlobMesh>.release(textMesh); |
|
|
|
layer.draws.Add(CanvasShader.tex(layer, paintWithWhite, meshmesh, EmojiUtils.image)); |
|
|
|
void _drawPathDrawMeshQuit(uiMeshMesh mesh) { |
|
|
|
void _drawPathDrawMeshQuit(uiMeshMesh mesh, TextBlobMesh textMesh) { |
|
|
|
ObjectPool<TextBlobMesh>.release(textMesh); |
|
|
|
} |
|
|
|
|
|
|
|
void _drawPath(uiPath path, uiPaint paint) { |
|
|
|