コード例 #1
0
ファイル: IndexBuffer.cs プロジェクト: alexey-bez/SharpDX
 /// <summary>
 /// Initializes a new instance of the <see cref="IndexBuffer"/> class.
 /// </summary>
 /// <param name="device">The device.</param>
 /// <param name="sizeInBytes">The size in bytes.</param>
 /// <param name="usage">The usage.</param>
 /// <param name="pool">The pool.</param>
 /// <param name="sixteenBit">if set to <c>true</c> use 16bit index buffer, otherwise, use 32bit index buffer.</param>
 /// <param name="sharedHandle">The shared handle.</param>
 /// <msdn-id>bb174357</msdn-id>	
 /// <unmanaged>HRESULT IDirect3DDevice9::CreateIndexBuffer([In] unsigned int Length,[In] unsigned int Usage,[In] D3DFORMAT Format,[In] D3DPOOL Pool,[Out, Fast] IDirect3DIndexBuffer9** ppIndexBuffer,[In] void** pSharedHandle)</unmanaged>	
 /// <unmanaged-short>IDirect3DDevice9::CreateIndexBuffer</unmanaged-short>	
 public IndexBuffer(Device device, int sizeInBytes, Usage usage, Pool pool, bool sixteenBit, ref IntPtr sharedHandle)
     : base(IntPtr.Zero)
 {
     unsafe
     {
         fixed (void* pSharedHandle = &sharedHandle)
             device.CreateIndexBuffer(sizeInBytes, (int)usage, sixteenBit ? Format.Index16 : Format.Index32, pool, this, (IntPtr)pSharedHandle);
     }
 }
コード例 #2
0
ファイル: IndexBuffer.cs プロジェクト: zmtzawqlp/SharpDX
 /// <summary>
 /// Initializes a new instance of the <see cref="IndexBuffer"/> class.
 /// </summary>
 /// <param name="device">The device.</param>
 /// <param name="sizeInBytes">The size in bytes.</param>
 /// <param name="usage">The usage.</param>
 /// <param name="pool">The pool.</param>
 /// <param name="sixteenBit">if set to <c>true</c> use 16bit index buffer, otherwise, use 32bit index buffer.</param>
 /// <param name="sharedHandle">The shared handle.</param>
 /// <msdn-id>bb174357</msdn-id>
 /// <unmanaged>HRESULT IDirect3DDevice9::CreateIndexBuffer([In] unsigned int Length,[In] unsigned int Usage,[In] D3DFORMAT Format,[In] D3DPOOL Pool,[Out, Fast] IDirect3DIndexBuffer9** ppIndexBuffer,[In] void** pSharedHandle)</unmanaged>
 /// <unmanaged-short>IDirect3DDevice9::CreateIndexBuffer</unmanaged-short>
 public IndexBuffer(Device device, int sizeInBytes, Usage usage, Pool pool, bool sixteenBit, ref IntPtr sharedHandle)
     : base(IntPtr.Zero)
 {
     unsafe
     {
         fixed(void *pSharedHandle = &sharedHandle)
         device.CreateIndexBuffer(sizeInBytes, (int)usage, sixteenBit ? Format.Index16 : Format.Index32, pool, this, (IntPtr)pSharedHandle);
     }
 }
コード例 #3
0
ファイル: IndexBuffer.cs プロジェクト: alexey-bez/SharpDX
 /// <summary>
 /// Initializes a new instance of the <see cref="IndexBuffer"/> class.
 /// </summary>
 /// <param name="device">The device.</param>
 /// <param name="sizeInBytes">The size in bytes.</param>
 /// <param name="usage">The usage.</param>
 /// <param name="pool">The pool.</param>
 /// <param name="sixteenBit">if set to <c>true</c> use 16bit index buffer, otherwise, use 32bit index buffer.</param>
 /// <msdn-id>bb174357</msdn-id>	
 /// <unmanaged>HRESULT IDirect3DDevice9::CreateIndexBuffer([In] unsigned int Length,[In] unsigned int Usage,[In] D3DFORMAT Format,[In] D3DPOOL Pool,[Out, Fast] IDirect3DIndexBuffer9** ppIndexBuffer,[In] void** pSharedHandle)</unmanaged>	
 /// <unmanaged-short>IDirect3DDevice9::CreateIndexBuffer</unmanaged-short>	
 public IndexBuffer(Device device, int sizeInBytes, Usage usage, Pool pool, bool sixteenBit)
     : base(IntPtr.Zero)
 {
     device.CreateIndexBuffer(sizeInBytes, (int)usage, sixteenBit ? Format.Index16 : Format.Index32, pool, this, IntPtr.Zero);
 }
コード例 #4
0
ファイル: IndexBuffer.cs プロジェクト: zmtzawqlp/SharpDX
 /// <summary>
 /// Initializes a new instance of the <see cref="IndexBuffer"/> class.
 /// </summary>
 /// <param name="device">The device.</param>
 /// <param name="sizeInBytes">The size in bytes.</param>
 /// <param name="usage">The usage.</param>
 /// <param name="pool">The pool.</param>
 /// <param name="sixteenBit">if set to <c>true</c> use 16bit index buffer, otherwise, use 32bit index buffer.</param>
 /// <msdn-id>bb174357</msdn-id>
 /// <unmanaged>HRESULT IDirect3DDevice9::CreateIndexBuffer([In] unsigned int Length,[In] unsigned int Usage,[In] D3DFORMAT Format,[In] D3DPOOL Pool,[Out, Fast] IDirect3DIndexBuffer9** ppIndexBuffer,[In] void** pSharedHandle)</unmanaged>
 /// <unmanaged-short>IDirect3DDevice9::CreateIndexBuffer</unmanaged-short>
 public IndexBuffer(Device device, int sizeInBytes, Usage usage, Pool pool, bool sixteenBit)
     : base(IntPtr.Zero)
 {
     device.CreateIndexBuffer(sizeInBytes, (int)usage, sixteenBit ? Format.Index16 : Format.Index32, pool, this, IntPtr.Zero);
 }