[Bug 8645] Issue when rendering with 2 contexts to one window

2006-10-16 Thread bugzilla-daemon
Please do not reply to this email: if you want to comment on the bug, go to
   
the URL shown below and enter yourcomments there. 
   
https://bugs.freedesktop.org/show_bug.cgi?id=8645  
 

[EMAIL PROTECTED] changed:

   What|Removed |Added

 AssignedTo|dri-|mesa3d-
   |[EMAIL PROTECTED] |[EMAIL PROTECTED]
  Component|General |Other
Product|DRI |Mesa
Version|XOrg CVS|CVS




--- Additional Comments From [EMAIL PROTECTED]  2006-10-16 08:31 ---
The underlying problem is that per-drawable state is tracked per context, which
is unfortunately quite widespread in DRI drivers currently, especially related
to buffer swaps (and vsync, ...).  
 
 
--   
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email 
 
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel


[Bug 8645] Issue when rendering with 2 contexts to one window

2006-10-15 Thread bugzilla-daemon
Please do not reply to this email: if you want to comment on the bug, go to
   
the URL shown below and enter yourcomments there. 
   
https://bugs.freedesktop.org/show_bug.cgi?id=8645  
 




--- Additional Comments From [EMAIL PROTECTED]  2006-10-15 02:53 ---
Good point, yes pageflip is enabled.

It seems using different contexts to render to the same window is a bit jerky 
in general. The nvidia driver seems to share the color attribute between both 
contexts, and fglrx just crashes :-/ . Is that supposed to work? The 
glXSwapBuffers manpage suggests that, but I haven't found anything else.

Maybe I can persuade our dict^H^H^H^H project maintainer to accept a 
SetThreadContext hack to take the rendering context away from the thread 
owning it...  
 
 
--   
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email 
 
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel


[Bug 8645] Issue when rendering with 2 contexts to one window

2006-10-15 Thread bugzilla-daemon
Please do not reply to this email: if you want to comment on the bug, go to
   
the URL shown below and enter yourcomments there. 
   
https://bugs.freedesktop.org/show_bug.cgi?id=8645  
 




--- Additional Comments From [EMAIL PROTECTED]  2006-10-15 13:42 ---
(In reply to comment #4)
 Good point, yes pageflip is enabled.
 
 It seems using different contexts to render to the same window is a bit jerky 
 in general. The nvidia driver seems to share the color attribute between both 
 contexts, and fglrx just crashes :-/ . Is that supposed to work? The 
 glXSwapBuffers manpage suggests that, but I haven't found anything else.
From quickly glancing at it, I would just say the same, but I'm no expert in
that area. Nevertheless, this looks like genuine driver bugs to me.

 Maybe I can persuade our dict^H^H^H^H project maintainer to accept a 
 SetThreadContext hack to take the rendering context away from the thread 
 owning it...
Well, I guess if it really doesn't work with pretty much any driver, you might
need to do that even if what you do is fully legal. I'd fix it for the radeon
drivers but I currently can't quite see how you'd notice the other contexts
upon a drawable change, as the __DRIdrawablePrivate struct only has a pointer to
a single context. Calling glXMakeCurrent in the drawing loops should work around
that problem (as that should make sure the hw buffer offsets get updated, just
as putting glDrawBuffers(GL_BACK) in there does), though again I don't think
this is needed by the spec.  
 
 
--   
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email 
 
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel


[Bug 8645] Issue when rendering with 2 contexts to one window

2006-10-14 Thread bugzilla-daemon
Please do not reply to this email: if you want to comment on the bug, go to
   
the URL shown below and enter yourcomments there. 
   
https://bugs.freedesktop.org/show_bug.cgi?id=8645  
 




--- Additional Comments From [EMAIL PROTECTED]  2006-10-14 12:34 ---
Created an attachment (id=7414)
 -- (https://bugs.freedesktop.org/attachment.cgi?id=7414action=view)
Test app to show the bug

This app creates a window and two glx contexts and starts 2 threads which use
the contexts to render to the window. The threads are only hackily
synchronised, but it should work, to my knowledge.

The program should draw a blue quad and a red primitive, with the red primitive
beeing partially covered by the quad. The problem is that the quad flickers as
if it was drawn to the front buffer. The flickering goes away if I move the
glDrawBuffers(GL_BACK); statements into the rendering loop in both threads.

The depth buffer seems to be shared properly between the contexts, and the
glColor state seems to work too.

The background is implementing multithreaded Direct3D for Wine. Direct3D
applications can do rendering from any thread, while a gl context is only valid
for one thread. Because of that a d3d app using differnt threads will just
crash with the current wine code.

We can't easilly take away the context from the thread it is assigned to
because we have no control over the threads, so we hope to be able to create
one context for each thread that does the rendering and share textures, VBOs,
shaders, ..., between the contexts and to render to the same window. Locking in
the d3d libs will make sure that only one thread renders at the same time.
  
 
 
--   
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email 
 
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel


[Bug 8645] Issue when rendering with 2 contexts to one window

2006-10-14 Thread bugzilla-daemon
Please do not reply to this email: if you want to comment on the bug, go to
   
the URL shown below and enter yourcomments there. 
   
https://bugs.freedesktop.org/show_bug.cgi?id=8645  
 




--- Additional Comments From [EMAIL PROTECTED]  2006-10-14 12:37 ---
Sorry, I forgot to mention, the version identification from glxinfo is:

OpenGL vendor string: Tungsten Graphics, Inc.
OpenGL renderer string: Mesa DRI R200 20060602 AGP 4x x86/MMX/SSE2 TCL
OpenGL version string: 1.3 Mesa 6.5.1
  
 
 
--   
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email 
 
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel


[Bug 8645] Issue when rendering with 2 contexts to one window

2006-10-14 Thread bugzilla-daemon
Please do not reply to this email: if you want to comment on the bug, go to
   
the URL shown below and enter yourcomments there. 
   
https://bugs.freedesktop.org/show_bug.cgi?id=8645  
 




--- Additional Comments From [EMAIL PROTECTED]  2006-10-14 18:08 ---
Have you enabled pageflip? It seems to work just fine here without pageflip, but
not with pageflip enabled.
I think the issue here is that in all of the radeon drivers (didn't look at
others), the radeon/r200PageFlip function which will finally get called upon a
glxSwapBuffers call updates the (per-context) hw state to adjust for the new
offsets. But since the drawable ultimately is bound to 2 contexts the other one
will still use the old values.  
 
 
--   
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email 
 
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel