# C1.Util.DX.ColorF.LerpRef

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_Util_DX_ColorF_LerpRef_" data-uid="C1.Util.DX.ColorF.LerpRef*">LerpRef Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_Util_DX_ColorF_LerpRef_" data-uid="C1.Util.DX.ColorF.LerpRef*"></a>
<h4 id="C1_Util_DX_ColorF_LerpRef_C1_Util_DX_ColorF__C1_Util_DX_ColorF__C1_Util_DX_ColorF__System_Single_" data-uid="C1.Util.DX.ColorF.LerpRef(C1.Util.DX.ColorF@,C1.Util.DX.ColorF@,C1.Util.DX.ColorF@,System.Single)">LerpRef(out ColorF, ref ColorF, ref ColorF, float)</h4>
<div class="markdown level1 summary"><p>Performs a linear interpolation between two colors.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static void LerpRef(out ColorF result, ref ColorF start, ref ColorF end, float amount)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Sub LerpRef(ByRef result As ColorF, ByRef start As ColorF, ByRef [end] As ColorF, amount As Single)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="C1.Util.DX.ColorF.html">ColorF</a></td>
      <td><span class="parametername">result</span></td>
      <td><p>The linear interpolation of the two colors.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.Util.DX.ColorF.html">ColorF</a></td>
      <td><span class="parametername">start</span></td>
      <td><p>Start color.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.Util.DX.ColorF.html">ColorF</a></td>
      <td><span class="parametername">end</span></td>
      <td><p>End color.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.single">float</a></td>
      <td><span class="parametername">amount</span></td>
      <td><p>Value between 0 and 1 indicating the weight of <code class="paramref">end</code>.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_Util_DX_ColorF_LerpRef_C1_Util_DX_ColorF__C1_Util_DX_ColorF__C1_Util_DX_ColorF__System_Single__remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>This method performs the linear interpolation based on the following formula.</p>
<pre><code class="lang-csharp">start + (end - start) * amount</code></pre>
<p>Passing <code class="paramref">amount</code> a value of 0 will cause <code class="paramref">start</code> to be returned; a value of 1 will cause <code class="paramref">end</code> to be returned.</p>
</div>
</div>
