Пример #1
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="pointer">
 /// </param>
 internal unsafe void MarshalTo(SharpVk.Interop.CommandBufferBeginInfo *pointer)
 {
     pointer->SType = StructureType.CommandBufferBeginInfo;
     pointer->Next  = null;
     if (this.Flags != null)
     {
         pointer->Flags = this.Flags.Value;
     }
     else
     {
         pointer->Flags = default(SharpVk.CommandBufferUsageFlags);
     }
     if (this.InheritanceInfo != null)
     {
         pointer->InheritanceInfo = (SharpVk.Interop.CommandBufferInheritanceInfo *)(Interop.HeapUtil.Allocate <SharpVk.Interop.CommandBufferInheritanceInfo>());
         this.InheritanceInfo.Value.MarshalTo(pointer->InheritanceInfo);
     }
     else
     {
         pointer->InheritanceInfo = default(SharpVk.Interop.CommandBufferInheritanceInfo *);
     }
 }
Пример #2
0
 /// <summary>
 ///
 /// </summary>
 public unsafe void Begin(SharpVk.CommandBufferUsageFlags?flags = default(SharpVk.CommandBufferUsageFlags?), SharpVk.CommandBufferInheritanceInfo?inheritanceInfo = default(SharpVk.CommandBufferInheritanceInfo?))
 {
     try
     {
         SharpVk.Interop.CommandBufferBeginInfo *marshalledBeginInfo = default(SharpVk.Interop.CommandBufferBeginInfo *);
         marshalledBeginInfo        = (SharpVk.Interop.CommandBufferBeginInfo *)(Interop.HeapUtil.Allocate <SharpVk.Interop.CommandBufferBeginInfo>());
         marshalledBeginInfo->SType = StructureType.CommandBufferBeginInfo;
         marshalledBeginInfo->Next  = null;
         if (flags != null)
         {
             marshalledBeginInfo->Flags = flags.Value;
         }
         else
         {
             marshalledBeginInfo->Flags = default(SharpVk.CommandBufferUsageFlags);
         }
         if (inheritanceInfo != null)
         {
             marshalledBeginInfo->InheritanceInfo = (SharpVk.Interop.CommandBufferInheritanceInfo *)(Interop.HeapUtil.Allocate <SharpVk.Interop.CommandBufferInheritanceInfo>());
             inheritanceInfo.Value.MarshalTo(marshalledBeginInfo->InheritanceInfo);
         }
         else
         {
             marshalledBeginInfo->InheritanceInfo = default(SharpVk.Interop.CommandBufferInheritanceInfo *);
         }
         Result methodResult = Interop.Commands.vkBeginCommandBuffer(this.handle, marshalledBeginInfo);
         if (SharpVkException.IsError(methodResult))
         {
             throw SharpVkException.Create(methodResult);
         }
     }
     finally
     {
         Interop.HeapUtil.FreeAll();
     }
 }
Пример #3
0
 public static extern SharpVk.Result vkBeginCommandBuffer(SharpVk.Interop.CommandBuffer commandBuffer, SharpVk.Interop.CommandBufferBeginInfo *beginInfo);