SpriteKit 中 "nonuniformly scaled texture" 是什么意思?
What is the meaning of "nonuniformly scaled texture" in SpriteKit?
在 SKCropNode
class 参考资料中,给出了一些指定掩码的示例。
他们在这里:
This means a crop node can use simple masks derived from a piece of artwork, but it can also use more sophisticated masks. For example, here are some ways you might specify a mask:
An untextured sprite that limits content to a rectangular portion of the scene.
A textured sprite is a precise per-pixel mask. But consider also the benefits of a nonuniformly scaled texture. You could use a nonuniformly scaled texture to create a mask for a resizable user-interface element (such as a health bar) and then fill the masked area with dynamic content.
A collection of nodes can dynamically generate a complex mask that changes each time the frame is rendered.
第二个例子介绍非均匀缩放纹理:这是什么意思?
这并不能帮助我理解第二个例子!
非均匀缩放纹理是应用于具有 xScale
!= yScale
.
的精灵的纹理
在 SKCropNode
class 参考资料中,给出了一些指定掩码的示例。
他们在这里:
This means a crop node can use simple masks derived from a piece of artwork, but it can also use more sophisticated masks. For example, here are some ways you might specify a mask:
An untextured sprite that limits content to a rectangular portion of the scene.
A textured sprite is a precise per-pixel mask. But consider also the benefits of a nonuniformly scaled texture. You could use a nonuniformly scaled texture to create a mask for a resizable user-interface element (such as a health bar) and then fill the masked area with dynamic content.
A collection of nodes can dynamically generate a complex mask that changes each time the frame is rendered.
第二个例子介绍非均匀缩放纹理:这是什么意思?
这并不能帮助我理解第二个例子!
非均匀缩放纹理是应用于具有 xScale
!= yScale
.