Lines Matching defs:patch
1891 struct WineD3DRectPatch *patch;
1893 patch = LIST_ENTRY(e1, struct WineD3DRectPatch, entry);
1894 IWineD3DDevice_DeletePatch(iface, patch->Handle);
5629 struct WineD3DRectPatch *patch;
5646 patch = LIST_ENTRY(e, struct WineD3DRectPatch, entry);
5647 if(patch->Handle == Handle) {
5655 patch = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*patch));
5656 patch->Handle = Handle;
5657 list_add_head(&This->patches[i], &patch->entry);
5659 TRACE("Found existing patch %p\n", patch);
5663 * attributes we have to tesselate, read back, and draw. This needs a patch
5667 * draw the patch.
5669 FIXME("Drawing an uncached patch. This is slow\n");
5670 patch = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*patch));
5673 if(pNumSegs[0] != patch->numSegs[0] || pNumSegs[1] != patch->numSegs[1] ||
5674 pNumSegs[2] != patch->numSegs[2] || pNumSegs[3] != patch->numSegs[3] ||
5675 (pRectPatchInfo && memcmp(pRectPatchInfo, &patch->RectPatchInfo, sizeof(*pRectPatchInfo)) != 0) ) {
5677 TRACE("Tesselation density or patch info changed, retesselating\n");
5680 patch->RectPatchInfo = *pRectPatchInfo;
5682 patch->numSegs[0] = pNumSegs[0];
5683 patch->numSegs[1] = pNumSegs[1];
5684 patch->numSegs[2] = pNumSegs[2];
5685 patch->numSegs[3] = pNumSegs[3];
5687 hr = tesselate_rectpatch(This, patch);
5691 /* Do not release the handle to store the params of the patch */
5693 HeapFree(GetProcessHeap(), 0, patch);
5699 This->currentPatch = patch;
5702 IWineD3DDevice_DrawPrimitiveStrided(iface, patch->numSegs[0] * patch->numSegs[1] * 2 * 3, &patch->strided);
5708 HeapFree(GetProcessHeap(), 0, patch->mem);
5709 HeapFree(GetProcessHeap(), 0, patch);
5726 struct WineD3DRectPatch *patch;
5732 patch = LIST_ENTRY(e, struct WineD3DRectPatch, entry);
5733 if(patch->Handle == Handle) {
5734 TRACE("Deleting patch %p\n", patch);
5735 list_remove(&patch->entry);
5736 HeapFree(GetProcessHeap(), 0, patch->mem);
5737 HeapFree(GetProcessHeap(), 0, patch);
5743 FIXME("Attempt to destroy nonexistent patch\n");