<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>2D 渲染 on Chen's Notes</title><link>https://lucky-chen.github.io/zh/docs/client_front_end/2d_rendering/</link><description>Recent content in 2D 渲染 on Chen's Notes</description><generator>Hugo</generator><language>zh-CN</language><lastBuildDate>Sun, 15 Mar 2020 00:00:00 +0000</lastBuildDate><atom:link href="https://lucky-chen.github.io/zh/docs/client_front_end/2d_rendering/index.xml" rel="self" type="application/rss+xml"/><item><title>Flutter渲染流程(二)-GPU线程工作</title><link>https://lucky-chen.github.io/zh/docs/client_front_end/2d_rendering/flutter-render-pipline-1/</link><pubDate>Sun, 15 Mar 2020 00:00:00 +0000</pubDate><guid>https://lucky-chen.github.io/zh/docs/client_front_end/2d_rendering/flutter-render-pipline-1/</guid><description>&lt;h1 id="概览"&gt;概览&lt;a class="anchor" href="#%e6%a6%82%e8%a7%88" aria-label="Link"&gt;&lt;/a&gt;&lt;/h1&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;将上一节中UI线程生成了&lt;code&gt;laytertree&lt;/code&gt;，交给GPU线程的&lt;code&gt;rasterizer&lt;/code&gt;&lt;/li&gt;&#10;&lt;li&gt;调用&lt;code&gt;LayerTree&lt;/code&gt;的&lt;code&gt;Preroll&lt;/code&gt;、&lt;code&gt;Paint&lt;/code&gt;2个方法，完成所有&lt;code&gt;Layer&lt;/code&gt;的绘制前准备以及绘制操作&lt;/li&gt;&#10;&lt;li&gt;将纹理化的结果，上屏&lt;/li&gt;&#10;&lt;/ul&gt;</description></item><item><title>Flutter渲染流程(一)-UI线程工作</title><link>https://lucky-chen.github.io/zh/docs/client_front_end/2d_rendering/flutter-render-pipline/</link><pubDate>Sun, 08 Mar 2020 00:00:00 +0000</pubDate><guid>https://lucky-chen.github.io/zh/docs/client_front_end/2d_rendering/flutter-render-pipline/</guid><description>&lt;h1 id="概览"&gt;概览&lt;a class="anchor" href="#%e6%a6%82%e8%a7%88" aria-label="Link"&gt;&lt;/a&gt;&lt;/h1&gt;&#10;&lt;p&gt;这一部分的主要工作是&lt;code&gt;WidgetTree&lt;/code&gt;转化成&lt;code&gt;LayerTree&lt;/code&gt;，主要分为下面几个阶段&lt;/p&gt;&#10;&lt;p&gt;&lt;img src="https://user-gold-cdn.xitu.io/2018/8/8/16517c804ab5e799?imageView2/0/w/1280/h/960/format/webp/ignore-error/1" alt="" /&gt;&lt;/p&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;Animate: 首先执行动画，这个过程可能会改变状态state&lt;/li&gt;&#10;&lt;li&gt;Build: 重新build脏节点的widget（状态改变）&lt;/li&gt;&#10;&lt;li&gt;Layout: 对脏节点进行重新的layout&lt;/li&gt;&#10;&lt;li&gt;Paint: 脏节点重新绘制&lt;/li&gt;&#10;&lt;li&gt;更新layertree，提交给gpu线程&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;p&gt;流程还是比较清晰、容易理解的&lt;/p&gt;</description></item></channel></rss>