# C1.Util.DX.Direct2D.Factory1

## Content

<div class="doc-site-dotnet-api-container">



  <h1 id="C1_Util_DX_Direct2D_Factory1" data-uid="C1.Util.DX.Direct2D.Factory1" class="text-break">Factory1 Class
</h1>
  <div class="markdown level0 summary"><p>ID2D1Factory1</p>
</div>
  <div class="markdown level0 conceptual"></div>
  <div class="inheritance">
    <h5>Inheritance</h5>
    <div class="level0"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object">object</a></div>
    <div class="level1"><a class="xref" href="C1.Util.DX.DisposeBase.html">DisposeBase</a></div>
    <div class="level2"><a class="xref" href="C1.Util.DX.CppObject.html">CppObject</a></div>
    <div class="level3"><a class="xref" href="C1.Util.DX.ComObject.html">ComObject</a></div>
    <div class="level4"><a class="xref" href="C1.Util.DX.Direct2D.Factory.html">Factory</a></div>
    <div class="level5"><span class="xref">Factory1</span></div>
      <div class="level6"><a class="xref" href="C1.Util.DX.Direct2D.Factory2.html">Factory2</a></div>
  </div>
  <div class="implements">
    <h5>Implements</h5>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.idisposable">IDisposable</a></div>
    <div><a class="xref" href="C1.Util.DX.IUnknown.html">IUnknown</a></div>
  </div>
  <h6><strong>Namespace</strong>: <a class="xref" href="C1.Util.DX.Direct2D.html">C1.Util.DX.Direct2D</a></h6>
  <h6><strong>Assembly</strong>: C1.WPF.DX.4.6.2.dll</h6>
  <h5 id="C1_Util_DX_Direct2D_Factory1_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">[Guid(&quot;bb12d362-daee-4b9a-aa1d-14ba401cfa1f&quot;)]
public class Factory1 : Factory, IDisposable, IUnknown</code></pre>
  </div>
  <div class="codewrapper">
    <pre><code class="lang-vbnet hljs">&lt;Guid(&quot;bb12d362-daee-4b9a-aa1d-14ba401cfa1f&quot;)&gt;
Public Class Factory1
    Inherits Factory
    Implements IDisposable, IUnknown</code></pre>
  </div>
  <h3 id="constructors">Constructors
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1__ctor_System_IntPtr_" data-uid="C1.Util.DX.Direct2D.Factory1.#ctor(System.IntPtr)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.-ctor.html#C1_Util_DX_Direct2D_Factory1__ctor_System_IntPtr_">Factory1(IntPtr)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.Util.DX.Direct2D.Factory1.html">Factory1</a> class.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="properties">Properties
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_IsSupported" data-uid="C1.Util.DX.Direct2D.Factory1.IsSupported">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.IsSupported.html#C1_Util_DX_Direct2D_Factory1_IsSupported">IsSupported</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a value indicating if Direct2D is supported on this platform.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_RegisteredEffects" data-uid="C1.Util.DX.Direct2D.Factory1.RegisteredEffects">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.RegisteredEffects.html#C1_Util_DX_Direct2D_Factory1_RegisteredEffects">RegisteredEffects</a>
        </td>
        <td class="markdown level1 summary"><p>Get the effects registered</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="methods">Methods
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_Create_C1_Util_DX_Direct2D_FactoryType_" data-uid="C1.Util.DX.Direct2D.Factory1.Create(C1.Util.DX.Direct2D.FactoryType)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.Create.html#C1_Util_DX_Direct2D_Factory1_Create_C1_Util_DX_Direct2D_FactoryType_">Create(FactoryType)</a>
        </td>
        <td class="markdown level1 summary"><p>Default Constructor for a <a class="xref" href="C1.Util.DX.Direct2D.Factory1.html">Factory1</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_CreateDevice_C1_Util_DX_DXGI_Device_" data-uid="C1.Util.DX.Direct2D.Factory1.CreateDevice(C1.Util.DX.DXGI.Device)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.CreateDevice.html#C1_Util_DX_Direct2D_Factory1_CreateDevice_C1_Util_DX_DXGI_Device_">CreateDevice(Device)</a>
        </td>
        <td class="markdown level1 summary"><p>HRESULT ID2D1Factory1::CreateDevice([In] IDXGIDevice* dxgiDevice,[Out, Fast] ID2D1Device** d2dDevice)</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_CreateDrawingStateBlock1_System_Nullable_C1_Util_DX_Direct2D_DrawingStateDescription1__C1_Util_DX_DirectWrite_RenderingParams_" data-uid="C1.Util.DX.Direct2D.Factory1.CreateDrawingStateBlock1(System.Nullable{C1.Util.DX.Direct2D.DrawingStateDescription1},C1.Util.DX.DirectWrite.RenderingParams)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.CreateDrawingStateBlock1.html#C1_Util_DX_Direct2D_Factory1_CreateDrawingStateBlock1_System_Nullable_C1_Util_DX_Direct2D_DrawingStateDescription1__C1_Util_DX_DirectWrite_RenderingParams_">CreateDrawingStateBlock1(DrawingStateDescription1?, RenderingParams)</a>
        </td>
        <td class="markdown level1 summary"><p>HRESULT ID2D1Factory1::CreateDrawingStateBlock([In, Optional] const D2D1_DRAWING_STATE_DESCRIPTION1* drawingStateDescription,[In, Optional] IDWriteRenderingParams* textRenderingParams,[Out, Fast] ID2D1DrawingStateBlock1** drawingStateBlock)</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_CreateGdiMetafile_System_IO_Stream_" data-uid="C1.Util.DX.Direct2D.Factory1.CreateGdiMetafile(System.IO.Stream)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.CreateGdiMetafile.html#C1_Util_DX_Direct2D_Factory1_CreateGdiMetafile_System_IO_Stream_">CreateGdiMetafile(Stream)</a>
        </td>
        <td class="markdown level1 summary"><p>Creates a new GdiMetafile object that you can use to replay metafile content.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_CreatePathGeometry1" data-uid="C1.Util.DX.Direct2D.Factory1.CreatePathGeometry1">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.CreatePathGeometry1.html#C1_Util_DX_Direct2D_Factory1_CreatePathGeometry1">CreatePathGeometry1()</a>
        </td>
        <td class="markdown level1 summary"><p>HRESULT ID2D1Factory1::CreatePathGeometry([Out, Fast] ID2D1PathGeometry1** pathGeometry)</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_CreateStrokeStyle1_C1_Util_DX_Direct2D_StrokeStyleProperties1__" data-uid="C1.Util.DX.Direct2D.Factory1.CreateStrokeStyle1(C1.Util.DX.Direct2D.StrokeStyleProperties1@)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.CreateStrokeStyle1.html#C1_Util_DX_Direct2D_Factory1_CreateStrokeStyle1_C1_Util_DX_Direct2D_StrokeStyleProperties1__">CreateStrokeStyle1(ref StrokeStyleProperties1)</a>
        </td>
        <td class="markdown level1 summary"><p>HRESULT ID2D1Factory1::CreateStrokeStyle([In] const D2D1_STROKE_STYLE_PROPERTIES1* strokeStyleProperties,[In, Buffer, Optional] const float* dashes,[In] unsigned int dashesCount,[Out, Fast] ID2D1StrokeStyle1** strokeStyle)</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_CreateStrokeStyle1_C1_Util_DX_Direct2D_StrokeStyleProperties1__System_Single___" data-uid="C1.Util.DX.Direct2D.Factory1.CreateStrokeStyle1(C1.Util.DX.Direct2D.StrokeStyleProperties1@,System.Single[])">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.CreateStrokeStyle1.html#C1_Util_DX_Direct2D_Factory1_CreateStrokeStyle1_C1_Util_DX_Direct2D_StrokeStyleProperties1__System_Single___">CreateStrokeStyle1(ref StrokeStyleProperties1, float[])</a>
        </td>
        <td class="markdown level1 summary"><p>HRESULT ID2D1Factory1::CreateStrokeStyle([In] const D2D1_STROKE_STYLE_PROPERTIES1* strokeStyleProperties,[In, Buffer, Optional] const float* dashes,[In] unsigned int dashesCount,[Out, Fast] ID2D1StrokeStyle1** strokeStyle)</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_Dispose_System_Boolean_" data-uid="C1.Util.DX.Direct2D.Factory1.Dispose(System.Boolean)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.Dispose.html#C1_Util_DX_Direct2D_Factory1_Dispose_System_Boolean_">Dispose(bool)</a>
        </td>
        <td class="markdown level1 summary"><p>Clean up any resources being used.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_GetEffectProperties_System_Guid_" data-uid="C1.Util.DX.Direct2D.Factory1.GetEffectProperties(System.Guid)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.GetEffectProperties.html#C1_Util_DX_Direct2D_Factory1_GetEffectProperties_System_Guid_">GetEffectProperties(Guid)</a>
        </td>
        <td class="markdown level1 summary"><p>HRESULT ID2D1Factory1::GetEffectProperties([In] const GUID&amp; effectId,[Out] ID2D1Properties** properties)</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_GetRegisteredEffects_System_Guid___System_Int32_System_Int32__System_Int32__" data-uid="C1.Util.DX.Direct2D.Factory1.GetRegisteredEffects(System.Guid[],System.Int32,System.Int32@,System.Int32@)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.GetRegisteredEffects.html#C1_Util_DX_Direct2D_Factory1_GetRegisteredEffects_System_Guid___System_Int32_System_Int32__System_Int32__">GetRegisteredEffects(Guid[], int, out int, out int)</a>
        </td>
        <td class="markdown level1 summary"><p>HRESULT ID2D1Factory1::GetRegisteredEffects([Out, Buffer, Optional] GUID* effects,[In] unsigned int effectsCount,[Out, Optional] unsigned int* effectsReturned,[Out, Optional] unsigned int* effectsRegistered)</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_RegisterEffectFromString_System_Guid_System_String_C1_Util_DX_Direct2D_PropertyBinding___System_Int32_C1_Util_DX_FunctionCallback_" data-uid="C1.Util.DX.Direct2D.Factory1.RegisterEffectFromString(System.Guid,System.String,C1.Util.DX.Direct2D.PropertyBinding[],System.Int32,C1.Util.DX.FunctionCallback)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.RegisterEffectFromString.html#C1_Util_DX_Direct2D_Factory1_RegisterEffectFromString_System_Guid_System_String_C1_Util_DX_Direct2D_PropertyBinding___System_Int32_C1_Util_DX_FunctionCallback_">RegisterEffectFromString(Guid, string, PropertyBinding[], int, FunctionCallback)</a>
        </td>
        <td class="markdown level1 summary"><p>HRESULT ID2D1Factory1::RegisterEffectFromString([In] const GUID&amp; classId,[In] const wchar_t* propertyXml,[In, Buffer, Optional] const D2D1_PROPERTY_BINDING* bindings,[In] unsigned int bindingsCount,[In] const __function__stdcall* effectFactory)</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_RegisterEffect__1" data-uid="C1.Util.DX.Direct2D.Factory1.RegisterEffect``1">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.RegisterEffect.html#C1_Util_DX_Direct2D_Factory1_RegisterEffect__1">RegisterEffect&lt;T&gt;()</a>
        </td>
        <td class="markdown level1 summary"><p>Register a <a class="xref" href="C1.Util.DX.Direct2D.CustomEffect.html">CustomEffect</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_RegisterEffect__1_System_Func___0__" data-uid="C1.Util.DX.Direct2D.Factory1.RegisterEffect``1(System.Func{``0})">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.RegisterEffect.html#C1_Util_DX_Direct2D_Factory1_RegisterEffect__1_System_Func___0__">RegisterEffect&lt;T&gt;(Func&lt;T&gt;)</a>
        </td>
        <td class="markdown level1 summary"><p>Register a <a class="xref" href="C1.Util.DX.Direct2D.CustomEffect.html">CustomEffect</a> factory.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_RegisterEffect__1_System_Func___0__System_Guid_" data-uid="C1.Util.DX.Direct2D.Factory1.RegisterEffect``1(System.Func{``0},System.Guid)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.RegisterEffect.html#C1_Util_DX_Direct2D_Factory1_RegisterEffect__1_System_Func___0__System_Guid_">RegisterEffect&lt;T&gt;(Func&lt;T&gt;, Guid)</a>
        </td>
        <td class="markdown level1 summary"><p>Register a <a class="xref" href="C1.Util.DX.Direct2D.CustomEffect.html">CustomEffect</a> factory.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_RegisterEffect__1_System_Guid_" data-uid="C1.Util.DX.Direct2D.Factory1.RegisterEffect``1(System.Guid)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.RegisterEffect.html#C1_Util_DX_Direct2D_Factory1_RegisterEffect__1_System_Guid_">RegisterEffect&lt;T&gt;(Guid)</a>
        </td>
        <td class="markdown level1 summary"><p>Register a <a class="xref" href="C1.Util.DX.Direct2D.CustomEffect.html">CustomEffect</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_UnregisterEffect_System_Guid_" data-uid="C1.Util.DX.Direct2D.Factory1.UnregisterEffect(System.Guid)">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.UnregisterEffect.html#C1_Util_DX_Direct2D_Factory1_UnregisterEffect_System_Guid_">UnregisterEffect(Guid)</a>
        </td>
        <td class="markdown level1 summary"><p>HRESULT ID2D1Factory1::UnregisterEffect([In] const GUID&amp; classId)</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_UnregisterEffect__1" data-uid="C1.Util.DX.Direct2D.Factory1.UnregisterEffect``1">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.UnregisterEffect.html#C1_Util_DX_Direct2D_Factory1_UnregisterEffect__1">UnregisterEffect&lt;T&gt;()</a>
        </td>
        <td class="markdown level1 summary"><p>Unregister a <a class="xref" href="C1.Util.DX.Direct2D.CustomEffect.html">CustomEffect</a>.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="operators">Operators
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_Util_DX_Direct2D_Factory1_op_Explicit_System_IntPtr__C1_Util_DX_Direct2D_Factory1" data-uid="C1.Util.DX.Direct2D.Factory1.op_Explicit(System.IntPtr)~C1.Util.DX.Direct2D.Factory1">
          <a class="xref" href="C1.Util.DX.Direct2D.Factory1.op_Explicit.html#C1_Util_DX_Direct2D_Factory1_op_Explicit_System_IntPtr__C1_Util_DX_Direct2D_Factory1">explicit operator Factory1(IntPtr)</a>
        </td>
        <td class="markdown level1 summary"><p>Performs an explicit conversion from <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.intptr">IntPtr</a> to <a class="xref" href="C1.Util.DX.Direct2D.Factory1.html">Factory1</a>.</p>
</td>
      </tr>
    </tbody>
  </table>

</div>
