Re: [5/5] WineD3D: Implement buffer subrange mapping with GL_APPLE_flush_buffer_range

2009-12-17 Thread Stefan Dösinger
Hi, Here's a new patch for review. I won't send it until Monday because I want to do some performance testing(see below), and because the ddraw patch is queued below that, but it needs more testing. The changes are essentially some bugfixing(one NULL pointer exception), and I dropped the opti

Re: [5/5] WineD3D: Implement buffer subrange mapping with GL_APPLE_flush_buffer_range

2009-12-16 Thread Henri Verbeet
2009/12/16 Stefan Dösinger : > Actually, since we're not going to Unmap-flush and PreLoad() the buffer(its > either-or), I can use the same data structure for the stack and list(or well, > dynamic array). I just have to watch out not to remove elements in any place > in unlock that affects DOUBL

Re: [5/5] WineD3D: Implement buffer subrange mapping with GL_APPLE_flush_buffer_range

2009-12-16 Thread Stefan Dösinger
Am 16.12.2009 um 13:44 schrieb Henri Verbeet: > 2009/12/16 Stefan Dösinger : >> The best way I see to merge those two tracking mechanisms is to organize >> them as a list, and upload all modified ranges in PreLoad(), or if the >> buffer is single buffered and dynamic, flush all the ranges after

Re: [5/5] WineD3D: Implement buffer subrange mapping with GL_APPLE_flush_buffer_range

2009-12-16 Thread Henri Verbeet
2009/12/16 Stefan Dösinger : > The best way I see to merge those two tracking mechanisms is to organize them > as a list, and upload all modified ranges in PreLoad(), or if the buffer is > single buffered and dynamic, flush all the ranges after the last unmap, and > clear the list in both PreLoa

Re: [5/5] WineD3D: Implement buffer subrange mapping with GL_APPLE_flush_buffer_range

2009-12-16 Thread Stefan Dösinger
Am 16.12.2009 um 12:50 schrieb Henri Verbeet: > What you're doing (or should be doing) is extending the > "lock_count/dirty_start/dirty_end" scheme to something more detailed. > I don't think using two different schemes depending on whether the > buffer is dynamic or not is a good idea. Sounds gre

Re: [5/5] WineD3D: Implement buffer subrange mapping with GL_APPLE_flush_buffer_range

2009-12-16 Thread Henri Verbeet
2009/12/16 Stefan Dösinger : > Am 16.12.2009 um 11:33 schrieb Henri Verbeet: > >> 2009/12/15 Stefan Dösinger : >>> @@ -85,6 +85,21 @@ static void buffer_create_buffer_object(struct >>> wined3d_buffer *This) >> ... >>> +            This->maps = HeapAlloc(GetProcessHeap(), 0, >>> sizeof(*This->maps

Re: [5/5] WineD3D: Implement buffer subrange mapping with GL_APPLE_flush_buffer_range

2009-12-16 Thread Stefan Dösinger
Am 16.12.2009 um 11:33 schrieb Henri Verbeet: > 2009/12/15 Stefan Dösinger : >> @@ -85,6 +85,21 @@ static void buffer_create_buffer_object(struct >> wined3d_buffer *This) > ... >> +This->maps = HeapAlloc(GetProcessHeap(), 0, >> sizeof(*This->maps)); > > This is the wrong place for

Re: [5/5] WineD3D: Implement buffer subrange mapping with GL_APPLE_flush_buffer_range

2009-12-16 Thread Henri Verbeet
2009/12/15 Stefan Dösinger : > @@ -85,6 +85,21 @@ static void buffer_create_buffer_object(struct > wined3d_buffer *This) ... > +This->maps = HeapAlloc(GetProcessHeap(), 0, sizeof(*This->maps)); This is the wrong place for that. Either do it in buffer_init(), or in buffer_Map(). Keepin