[osg-users] 'loosing' textures?
Raymond de Vries
reedev at xs4all.nl
Wed Sep 19 23:21:41 PDT 2007
Hi,
I know, it sounds that I'm doing strange things. But the opposite is
true. Well, I am stripping everything and see where it is. Eventually it
will be something small & stupid, as always ;-)
Thanks for your time!
Raymond
Zach Deedler wrote:
> Well it does sound like you are doing some pretty crazy things, but I don't
> know why they'd cause textures to disappear. Are there any other odd things
> that you are doing?
>
> I had similar texture problems when using ReplicantBody models in my scenes.
> Are you loading any crazy file formats?
>
> Has anything else changed since you have upgraded to OSG 2.0?
>
> -----Original Message-----
> From: osg-users-bounces at lists.openscenegraph.org
> [mailto:osg-users-bounces at lists.openscenegraph.org] On Behalf Of Raymond de
> Vries
> Sent: Wednesday, September 19, 2007 10:09 AM
> To: OpenSceneGraph Users
> Subject: Re: [osg-users] 'loosing' textures?
>
> Hi Zach,
>
>
>> It sounds like your state sets are not being managed properly. Are you
>> doing any opengl state changes outside of OSG? If so, try removing them
>>
> and
>
>> see what happens.
>>
>>
> You mean that I do direct OpenGL calls, mixed with OSG, right? Nope, I
> am not doing that. Yes, I can imagine that that's tricky to do.
> Everything is single threaded, single rendering context.
>
> thnx
> Raymond
>
>
>> -----Original Message-----
>> From: osg-users-bounces at lists.openscenegraph.org
>> [mailto:osg-users-bounces at lists.openscenegraph.org] On Behalf Of Raymond
>>
> de
>
>> Vries
>> Sent: Wednesday, September 19, 2007 9:34 AM
>> To: OpenSceneGraph Users
>> Subject: Re: [osg-users] 'loosing' textures?
>>
>> Hi,
>>
>>
>>
>>> Glut is effectively only used for creating the rendering context at the
>>> moment. From there on I use this rendering context in the .net controls.
>>> Apart from that the usage is for historical reasons. I understand it
>>> sounds strange but the glut functionality that I use right now is very
>>> limited. And when I do use it, it is used as a kind of debugging window
>>> instead of het .net control.
>>>
>>> Rewriting the whole thing is not an option right now, and I don't need
>>> the full osgviewer functionality. I will try to use osg::GraphicsContext
>>> so that I can take a step in the right direction.
>>>
>>>
>>>
>> Ok, I guess this GraphicsContext is only to be used as part of the
>> osgviewer, so this is not an option for me right now.
>>
>> More info, maybe this rings a bell: the textures only disappear after a
>> few frames, when I use multiple windows (.net controls). Conceptually, I
>> don't have a clue what's going on, all the windows have a view on the
>> same scenegraph, using their own sceneview.
>>
>> thanks a lot for your time!
>> Raymond
>>
>>
>>
>>> best regards
>>> Raymond
>>>
>>>
>>> Robert Osfield wrote:
>>>
>>>
>>>
>>>> Hi Raymond,
>>>>
>>>> I am perplexed why you'd want to use GLUT for any multiple window
>>>> work. Why not just try the native windowing support.
>>>>
>>>> Robert.
>>>>
>>>> On 9/19/07, Raymond de Vries <reedev at xs4all.nl> wrote:
>>>>
>>>>
>>>>
>>>>
>>>>> Hi Robert,
>>>>>
>>>>> Sure, I did not provide information for the complete solution. At this
>>>>> moment I was hoping that someone else was triggered by this and he or
>>>>> she did some extensive research on this. Appearantly I did trigger ;-)
>>>>>
>>>>> I will describe my situation here in detail:
>>>>>
>>>>> * osg 2.0.0 on Windows XP SP2, 1 monitor
>>>>> * 1 main freeglut window = 1 rendering context. Shared contexts is
>>>>> enabled in freeglut since I intend to use only 1 rendering
>>>>>
> context
>
>>>>> in order to preserve resources. This window exists during the
>>>>> existence of the program and I hide it just after creation. I
>>>>> don't draw this window.
>>>>> * Multiple other windows, mixed glut and .net controls. In the .net
>>>>> control I create a so-called NativeWindow and get the current
>>>>> context. This way I get the context from my main window. These
>>>>> other windows and .net controls are created and deleted at
>>>>>
> runtime
>
>>>>> * Each 'other' window (ie not the main window) has its own
>>>>>
> sceneview
>
>>>>> * 1 scenegraph, assigned to each sceneview (setSceneData(node))
>>>>> * Each 'other' window has its own camera transformation
>>>>>
>>>>> Models are then loaded from file and added to the scenegraph. The
>>>>>
> effect
>
>>>>> that I see right now is that it seems that I am using multiple
>>>>>
> rendering
>
>>>>> contexts and that the texture of some parts of the models don't get
>>>>> uploaded to a particular rendering context. This is not the case
>>>>> however, I checked the contexts being made active and they are all the
>>>>> same. It looks like the models are only smooth shaded. Any clue?
>>>>>
>>>>> Is it possible that I need to set a specific rendering context to a
>>>>> sceneview?
>>>>>
>>>>> Thanks a lot (again)
>>>>> Raymond
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> Robert Osfield wrote:
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>> Hi Raymond,
>>>>>>
>>>>>> If its not clear to you then with this small amount of information is
>>>>>> going to be absolutely beyond comprehension for others...
>>>>>>
>>>>>> First up what type of application/viewer code do you have? Single
>>>>>> window, multiple cameras? What platform? Does it just happen with
>>>>>> certain types of hardware?
>>>>>>
>>>>>> Does osgviewer exhibit the same problems your data? Have you tried
>>>>>> disabling the optimizer?
>>>>>>
>>>>>> Robert.
>>>>>>
>>>>>> On 9/19/07, Raymond de Vries <reedev at xs4all.nl> wrote:
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>> Hi everyone,
>>>>>>>
>>>>>>> Since I have upgraded to OSG 2.0 (a few months ago) I seem to 'loose'
>>>>>>> textures on loaded models. It is not very clear to me what happens,
>>>>>>>
>>>>>>>
>> and
>>
>>
>>>>>>> it is not easy to describe. At the moment I was wondering if someone
>>>>>>>
>>>>>>>
>> has
>>
>>
>>>>>>> a hint or so.
>>>>>>>
>>>>>>> Thanks a lot,
>>>>>>> Raymond
>>>>>>>
>>>>>>> _______________________________________________
>>>>>>> osg-users mailing list
>>>>>>> osg-users at lists.openscenegraph.org
>>>>>>>
>>>>>>>
>>>>>>>
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>
>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>> _______________________________________________
>>>>>> osg-users mailing list
>>>>>> osg-users at lists.openscenegraph.org
>>>>>>
>>>>>>
>>>>>>
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>
>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>> _______________________________________________
>>>>> osg-users mailing list
>>>>> osg-users at lists.openscenegraph.org
>>>>>
>>>>>
>>>>>
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>
>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>> _______________________________________________
>>>> osg-users mailing list
>>>> osg-users at lists.openscenegraph.org
>>>>
>>>>
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
>>>>
>>>>
>>>>
>>>>
>>> _______________________________________________
>>> osg-users mailing list
>>> osg-users at lists.openscenegraph.org
>>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>>
>>>
>>>
>>>
>>>
>> _______________________________________________
>> osg-users mailing list
>> osg-users at lists.openscenegraph.org
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>
>> _______________________________________________
>> osg-users mailing list
>> osg-users at lists.openscenegraph.org
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>
>>
>>
>>
>
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
>
>
More information about the osg-users
mailing list