コード例 #1
0
 internal unsafe void MarshalTo(SharpVk.Interop.PipelineCacheCreateInfo *pointer)
 {
     pointer->SType = StructureType.PipelineCacheCreateInfo;
     pointer->Next  = null;
     if (this.Flags != null)
     {
         pointer->Flags = this.Flags.Value;
     }
     else
     {
         pointer->Flags = default(SharpVk.PipelineCacheCreateFlags);
     }
     pointer->InitialDataSize = (HostSize)(this.InitialData?.Length ?? 0);
     if (this.InitialData != null)
     {
         var fieldPointer = (byte *)(Interop.HeapUtil.AllocateAndClear <byte>(this.InitialData.Length).ToPointer());
         for (int index = 0; index < (uint)(this.InitialData.Length); index++)
         {
             fieldPointer[index] = this.InitialData[index];
         }
         pointer->InitialData = fieldPointer;
     }
     else
     {
         pointer->InitialData = null;
     }
 }
コード例 #2
0
 public static extern SharpVk.Result vkCreatePipelineCache(SharpVk.Interop.Device device, SharpVk.Interop.PipelineCacheCreateInfo *createInfo, SharpVk.Interop.AllocationCallbacks *allocator, SharpVk.Interop.PipelineCache *pipelineCache);