本文整理汇总了C++中FloatPoint3D::z方法的典型用法代码示例。如果您正苦于以下问题:C++ FloatPoint3D::z方法的具体用法?C++ FloatPoint3D::z怎么用?C++ FloatPoint3D::z使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FloatPoint3D
的用法示例。
在下文中一共展示了FloatPoint3D::z方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: setAnchorPoint
void PlatformCALayerWin::setAnchorPoint(const FloatPoint3D& value)
{
CACFLayerSetAnchorPoint(m_layer.get(), CGPointMake(value.x(), value.y()));
CACFLayerSetAnchorPointZ(m_layer.get(), value.z());
setNeedsCommit();
}
示例2: printLayer
static void printLayer(StringBuilder& builder, const PlatformCALayer* layer, int indent)
{
FloatPoint3D layerPosition = layer->position();
FloatPoint3D layerAnchorPoint = layer->anchorPoint();
FloatRect layerBounds = layer->bounds();
builder.append('\n');
printIndent(builder, indent);
char* layerTypeName = nullptr;
switch (layer->layerType()) {
case PlatformCALayer::LayerTypeLayer: layerTypeName = "layer"; break;
case PlatformCALayer::LayerTypeWebLayer: layerTypeName = "web-layer"; break;
case PlatformCALayer::LayerTypeSimpleLayer: layerTypeName = "simple-layer"; break;
case PlatformCALayer::LayerTypeTransformLayer: layerTypeName = "transform-layer"; break;
case PlatformCALayer::LayerTypeWebTiledLayer: layerTypeName = "web-tiled-layer"; break;
case PlatformCALayer::LayerTypeTiledBackingLayer: layerTypeName = "tiled-backing-layer"; break;
case PlatformCALayer::LayerTypePageTiledBackingLayer: layerTypeName = "page-tiled-backing-layer"; break;
case PlatformCALayer::LayerTypeTiledBackingTileLayer: layerTypeName = "tiled-backing-tile-layer"; break;
case PlatformCALayer::LayerTypeRootLayer: layerTypeName = "root-layer"; break;
case PlatformCALayer::LayerTypeAVPlayerLayer: layerTypeName = "avplayer-layer"; break;
case PlatformCALayer::LayerTypeWebGLLayer: layerTypeName = "webgl-layer"; break;
case PlatformCALayer::LayerTypeBackdropLayer: layerTypeName = "backdrop-layer"; break;
case PlatformCALayer::LayerTypeShapeLayer: layerTypeName = "shape-layer"; break;
case PlatformCALayer::LayerTypeLightSystemBackdropLayer: layerTypeName = "light-system-backdrop-layer"; break;
case PlatformCALayer::LayerTypeDarkSystemBackdropLayer: layerTypeName = "dark-system-backdrop-layer"; break;
case PlatformCALayer::LayerTypeScrollingLayer: layerTypeName = "scrolling-layer"; break;
case PlatformCALayer::LayerTypeCustom: layerTypeName = "custom-layer"; break;
}
builder.append("(");
builder.append(layerTypeName);
builder.append(" [");
builder.appendNumber(layerPosition.x());
builder.append(' ');
builder.appendNumber(layerPosition.y());
builder.append(' ');
builder.appendNumber(layerPosition.z());
builder.append("] [");
builder.appendNumber(layerBounds.x());
builder.append(' ');
builder.appendNumber(layerBounds.y());
builder.append(' ');
builder.appendNumber(layerBounds.width());
builder.append(' ');
builder.appendNumber(layerBounds.height());
builder.append("] [");
builder.appendNumber(layerAnchorPoint.x());
builder.append(' ');
builder.appendNumber(layerAnchorPoint.y());
builder.append(' ');
builder.appendNumber(layerAnchorPoint.z());
builder.append("] superlayer=");
builder.appendNumber(reinterpret_cast<unsigned long long>(layer->superlayer()));
// Print name if needed
String layerName = CACFLayerGetName(layer->platformLayer());
if (!layerName.isEmpty()) {
builder.append('\n');
printIndent(builder, indent + 1);
builder.append("(name \"");
builder.append(layerName);
builder.append("\")");
}
// Print borderWidth if needed
if (CGFloat borderWidth = CACFLayerGetBorderWidth(layer->platformLayer())) {
builder.append('\n');
printIndent(builder, indent + 1);
builder.append("(borderWidth ");
builder.appendNumber(borderWidth);
builder.append(')');
}
// Print backgroundColor if needed
printColor(builder, indent + 1, "backgroundColor", CACFLayerGetBackgroundColor(layer->platformLayer()));
// Print borderColor if needed
printColor(builder, indent + 1, "borderColor", CACFLayerGetBorderColor(layer->platformLayer()));
// Print masksToBounds if needed
if (bool layerMasksToBounds = layer->masksToBounds()) {
builder.append('\n');
printIndent(builder, indent + 1);
builder.append("(masksToBounds true)");
}
if (bool geometryFlipped = layer->geometryFlipped()) {
builder.append('\n');
printIndent(builder, indent + 1);
builder.append("(geometryFlipped true)");
}
// Print opacity if needed
float layerOpacity = layer->opacity();
if (layerOpacity != 1) {
builder.append('\n');
printIndent(builder, indent + 1);
builder.append("(opacity ");
builder.appendNumber(layerOpacity);
builder.append(')');
//.........这里部分代码省略.........