10-Origami中文帮助-Workflow-Performance

Dosen原创

这是我学习quartz composer,Origami,看官方文档翻译下来的,每天一篇,有不准确的地方希望能指出,一起交流进步。转载请与我联系,擅自转载视作侵权。


Performance      性能


Here are some tips for improving the performance of your prototypes.

这里是一些改善你原型的性能的技巧。



Origami for Mac


Inline Values are helpful when you're building your prototypes, but take a lot of processing power that would otherwise be used to speed up Origami and Origami Live. You can toggle Inline Values on and off in the Origami menu. It's best to turn them off if you're recording a video or giving a demo of your prototype. Quickly toggle it on and off with the keyboard shortcut⌘⌥⌃V.

在建立原型的过程中内联值时非常有用的,但是需要耗费很多的处理能力。你可以在Origami菜单中开关内联值。如果你在录视频或演示原型demo,最好是关闭它。用快捷键⌘⌥⌃V快速切换它的开启关闭状态。

Avoid animating certain graphically intensive patches. Some patches, like Disc Blur for example, can produce nice effects but take a lot of computing power. You can get away with changing their inputs occasionally, but you might notice your composition slow down if you animate their inputs, even on fancy new computers.

避免集中使用一些效果生动的动画模块。一些模块, 比如Disc Blur(一种模糊效果)可以制作出漂亮的特效,但是消耗大量的处理能力。你可以偶尔改变它的输入来离开,但是你可以回注意到了,如果你让它们的输入动起来,你的合成会慢下来,即使在新的很棒的电脑上。

If you're not using Origami Live, there are some specific optimizations you can make to your compositions. If you turn off the Render port on Layer Groups that aren't visible, or turn off Enable for layers that aren't visible, you'll stop Quartz Composer from processing those patches, and ones that are linked or contained by them, every frame.

如果你不使用Origami Live,这里还有一些特殊的优化方法可以用在你的原型里。如果你关闭Layer Groups的渲染接口,或者使Layers不可见,你会让Quartz composer停止处理那些模块,它们中关联或包含着一个或多个,而且是每一帧。



Origami Live


Origami Live can run your prototypes at 60 fps by sending images from Quartz Composer on the Mac to the device only when necessary. If the images aren't frequently changing, Origami only needs to send small bits of information over USB every frame, like the positions of layers that are currently moving for example.

当必要时,OrigamiLive可以从Mac的QuartzComposer里以60帧速率发送图片到你的设备上演示你的原型。如果图片不是频繁的改动,Origami只需要通过USB在每一帧发送信息小一点的就可以,就像层的位置正在移动一样。

Make sure the Image outputs of your Layer Groups are directly connected to Layer patches (or the Viewer patch). Passing the image of a Layer Group through another patch (like Gaussian Blur) will make it so every time that image changes - either by changing the blur or by making any change to any layer inside the group - will cause it to send a new image to the device. You can try to fake a blur animation by fading a blurred layer on top of the non-blurred one.

确保你的层组的图片输出是直接连接的层模块(或查看器模块)。传送层组的图片穿过另一个模块(就像高斯模糊)会让它每一帧的图片都有改变,不论是改变模糊或对组中的任何层做任何改变,会导致它发送一个新图到设备上,你可以试着在一个不模糊的上面伪造一个模糊的层,来伪造一个模糊动画。

Avoid using the Enable port on Layers. Each time a layer is enabled, the list of layers gets regenerated on the device which can take some time. Use the Opacity port to hide and show layers instead.

避免使用层上的Enable接口。每当一个层开启可用时,层的列表会需要一些时间在设备上重建。使用透明接口去隐藏或显示的方法替代。

Avoid animating the Color port on Layers. This requires special blending to happen on the device.

避免在层的颜色接口上做动画,这要求在设备上发生特殊的融合。

你可能感兴趣的:(10-Origami中文帮助-Workflow-Performance)