case D3DPT_TRIANGLESTRIP:
return PrimitiveCount + 2;
case D3DPT_TRIANGLEFAN:
- return PrimitiveCount + 1;
+ return PrimitiveCount + 2;
default:
os::log("apitrace: warning: %s: unknown D3DPRIMITIVETYPE %u\n", __FUNCTION__, PrimitiveType);
return 0;
break;
case D3DSIO_END:
- if (dwToken != D3DSIO_END) {
- os::log("apitrace: warning: %s: malformed END token\n", __FUNCTION__);
+ if (dwToken == D3DSIO_END) {
+ return dwLength * sizeof *pFunction;
}
- return dwLength * sizeof *pFunction;
+ break;
}
}
}
#if DIRECT3D_VERSION >= 0x900
case D3DFMT_NV12:
+ case D3DFMT_YV12:
return (Height + ((Height + 1) / 2)) * RowPitch;
case D3DFMT_NULL: