internal static unsafe ReflectTypeDescription GetManaged(ref SpirvReflectNative.SpvReflectTypeDescription type_description) { ReflectTypeDescription desc = new ReflectTypeDescription(); PopulateReflectTypeDescription(ref type_description, ref desc); desc.Members = ToManagedArray(type_description.members, type_description.member_count); return(desc); }
private static unsafe void PopulateReflectTypeDescription( ref SpirvReflectNative.SpvReflectTypeDescription type_description, ref ReflectTypeDescription desc) { desc.Id = type_description.id; desc.Op = (Op)type_description.op; desc.TypeName = new string(type_description.type_name); desc.StructMemberName = new string(type_description.struct_member_name); desc.StorageClass = (StorageClass)type_description.storage_class; desc.TypeFlags = (ReflectType)type_description.type_flags.Data; desc.DecorationFlags = (ReflectDecoration)type_description.decoration_flags.Data; desc.Traits = new Traits(type_description.traits); }