Lines Matching refs:This

8  * This library is free software; you can redistribute it and/or
13 * This library is distributed in the hope that it will be useful,
268 IWineD3DQueryImpl *This = (IWineD3DQueryImpl *)iface;
269 TRACE("(%p)->(%s,%p)\n",This,debugstr_guid(riid),ppobj);
274 *ppobj = This;
282 IWineD3DQueryImpl *This = (IWineD3DQueryImpl *)iface;
283 TRACE("(%p) : AddRef increasing from %d\n", This, This->ref);
284 return InterlockedIncrement(&This->ref);
288 IWineD3DQueryImpl *This = (IWineD3DQueryImpl *)iface;
290 TRACE("(%p) : Releasing from %d\n", This, This->ref);
291 ref = InterlockedDecrement(&This->ref);
297 if (This->type == WINED3DQUERYTYPE_EVENT)
299 struct wined3d_event_query *query = This->extendedData;
302 else if (This->type == WINED3DQUERYTYPE_OCCLUSION)
304 struct wined3d_occlusion_query *query = This->extendedData;
307 HeapFree(GetProcessHeap(), 0, This->extendedData);
310 HeapFree(GetProcessHeap(), 0, This);
331 IWineD3DQueryImpl *This = (IWineD3DQueryImpl *) iface;
332 struct wined3d_occlusion_query *query = This->extendedData;
333 IWineD3DDeviceImpl *device = This->device;
341 TRACE("(%p) : type D3DQUERY_OCCLUSION, pData %p, dwSize %#x, dwGetDataFlags %#x\n", This, pData, dwSize, dwGetDataFlags);
343 if (!query->context) This->state = QUERY_CREATED;
345 if (This->state == QUERY_CREATED)
353 if (This->state == QUERY_BUILDING)
362 WARN("(%p) : Occlusion queries not supported. Returning 1.\n", This);
369 FIXME("%p Wrong thread, returning 1.\n", This);
374 context = context_acquire(This->device, query->context->current_rt, CTXUSAGE_RESOURCELOAD);
380 TRACE("(%p) : available %d.\n", This, available);
388 TRACE("(%p) : Returning %d samples.\n", This, samples);
406 IWineD3DQueryImpl *This = (IWineD3DQueryImpl *) iface;
407 struct wined3d_event_query *query = This->extendedData;
411 TRACE("(%p) : type D3DQUERY_EVENT, pData %p, dwSize %#x, dwGetDataFlags %#x\n", This, pData, dwSize, dwGetDataFlags);
416 WARN("(%p): Event query not supported by GL, reporting GPU idle\n", This);
421 ret = wined3d_event_query_test(query, This->device);
434 FIXME("(%p) Wrong thread, reporting GPU idle.\n", This);
459 IWineD3DQueryImpl *This = (IWineD3DQueryImpl *)iface;
460 return This->type;
464 IWineD3DQueryImpl *This = (IWineD3DQueryImpl *)iface;
466 TRACE("(%p) : dwIssueFlags %#x, type D3DQUERY_EVENT\n", This, dwIssueFlags);
469 struct wined3d_event_query *query = This->extendedData;
474 wined3d_event_query_issue(query, This->device);
483 This->state = QUERY_BUILDING;
485 This->state = QUERY_SIGNALLED;
492 IWineD3DQueryImpl *This = (IWineD3DQueryImpl *)iface;
493 IWineD3DDeviceImpl *device = This->device;
498 struct wined3d_occlusion_query *query = This->extendedData;
501 /* This is allowed according to msdn and our tests. Reset the query and restart */
504 if (This->state == QUERY_BUILDING)
511 context = context_acquire(This->device, NULL, CTXUSAGE_RESOURCELOAD);
516 context = context_acquire(This->device, query->context->current_rt, CTXUSAGE_RESOURCELOAD);
527 context = context_acquire(This->device, NULL, CTXUSAGE_RESOURCELOAD);
543 if (This->state == QUERY_BUILDING)
551 context = context_acquire(This->device, query->context->current_rt, CTXUSAGE_RESOURCELOAD);
563 FIXME("(%p) : Occlusion queries not supported\n", This);
567 This->state = QUERY_BUILDING;
569 This->state = QUERY_SIGNALLED;