TBitmap是否与FMX中的FloodFill等效? [英] Is there an equivalent to FloodFill in FMX for a TBitmap?

查看:76
本文介绍了TBitmap是否与FMX中的FloodFill等效?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在从VCL转换为FMX。在VCL中,TBitmap的TCanvas中有一个名为FloodFill的函数,该函数允许TBitmap的画布上填充特定的颜色,直到在位图的画布上达到另一特定的颜色为止。

I am converting from VCL to FMX. In VCL, there was a function in a TBitmap's TCanvas called FloodFill, which allowed for a TBitmap's canvas to be flooded with a specific color, until another specific color was reached on the bitmap's canvas.

FMX中是否有与此功能等效的功能?

Is there an equivalent to this function in FMX?

推荐答案

没有 FloodFill 在FireMonkey中等效,但是您可以使用路径( TPathData )可以填充。因此,您可以定义要填充形状的路径,然后
使用 FMX.Graphics.TCanvas.FillPath 进行内部绘画。

There is not a FloodFill function equivalent in FireMonkey, but you can use a path(TPathData) which can be filled. So you could define a path with the shape to fill, and then use the FMX.Graphics.TCanvas.FillPath to do the interior painting.

这篇关于TBitmap是否与FMX中的FloodFill等效?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆