Hi Wojciech,

First of thanks for the efforts in tracking down this issue.

I think that accepting a 32bit buffer when 24bit was sought would be
fine, but if the stick_adherance is set then it shouldn't be
acceptable.

Could you post changes to osg-submissions mailing list too, as this
will make it much easier for me and Don to track submissions - the
osg-users mailing list can often be swamped so fixes could be missed
otherwise.

A general note for other win32 users, could you guys test out these changes?

Robert.

On 7/12/06, Wojciech Lewandowski <[EMAIL PROTECTED]> wrote:


Hi again,

I took me longer than I thought but I finally made the tests. I can confirm
your observations. It seems that there is an issue with
VisualChooser::choose method implementation in Win32. Good thing for me this
is not my code but this (my changes were in RenderSurface ;-).

I did look further whats actually happening. It seems that list of
_visual_attributes contains 2 recommended depth buffer sizes: 16 bit and 24
bit. ChoosePixelFormat (Line 654 VisualChooser.cpp ver 1.26) returns
PIixelFormat using 32 bit depth. Code in lines 655-682 does aditional check
on attributes returned from DescribePixelFormat and rejects visual because
bit depth does not match exactly. And here lies the problem: this code
resets visualId but forgets to set failed flag which is used later. So the
remainning code assumes that visual was found but visual id is reset and
incorrect empty visualInfo structure is returned.

If Don or Robert reads this I have attached simple fix to VisualChooser.cpp.
This fix makes sure that VisualChooser::choose will return null if
PixelFormat gets rejected in lines 655-682. But I am not sure if this in
accordance wiht original intent. Should 32 bit depth buffer be rejected if
16 or 24 bit was sought ? If not further changes in the code should be
made... And what is the role of strict_adherence flag ?

Best,
Wojtek Lewandowski


----- Original Message -----

From: Frank Bergmann
To: 'osg users'

Sent: Sunday, July 09, 2006 5:22 AM
Subject: RE: [osg-users] Working towards OpenSceneGraph-1.1 release




Hello Wojtek,



Sorry for taking my sweet time to answer this one … I believe the problem to
be with the choose method in VisualChooser.cpp … in line 683 the visual id
will be set to zero in case one of the tests fail. On an older (or virtual,
or remote machine) there will not be a better visual than the one already
found.



So what I did in my build was to display a warning in console mode and in
window mode my application is silent about the test-failure and work just
fine. I know that this is a hack and I would like to see this issue solved
in a better way.



Best

Frank





From: Wojciech Lewandowski [mailto:[EMAIL PROTECTED]
Sent: Wednesday, June 28, 2006 6:54 AM
To: osg users
Subject: Re: [osg-users] Working towards OpenSceneGraph-1.1 release




Hi Frank,





What you describe seems a bit difficult for me for me. I don't have easy
access to second machine to test these scenarios. In fact I have a lot of
other work to do till the end of this week. Hopefully situation will change
and I will look at the problem next week.





If you can't wait you may try to revert my changes and see if that helps.
Don submitted them around 12th April 2006. Look at the thread with following
topic:


"Attaching OGL initialized Window to RenderSurface +RenderSurface build
broken"


Wojtek






----- Original Message -----


From: Frank Bergmann


To: 'osg users'


Sent: Tuesday, June 27, 2006 7:28 PM


Subject: RE: [osg-users] Working towards OpenSceneGraph-1.1 release




Hello Wojtek,



One easy way to reproduce the failure would be to use a remote desktop
connection to your Win32 development machine. When using Remote Desktop it
will seem to windows as if a different graphics card is used. When tracing
the call I see a test for the DepthSize (VisualChooser.cpp Line 678) failing
… maybe it would be enough for me to reset the attribute from 32 to 24 bit …



And yes it occurs with the osgDemos … osgTeapot will result in an endless
loop of OpenGL errors, osgPick is an example of an application crashing
(access violation) with:



"Error: In Texture::Extensions::setupGLExtensions(..)
OpenGL version test failed, requires valid graphics context."



The same error occurs when testing the application in a virtual WIN32
machine (VMware) … while it works fine with virtual machines with linux
systems.



Thanks

Frank





From: Wojciech Lewandowski [mailto:[EMAIL PROTECTED]
Sent: Tuesday, June 27, 2006 6:59 AM
To: osg users
Subject: Re: [osg-users] Working towards OpenSceneGraph-1.1 release




Frank & Robert,





I may be somehow responsible for the above issues. I once asked Don to
provide support for render surface to use window with gl context already
created. Don implemented this feature in Linux and made empty placeholder
for Windows version. I wrote neccessary portion of code and Don put this
into repository.





I was quite a long ago and I don't remember details but may try to help you
if you provide some aditional details. Do you see this problem when using
osg Demos ? If not how you create render surface ? Do you work with non
standard windows toolkit ? Can you trace the code and see which WGL
extensions are missing ?





Wojtek Lewandowski





P.S. I don't feel responsible for use of MessageBoxes though ;-) They were
there already...






----- Original Message -----


From: Frank Bergmann


To: 'osg users'


Sent: Monday, June 26, 2006 8:07 PM


Subject: RE: [osg-users] Working towards OpenSceneGraph-1.1 release




The current CVS version works fine for me with one noticeable change since
the 1.0 release:



-          The Producer will no longer work with older graphics cards not
supporting certain WGL extensions on WIN32. Osg::notify prints:

"Producer::VisualChooser: unable to setup a valid visual with WGL
extensions, switching to compatibility mode."

even more annoying is a MessageBox popping up:

"Producer: Internal Error: Can't assign Visual (PIXELFORMAT) to surface. The
parameter is incorrect."

after clicking the message box away one of several things happens:

Either I get an error message:

"Error: OpenGL version test failed, requires valid graphics context." And
the program dies because of access violations …

or


The program continues but each draw attempt will just print that realize has
to be called first.



Obviously the "switching to compatibility mode" does not work out well. Also
the whole  notion that a dependency library will open MessageBoxes is not
something I relish, I prefer exceptions.



Under Linux (FC5, ubuntu 6.06) the problem does not exist … also OSG 1.0 and
0.9.9 on Win32 … works just fine, confirming that the problem seems to
confined to "RenderSurface_Win32.cpp".

Cheers

Frank





From: Robert Osfield [mailto:[EMAIL PROTECTED]
Sent: Monday, June 26, 2006 7:21 AM
To: osg users
Subject: [osg-users] Working towards OpenSceneGraph-1.1 release



Hi All,

I would like to start working towards getting the OpenSceneGraph-1.1
release out in July, and would very much appreciate assistance from
the community in this effort.

1) The first phase has to be testing out the CVS version of
OpenThreads/Produer and OpenSceneGraph on as many platforms as
possible, fixing build issues on each of these platforms.  Testing
against your own applications will also be invaluable.

2) The second phase will be the a series of release candidates.  This
phase will only commense once we have general consensus that the CVS
versions are all compiling and working ok.

3) The thrid phase will be the actual release.  This will be once we
have a release candidate that looks solid w.r.t source code and the
distribution tarballs themselves.  The third phase is mainly down to
me updating the website in all the appropriate places, but its also
about then telling all the various relevant news websites about the
new release - something the community can certainly help significantly
with.

I'd like everything to be complete in time for Siggraph, but the
earlier the better as those heading to Siggraph will no doubt be busy,
and well I'm gunna be pretty busy preparing for me house move.

Phase 1 can start right now.  I'll try and turn around build fixes
ASAP to get things back and tested.  I am still checking in a few
submissions, more on this on follow up emails in this thread.

Thanks in advance for your help,
Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

 ________________________________


_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/
 ________________________________


_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


 ________________________________


_______________________________________________

osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/



_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/



_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Reply via email to