Re: [osg-users] Need help fixing my atmospheric transmission shader, it's so close to working!

2012-01-30 Thread Ethan Fahy
I should have mentioned before that only the red channel is of any importance; 
There is a viewer further down the pipeline that picks up the red channel 
values from the framebuffer so the green and blue channels don't matter at all. 
 I just set the green and blue channels to the red channel in case I ever want 
to use a different viewer and see things in grey-scale.

I tried to do a bit of research on GLSL texture binding but am very confused by 
it and not sure what I could change about my shader to fix binding issues.

I tried using this line:

Code:
vec4 color = texture2D(baseTexture, gl_TexCoord[0].st) + gl_Color;


thinking that by adding the texture color to the tree colors I might get the 
correct result.  This actually makes me see both the terrain texture and the 
tree colors.  This may then be the correct solution, but I'm not sure if it is 
really doing what I think it's doing...

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=45118#45118





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] Is it possible to get OpenGL calls as output from OSG?

2012-01-30 Thread Jesper D. Thomsen
Hi guys,

I have what may be a little bit of an unusual question regarding usage of 
OpenSceneGraph.
In our application we use OSG for drawing views of a dynamically created and 
animated model, which has so far worked out very well for us.
We are now in the situation where we would like to be able to interface with 
various CAD packages and be able to show our model inside them. A number of CAD 
packages support this by allowing plugins to render OpenGL calls within the 
host CAD programs viewports (so that the viewport can contain the combined 
contents of the plugin drawing and elements from the host CAD program).
I am wondering if I can somehow use our existing setup for generating these 
OpenGL calls directly from OSG. Would it somehow be possible to draw to a 
kind of OpenGL call buffer rather than directly to a drawing context from 
OpenSceneGraph. I guess that there's no code in OSG which can do this directly, 
but I was thinking that it might be possible to create a substitution for 
GraphicsWindow32 where I could catch the OpenGL calls being generated, and then 
transfer them to a plugin in the CAD program from there.
I do however see some possible issues where OSG is aware of the exact stage of 
the OpenGL setup, and I would somehow have to flush this when generating the 
OpenGL call stack.

Regards, and thanks in advance.

Jesper D. Thomsen
AnyBody Technology
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Is it possible to get OpenGL calls as output from OSG?

2012-01-30 Thread Tim Moore
On Mon, Jan 30, 2012 at 2:48 PM, Jesper D. Thomsen j...@anybodytech.com wrote:
 Hi guys,



 I have what may be a little bit of an unusual question regarding usage of
 OpenSceneGraph.
 In our application we use OSG for drawing views of a dynamically created and
 animated model, which has so far worked out very well for us.

 We are now in the situation where we would like to be able to interface with
 various CAD packages and be able to show our model inside them. A number of
 CAD packages support this by allowing plugins to render OpenGL calls within
 the host CAD programs viewports (so that the viewport can contain the
 combined contents of the plugin drawing and elements from the host CAD
 program).

 I am wondering if I can somehow use our existing setup for generating these
 OpenGL calls directly from OSG. Would it somehow be possible to “draw” to a

 kind of OpenGL call buffer rather than directly to a drawing context from
 OpenSceneGraph. I guess that there’s no code in OSG which can do this
 directly, but I was thinking that it might be possible to create a
 substitution for GraphicsWindow32 where I could catch the OpenGL calls being
 generated, and then transfer them to a plugin in the CAD program from there.
OSG makes OpenGL calls ;-) The issue is running OSG in a situation
where it is not in control of creating and managing the graphics
context. To get started, take a look at the examples like osgviewerSDL
that set up the viewer as an embedded window.

 I do however see some possible issues where OSG is aware of the exact stage
 of the OpenGL setup, and I would somehow have to flush this when generating
 the OpenGL call stack.
Yes, that is the issue. It can be done with some careful use of
callbacks in the scene graph. In your situation, you need to be
careful to be in the expected state when OSG rendering starts, and
leave it in the state expected by the CAD program when OSG finishes
up.

Tim



 Regards, and thanks in advance.



 Jesper D. Thomsen

 AnyBody Technology


 ___
 osg-users mailing list
 osg-users@lists.openscenegraph.org
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] Is it possible to get OpenGL calls as output from OSG?

2012-01-30 Thread Sergey Kurdakov
Hi

it is possible to achieve this in following way:

render to FBO camera on provided by CAD context ( set main camera as FBO ),
get texture ( there are ways to make it clean, but I just stole texture id
from within inside OSG ) and apply it onto OpenGL quad
I achieved rendering in Blender with OSG, but so that it worked I used only
one threaded model.

Regards
Sergey
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Is it possible to get OpenGL calls as output from OSG?

2012-01-30 Thread Chris 'Xenon' Hanson
On 1/30/2012 7:49 AM, Sergey Kurdakov wrote:
 render to FBO camera on provided by CAD context ( set main camera as FBO ), 
 get texture (
 there are ways to make it clean, but I just stole texture id from within 
 inside OSG ) and
 apply it onto OpenGL quad
 I achieved rendering in Blender with OSG, but so that it worked I used only 
 one threaded
 model.

  I've done this too, only using a context cloned and shared from the original 
one
provided by the host app. Then you just rasterize OSG's texture within the host 
app.

 Regards
 Sergey

-- 
Chris 'Xenon' Hanson, omo sanza lettere. xe...@alphapixel.com 
http://www.alphapixel.com/
  Digital Imaging. OpenGL. Scene Graphs. GIS. GPS. Training. Consulting. 
Contracting.
There is no Truth. There is only Perception. To Perceive is to Exist. - 
Xen
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Need help fixing my atmospheric transmission shader, it's so close to working!

2012-01-30 Thread Sergey Polischuk
Only your terrain have texture and for your trees - function call 
texture2D(baseTexture, gl_TexCoord[0].st) return black (0,0,0,1). Your trees 
have per-vertex color attribute, and your ground dont(?) (i dont know to what 
value it defaults). Simplest options to fix this - set 1x1 white texture to 
your trees or add color array to ground (with black color values) and use 
texture2D(baseTexture, gl_TexCoord[0].st) + gl_Color, or write different 
shaders (one version with texture, one without). If gl_Color defaults to black 
without color array, you can use vec4 color = texture2D(baseTexture, 
gl_TexCoord[0].st) + gl_Color; without any changes.

30.01.2012, 17:30, Ethan Fahy ethanf...@gmail.com:
 I should have mentioned before that only the red channel is of any 
 importance; There is a viewer further down the pipeline that picks up the red 
 channel values from the framebuffer so the green and blue channels don't 
 matter at all.  I just set the green and blue channels to the red channel in 
 case I ever want to use a different viewer and see things in grey-scale.

 I tried to do a bit of research on GLSL texture binding but am very confused 
 by it and not sure what I could change about my shader to fix binding issues.

 I tried using this line:

 Code:
 vec4 color = texture2D(baseTexture, gl_TexCoord[0].st) + gl_Color;

 thinking that by adding the texture color to the tree colors I might get the 
 correct result.  This actually makes me see both the terrain texture and the 
 tree colors.  This may then be the correct solution, but I'm not sure if it 
 is really doing what I think it's doing...

 --
 Read this topic online here:
 http://forum.openscenegraph.org/viewtopic.php?p=45118#45118

 ___
 osg-users mailing list
 osg-users@lists.openscenegraph.org
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Is a render to texture master camera critical?

2012-01-30 Thread Riccardo Corsi
Hi all,

I've tried  to use the main camera as RTT in several applications and it
works for me as well.
But I'd like to ask a couple of questions on the post process passes
instead:
- is there any conceptual difference between using the final ortho camera
as a in-graph POST_RENDER or as a viewer's slave one?
- if using multiple post process passes, is it a good solution to add all
of the post cameras as children of a group with TraversalOrderBin, to
obtain a specific rendering order? Does this work correctly with all the
threading models?  Or is it better to explicitly assign to each camera its
render order via setRenderOrder()?

Thank you.
Ricky



On Fri, Jan 27, 2012 at 11:40, Tim Moore timoor...@gmail.com wrote:

 2012/1/17 Martin Großer grosser.mar...@gmx.de:
  Hello all,
 
  A few weeks ago, I want to render my scene into a texture, which I want
 to use in the final rendering on a screen aligned quad. My first problem
 was I lost the shadows, because view dependent shadow techniques don't work
 with nested cameras. So I used a RTT slave camera. Now my Callbacks don't
 work, because they don't work with slave cameras (no update visistors for
 slave scene graphs). So now my rtt camera is the master camera and my ortho
 camera for the quad is a nested camera (see the
 render_to_texture_scene_graph.png). It looks fine, but I am not sure
 whether it is a good idea.
 
  There are any special explanatory notes for me? Is it a good or bad
 scene graph pattern for my use case?
 A couple of points:
 The default for a slave camera is to use the master camera's scene
 graph. In that case you don't need to worry about callbacks in the
 main scene graph.

 You can install an UpdateSlaveCallback if you really need it. See osg/View.

 If you set up your windows and contexts explicitly and assign them to
 slave cameras before calling Viewer::realize() or Viewer::run(), then
 the master camera will not be given a graphics context and won't be
 used for rendering. The manipulators will still update the master and
 Its view and projection matrices will be used to control the slave
 cameras if desired.

 When I play with RTT, I like to open the window and set up the
 graphics context with GraphicsContext::createGraphicsContext(), then
 assign that to the slave cameras that render the scene graph and
 display the rendered texture on the screen. I don't put the RTT camera
 in the scene graph.

 Tim
 
  Cheers
 
  Martin
  --
  Empfehlen Sie GMX DSL Ihren Freunden und Bekannten und wir
  belohnen Sie mit bis zu 50,- Euro! https://freundschaftswerbung.gmx.de
 
  ___
  osg-users mailing list
  osg-users@lists.openscenegraph.org
 
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
 
 ___
 osg-users mailing list
 osg-users@lists.openscenegraph.org
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] Help: many cameras are rendering at the same time or one by one?

2012-01-30 Thread wang shuiying

Hello,

My question might be silly, but I really want to know about that.

I wonder if there are many cameras (one main camera + many pre render 
cameras), will OSG (or grahic hardware) manage to make these cameras 
render one by one or  at the same time?


I have a programm concerning leveraging GPU parallelism capability, but 
I include many pre render cameras in it. So I would like to know how 
these cameras are managed.


Thank you in advance!

Shuiying


___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] [3rdparty] Maintaining osgWidget Window aspect ratio on resize

2012-01-30 Thread Adam Bruce
Hi,

I'm starting to use osgWidget to create a GUI in a GraphicsWindowWX and  am 
attempting to figure out how to best get an osgWidget Window to maintain a 
defined aspect ratio on window resize. It appears that it's not possible to do 
this through subclassing as the only virtual functions are intended to handle 
internal redrawing internal widgets. I'm currently only using precompiled 
binaries and so would rather look for a quicker solution over setting up the 
proper build environment to build from source. Is this possible with osgWidget 
out of the box?

Thanks,
Adam

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=45126#45126





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] FOV

2012-01-30 Thread Shaheed Khan
Hi,
Thanks chris .. em able to zoom using getProjectionMatrixAsPerspective and 
setProjectionMatrixAsPerspective fuctions

Actually em trying this view for LDP instead of Aircraft and i want to make my 
view as entire black screen (instead of Runway) during initialization until i 
select some modes 

Wat parameters in which function should i set to get black screen 

Any suggestion plz share :|

... 

Thank you!

Cheers,
Shaheed

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=45127#45127





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] FOV

2012-01-30 Thread Chris 'Xenon' Hanson
On 1/30/2012 12:25 PM, Shaheed Khan wrote:
 Actually em trying this view for LDP instead of Aircraft and i want to make 
 my view as entire black screen (instead of Runway) during initialization 
 until i select some modes 
 Wat parameters in which function should i set to get black screen 

  You could probably set the clear color to black and just set the Nodemask of 
your
top-level node to 0.

-- 
Chris 'Xenon' Hanson, omo sanza lettere. xe...@alphapixel.com 
http://www.alphapixel.com/
  Digital Imaging. OpenGL. Scene Graphs. GIS. GPS. Training. Consulting. 
Contracting.
There is no Truth. There is only Perception. To Perceive is to Exist. - 
Xen
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] Getting osgWidget::Window to maintain aspect ratio on graphics context resize

2012-01-30 Thread Adam Bruce
Hi,

First off, I accidentally created this topic initially in the 3rd Party 
subforum and can't seem to delete it on my own.

I'm starting to use osgWidget to create some basic GUI elements in a 
GraphicsWindowWX and am attempting to figure out how to best get an osgWidget 
Window to maintain a defined aspect ratio on window resize. It appears that 
it's not possible to do this through subclassing as the only virtual functions 
are intended to handle redrawing internal widgets. I'm currently only using 
precompiled binaries and so would rather look for a quicker solution over 
setting up the proper build environment to build from source and modify 
osgWidget::Window. Is this possible with osgWidget out of the box? Or, 
alternately, are there any 2D GUI libraries that can be integrated with OSG 
that can easily interface with osg::Texture classes?

Thanks,
Adam

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=45129#45129





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Help: many cameras are rendering at the same time or one by one?

2012-01-30 Thread Chris 'Xenon' Hanson
On 1/30/2012 12:27 PM, wang shuiying wrote:
 I wonder if there are many cameras (one main camera + many pre render 
 cameras), will OSG
 (or grahic hardware) manage to make these cameras render one by one or  at 
 the same time?
 I have a programm concerning leveraging GPU parallelism capability, but I 
 include many pre
 render cameras in it. So I would like to know how these cameras are managed.

  I believe this is determined by osgViewer's threading model:

CullDrawThreadPerContext
CullThreadPerCameraDrawThreadPerContext
DrawThreadPerContext
SingleThreaded

etc.

 Thank you in advance!
 Shuiying


-- 
Chris 'Xenon' Hanson, omo sanza lettere. xe...@alphapixel.com 
http://www.alphapixel.com/
  Digital Imaging. OpenGL. Scene Graphs. GIS. GPS. Training. Consulting. 
Contracting.
There is no Truth. There is only Perception. To Perceive is to Exist. - 
Xen
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] osgViewer::GraphicsWindowCocoa::WindowData dynamic_cast returns 0

2012-01-30 Thread Sean Sullivan
Looks like my own project had both of those flags set to true. Setting them to 
false cleared it up.

Thanks,
Sean


sth wrote:
 Hi Sean,
 
 
 I had similar problems in the past as you and Chuck. My fix was to make
 sure the project-settings for osg and my own project where the same and
 set to FALSE:
 
 Symbols hidden by default (GCC_SYMBOLS_PRIVATE_EXTERN): FALSE
 
 and eventually
 
 Inline hidden methods (GCC_INLINES_ARE_PRIVATE_EXTERN): FALSE
 
 Cheers,
 
 Stephan
 
 Am 27.01.12 18:11, schrieb Sean Sullivan:
 
  Hey guys,
  
  I'm trying to pass an osgViewer::GraphicsWindowCocoa::WindowData to my 
  traits object with CreateOnlyView specified. For some reason whenever my 
  WindowData is dynamic_cast in GraphicsWindowCocoa.mm it just returns 0. If 
  I switch them to static_cast they work.
  
  Here's my code:
  
  
  Code:
  // OSGWindow.h
  osgViewer::GraphicsWindowCocoa::WindowData* windowData;
  
  // OSGWindow.cpp
  windowData = new osgViewer::GraphicsWindowCocoa::WindowData 
  (osgViewer::GraphicsWindowCocoa::WindowData::CreateOnlyView);
  
  osg::ref_ptrosg::GraphicsContext::Traits traits = new 
  osg::GraphicsContext::Traits();
  
  traits-x = 100;
  traits-y = 100;
  traits-width = 1280;
  traits-height = 720;
  traits-red = 8;
  traits-blue = 8;
  traits-green = 8;
  traits-alpha = 8;
  traits-depth = 24;
  traits-windowDecoration = false;
  traits-doubleBuffer = true;
  traits-vsync = false;
  traits-stencil = 1;
  traits-samples = 8;
  traits-sampleBuffers = 1;
  traits-inheritedWindowData = windowData;
  
  osg::ref_ptrosg::GraphicsContext context = 
  osg::GraphicsContext::createGraphicsContext (traits.get());
  
  
  
  This is what's in GraphicsWindowCocoa.mm that returns 0:
  
  
  Code:
  GraphicsWindowCocoa::WindowData* windowData = traits-inheritedWindowData ? 
  dynamic_castGraphicsWindowCocoa::WindowData*(traits-inheritedWindowData.get())
   : NULL;
  
  
  
  I tried expanding it into if statements and the traits-inheritedWindowData 
  returns true. I also tried copying and pasting this line into my file where 
  I create my traits object and it returns properly.
  
  Any ideas?
  
  Cheers,
  Sean
  
  --
  Read this topic online here:
  http://forum.openscenegraph.org/viewtopic.php?p=45082#45082
  
  
  
  
  
  ___
  osg-users mailing list
  
  http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
  
 
 ___
 osg-users mailing list
 
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
 
  --
 Post generated by Mail2Forum


--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=45130#45130





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] Best usage of function: return ref_ptr or standard ptr?

2012-01-30 Thread Juan Herrera
Hi,

I have a function which I want to return a group, with two alternatives:


Code:

osg::ref_ptr osg::Group  returnGroup()
{
osg::ref_ptr  osg::Group  group = new osg::Group;
...
return group;
}





Code:

osg::Group * returnGroup()
{
osg::Group * group = new osg::Group;
...
return group;
}




Which usage is better if garbage collection is desired?

Thank you!

Cheers,
Juan

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=45134#45134





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Best usage of function: return ref_ptr or standard ptr?

2012-01-30 Thread Kim Bale
Hi Juan,

Returning a reference counted pointer is in general the safest thing to do
as it ensures that the object will get deleted when it goes out of scope.

A quick search of the osg-users will reveal a number of threads on the
subject alternatively try the link below:

http://andesengineering.com/OSG_ProducerArticles/RefPointers/RefPointers.html

K.



On 30 January 2012 21:45, Juan Herrera juan...@gmail.com wrote:

 Hi,

 I have a function which I want to return a group, with two alternatives:


 Code:

 osg::ref_ptr osg::Group  returnGroup()
 {
 osg::ref_ptr  osg::Group  group = new osg::Group;
 ...
 return group;
 }





 Code:

 osg::Group * returnGroup()
 {
 osg::Group * group = new osg::Group;
 ...
 return group;
 }




 Which usage is better if garbage collection is desired?

 Thank you!

 Cheers,
 Juan

 --
 Read this topic online here:
 http://forum.openscenegraph.org/viewtopic.php?p=45134#45134





 ___
 osg-users mailing list
 osg-users@lists.openscenegraph.org
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] Array of geometries

2012-01-30 Thread Juan Herrera
Hi,

I need to create an array of geometries. I'm not sure whether to use:


Code:

osg::Geometry** tube;
ref_ptr  ref_ptr  Geometry   tube;
ref_ptr  Geometry  * tube;




I want then to allocate the tube Geometry array as something like:

Code:

tube = new Geometry[pointList-size() - 1];




Thank you!

Cheers,
Juan

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=45136#45136





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Best usage of function: return ref_ptr or standard ptr?

2012-01-30 Thread Philipp Moeller
Juan Herrera juan...@gmail.com writes:

 Hi,

 I have a function which I want to return a group, with two alternatives:


 Code:

 osg::ref_ptr osg::Group  returnGroup()
 {
 osg::ref_ptr  osg::Group  group = new osg::Group;
 ...
 return group;
 }





 Code:

 osg::Group * returnGroup()
 {
 osg::Group * group = new osg::Group;
 ...
 return group;
 }




 Which usage is better if garbage collection is desired?

There is no garbage collection in osg. Objects are deleted through
reference counting, but that is probably what you mean.

I'd go with the second style if nothing in returnGroup stores the
pointer. It is certainly safe, if the pointer is assigned to a ref_ptr
in another object. In general, use ref_ptr when you need to store
something for a longer duration and a plain pointer for short-lived
access and creation.

Cheers,
Philipp



 Thank you!

 Cheers,
 Juan

 --
 Read this topic online here:
 http://forum.openscenegraph.org/viewtopic.php?p=45134#45134





 ___
 osg-users mailing list
 osg-users@lists.openscenegraph.org
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Array of geometries

2012-01-30 Thread Sergey Polischuk
Hi

std::vectorosg::ref_ptrosg::Geometry 

31.01.2012, 02:18, Juan Herrera juan...@gmail.com:
 Hi,

 I need to create an array of geometries. I'm not sure whether to use:

 Code:

 osg::Geometry** tube;
 ref_ptr  ref_ptr  Geometry   tube;
 ref_ptr  Geometry  * tube;

 I want then to allocate the tube Geometry array as something like:

 Code:

 tube = new Geometry[pointList-size() - 1];

 Thank you!

 Cheers,
 Juan

 --
 Read this topic online here:
 http://forum.openscenegraph.org/viewtopic.php?p=45136#45136

 ___
 osg-users mailing list
 osg-users@lists.openscenegraph.org
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Help: many cameras are rendering at the same time or one by one?

2012-01-30 Thread Sergey Polischuk
Hi
If you have one graphics device and one graphics context - all cameras rendered 
one by one (i mean actual draw calls)

30.01.2012, 23:27, wang shuiying shuiying.w...@fu-berlin.de:
 Hello,

 My question might be silly, but I really want to know about that.

 I wonder if there are many cameras (one main camera + many pre render
 cameras), will OSG (or grahic hardware) manage to make these cameras
 render one by one or  at the same time?

 I have a programm concerning leveraging GPU parallelism capability, but
 I include many pre render cameras in it. So I would like to know how
 these cameras are managed.

 Thank you in advance!

 Shuiying

 ___
 osg-users mailing list
 osg-users@lists.openscenegraph.org
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] osgmaxexp problems

2012-01-30 Thread Seppo
Hi Farshid,

 

Yes, when 3ds max starts up it gives this error. Could it be since I also
use newer OSG version than what was with the current stable release of
osgmaxexp (1.0.1)? I have copied the corresponding dll files there too so it
is not atleast missing any dll files, but I am not sure if that causes the
problem anyway.

 

Thanks,

-Seppo

 

From: osg-users-boun...@lists.openscenegraph.org
[mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Farshid
Lashkari
Sent: 26. tammikuuta 2012 20:02
To: OpenSceneGraph Users
Subject: Re: [osg-users] osgmaxexp problems

 

Hi Seppo,

On Tue, Jan 24, 2012 at 12:37 AM, Seppo se...@kuutio.net wrote:

I have compiled osgmaxexp svn rev 236 without problems, but when using that
I get this error when running 3DS max 2012 (32bit version):

DLL (OSGEXP.dle) failed to initialize. Error code 998 - Invalid access to
memory location.

 

 Are you getting this error when 3ds max starts up or when you try to
export?

 

Cheers,

Farshid

 

 

 


___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

 

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] OSG website error

2012-01-30 Thread Christian Schulte

Hello everyone,

from France I receive following response trying to log to 
www.openscenegraph.org :


Traceback (most recent call last):
  File /usr/lib/python2.5/site-packages/trac/web/api.py, line 339, in 
send_error
'text/html')
  File /usr/lib/python2.5/site-packages/trac/web/chrome.py, line 684, in 
render_template
data = self.populate_data(req, data)
  File /usr/lib/python2.5/site-packages/trac/web/chrome.py, line 592, in 
populate_data
d['chrome'].update(req.chrome)
  File /usr/lib/python2.5/site-packages/trac/web/api.py, line 168, in 
__getattr__
value = self.callbacks[name](self)
  File /usr/lib/python2.5/site-packages/trac/web/chrome.py, line 460, in 
prepare_request
for category, name, text in contributor.get_navigation_items(req):
  File 
/usr/lib/python2.5/site-packages/trac/versioncontrol/web_ui/browser.py, line 
295, in get_navigation_items
if 'BROWSER_VIEW' in req.perm:
  File /usr/lib/python2.5/site-packages/trac/perm.py, line 523, in 
has_permission
return self._has_permission(action, resource)
  File /usr/lib/python2.5/site-packages/trac/perm.py, line 537, in 
_has_permission
check_permission(action, perm.username, resource, perm)
  File /usr/lib/python2.5/site-packages/trac/perm.py, line 424, in 
check_permission
perm)
  File /usr/lib/python2.5/site-packages/trac/perm.py, line 282, in 
check_permission
get_user_permissions(username)
  File /usr/lib/python2.5/site-packages/trac/perm.py, line 357, in 
get_user_permissions
for perm in self.store.get_user_permissions(username):
  File /usr/lib/python2.5/site-packages/trac/perm.py, line 175, in 
get_user_permissions
cursor.execute(SELECT username,action FROM permission)
  File /usr/lib/python2.5/site-packages/trac/db/util.py, line 51, in execute
return self.cursor.execute(sql)
  File /usr/lib/python2.5/site-packages/trac/db/sqlite_backend.py, line 58, 
in execute
args or [])
  File /usr/lib/python2.5/site-packages/trac/db/sqlite_backend.py, line 50, 
in _rollback_on_error
return function(self, *args, **kwargs)
OperationalError: database is locked

Does anyone experience the same behaviour ?

Christian
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org