wined3d: Merge indexbuffer and buffer implementations.