wined3d: Respect ARB_VERTEX_BUFFER_OBJECT in loadVertexData.
Markus Amsler
markus.amsler at oribi.org
Sat Oct 28 09:44:54 CDT 2006
Stefan Dösinger wrote:
> Am Samstag 28 Oktober 2006 13:31 schrieb Markus Amsler:
>
>> Stefan Dösinger wrote:
>>
>>>> - GLint curVBO = -1;
>>>> + GLint curVBO = GL_SUPPORT(ARB_VERTEX_BUFFER_OBJECT) ? -1 : 0;
>>>>
>>> Strange, I thought I sent a patch like that already and it was committed
>>> :-/
>>>
>> You wrote it for loadNumberedArrays, I copy pasted it to loadVertexData.
>> I have to admit, I don't know exactly what I'm doing here (opengl/d3d
>> newbie).
>>
> The code below checks if the VBO for the data type in the stream is the vbo
> that is currently bound. 0 means no vbo, so setting the vbo to 0 equals
> operation without vbos. There is no member checking the current vbo in the
> device, only the curvbo optimization in the loading functions(waits for
> better state management).
>
> If vbos are not supported the vbo for each data in the stream source is always
> 0. Setting curvbo to 0 if vbos aren't supported will make sure that
> the .vbo != curvbo check is always false and glBindBufferARB is never called,
> preventing the crash due to a NULL or invalid function pointer.
>
Thanks, so the patch is correct after all.
>> But this patch lets me play Battlefield 1942 on my laptop where
>> ARB_VERTEX_BUFFER_OBJECT is not supported :-)
>>
> Could it be that you have some radeon dri setup without direct rendering(using
> accelerated indirect rendering instead)? I think even a gf2 and a mach64 card
> support vertex buffers objects, so I'm kinda surprised yours does not.
>
> Though, I also wonder why accelerated indirect rendering won't do VBOs.
>
Its a Radeon Mobility M7 LW, with direct rendering. It has a RV200 core
which is a R100 with the memory controller from R200. And it looks like
the R100 doesn't support vertex_buffer_objects (couldn't find precise
specs).
More information about the wine-devel
mailing list