Hi Arelien,
On 24 October 2013 15:11, Aurelien Albert wrote:
> Will this works with shared contexts ?
>
Shared context will have the same ContextID's but they will have seperate
osg::State and osg::GraphicsContexts, as well as seperate CullVisitor etc.
You can use an internal map for any of the
Hi Robert,
> The CullVisitor::getRenderInfo() method could be used to access to the
> osg::State object and hence ContextID that is relevant to the current cull
> traversal.
Will this works with shared contexts ?
Thank you!
Cheers,
Aurelien
--
Read this topic online here:
On 24 October 2013 14:41, Glenn Waldron wrote:
> Well, Paul did ask for per-context uniforms. But re-reading the original
> post, it's evident that the GC ID is not available during cull anyway ...
> so scratch that idea :)
>
The CullVisitor::getRenderInfo() method could be used to access to the
Well, Paul did ask for per-context uniforms. But re-reading the original
post, it's evident that the GC ID is not available during cull anyway ...
so scratch that idea :)
Glenn Waldron / @glennwaldron
On Thu, Oct 24, 2013 at 9:14 AM, Aurelien Albert <
aurelien.alb...@alyotech.fr> wrote:
> Hi,
Hi,
> And then index that by the GC ID if it's available through the
> cv->getCurrentCamera().
That's a bit different for my solution :
- in my idea, you get "per-view" uniforms : even if multiple views runs with
the same graphics context, you still have different uniforms
- in your idea, y
Another idea would be a subclass of Uniform (MultiplexingUniform?) that you
can program per context.
Or, a variation on Aurelien's approach would be to use:
osg::buffered_object> multiUniform;
And then index that by the GC ID if it's available through the
cv->getCurrentCamera(). This would be
Hi,
At cull traversal, I do the following (this is pseudo-code!) :
Code:
cullTraversal(pCullVisitor)
{
// Get per-view-data
perViewData = getOrCreatePerViewData(pCullVisitor);
// Compute "dynamic" uniforms
perViewData.pDynamicUniform_1->set(value);
perViewData.pDynamicUnifor
Hi,
I am also interesting in this topic.
How do you push 'dynamic" Uniforms at cull traversal ? Does it work well of
multi-threading is activated ?
Cheers,
Gaëtan
2013/10/24 Aurelien Albert
> Hi,
>
>
> > If you have just a single uniform value per context then I'd simply
> place the Uniform
Hi,
> If you have just a single uniform value per context then I'd simply place the
> Uniform on the each if the viiewer's osg::Camera's StateSet, such that each
> Camera assigned to each Context gets it's own state inherited down including
> the Uniform.
> Some nodes have a cull callback.
Hi,
We have to manage some similar problems. We have different shaders and
different uniforms in the same
scene graph.
Some nodes have a cull callback. During the cull traversal, the callback
identify the current view/context
and push the corresponding state set in the render graph, traverse
HI Paul,
If you have just a single uniform value per context then I'd simply place
the Uniform on the each if the viiewer's osg::Camera's StateSet, such that
each Camera assigned to each Context gets it's own state inherited down
including the Uniform.
If you want to put a vector of Uniform in th
Hi all -- I've been inactive with OSG lately, but from time to time get
called back. Given my lack of recent experience, I would appreciate your
help with this issue.
I have a multicontext/multidisplay app that needs to compute a uniform
during cull, and it will have a different value for each con
12 matches
Mail list logo