Lines Matching refs:backendContext
59 sk_sp<GrGpu> GrVkGpu::Make(const GrVkBackendContext& backendContext, in Make() argument
61 if (backendContext.fInstance == VK_NULL_HANDLE || in Make()
62 backendContext.fPhysicalDevice == VK_NULL_HANDLE || in Make()
63 backendContext.fDevice == VK_NULL_HANDLE || in Make()
64 backendContext.fQueue == VK_NULL_HANDLE) { in Make()
67 if (!backendContext.fGetProc) { in Make()
73 backendContext.fGetProc("vkEnumerateInstanceVersion", in Make()
88 backendContext.fGetProc("vkGetPhysicalDeviceProperties", in Make()
89 backendContext.fInstance, in Make()
96 localGetPhysicalDeviceProperties(backendContext.fPhysicalDevice, &physDeviceProperties); in Make()
99 uint32_t apiVersion = backendContext.fMaxAPIVersion ? backendContext.fMaxAPIVersion in Make()
107 if (backendContext.fVkExtensions) { in Make()
108 interface.reset(new GrVkInterface(backendContext.fGetProc, in Make()
109 backendContext.fInstance, in Make()
110 backendContext.fDevice, in Make()
113 backendContext.fVkExtensions)); in Make()
114 if (!interface->validate(instanceVersion, physDevVersion, backendContext.fVkExtensions)) { in Make()
121 interface.reset(new GrVkInterface(backendContext.fGetProc, in Make()
122 backendContext.fInstance, in Make()
123 backendContext.fDevice, in Make()
132 return sk_sp<GrGpu>(new GrVkGpu(context, options, backendContext, interface, instanceVersion, in Make()
139 const GrVkBackendContext& backendContext, sk_sp<const GrVkInterface> interface, in GrVkGpu() argument
143 , fMemoryAllocator(backendContext.fMemoryAllocator) in GrVkGpu()
144 , fInstance(backendContext.fInstance) in GrVkGpu()
145 , fPhysicalDevice(backendContext.fPhysicalDevice) in GrVkGpu()
146 , fDevice(backendContext.fDevice) in GrVkGpu()
147 , fQueue(backendContext.fQueue) in GrVkGpu()
148 , fQueueIndex(backendContext.fGraphicsQueueIndex) in GrVkGpu()
151 SkASSERT(!backendContext.fOwnsInstanceAndDevice); in GrVkGpu()
155 fMemoryAllocator.reset(new GrVkAMDMemoryAllocator(backendContext.fPhysicalDevice, in GrVkGpu()
161 if (backendContext.fDeviceFeatures2) { in GrVkGpu()
162 fVkCaps.reset(new GrVkCaps(options, this->vkInterface(), backendContext.fPhysicalDevice, in GrVkGpu()
163 *backendContext.fDeviceFeatures2, instanceVersion, in GrVkGpu()
165 *backendContext.fVkExtensions)); in GrVkGpu()
166 } else if (backendContext.fDeviceFeatures) { in GrVkGpu()
169 features2.features = *backendContext.fDeviceFeatures; in GrVkGpu()
170 fVkCaps.reset(new GrVkCaps(options, this->vkInterface(), backendContext.fPhysicalDevice, in GrVkGpu()
172 *backendContext.fVkExtensions)); in GrVkGpu()
177 if (backendContext.fFeatures & kGeometryShader_GrVkFeatureFlag) { in GrVkGpu()
180 if (backendContext.fFeatures & kDualSrcBlend_GrVkFeatureFlag) { in GrVkGpu()
183 if (backendContext.fFeatures & kSampleRateShading_GrVkFeatureFlag) { in GrVkGpu()
186 fVkCaps.reset(new GrVkCaps(options, this->vkInterface(), backendContext.fPhysicalDevice, in GrVkGpu()
192 VK_CALL(GetPhysicalDeviceProperties(backendContext.fPhysicalDevice, &fPhysDevProps)); in GrVkGpu()
193 VK_CALL(GetPhysicalDeviceMemoryProperties(backendContext.fPhysicalDevice, &fPhysDevMemProps)); in GrVkGpu()