does android sdk give any convenience methods for converting Shape to Path?
the Canvas class does not take Shape as a parameter for any of its methods. There is no drawShape or clipShape, etc... So, I need to use Path instead. Does android sdk expose any way to convert Shape to Path or Path to shape? I haven't been 开发者_StackOverflow社区able to find relationship any between the 2 classes...?
Thank you
Shape is just an abstraction over the Canvas. It may or may not use a Path internally. You cannot convert a Shape to a Path directly, but all Shapes can be implemented using Path. You can however create a Shape from a Path using the PathShape class.
精彩评论