## who is worse 4 Static VB or 1 Dinamic VB ??

### who is worse 4 Static VB or 1 Dinamic VB ??

supose you  can manage to use only 1 dinamic Vertex buffer  or  to use 4 o 6
static vertex buffer what you  chose an why ?

--

Luis Duarte

### who is worse 4 Static VB or 1 Dinamic VB ??

Quote:> supose you  can manage to use only 1 dinamic Vertex buffer  or  to use 4 o
6
> static vertex buffer what you  chose an why ?

I would make my decision on whether the geoemtry was indeed static or if it
was dynamic.  Not based on the number that would be needed.

### who is worse 4 Static VB or 1 Dinamic VB ??

Quote:> supose you  can manage to use only 1 dinamic Vertex buffer  or  to use 4 o 6
> static vertex buffer what you  chose an why ?

If you explain why you think these are the choices you have, I may be
able to say what I think is preferable, and most likely show you that
you have other options.

Eyal

### who is worse 4 Static VB or 1 Dinamic VB ??

Ok

I have a bsp tree  and i use the vertices to create a static vb

and i have 5 meshes in anothers vbs

and my particles in another vbs

i can convine al the meshes and the particles in  a vb

but what do you think ?

Quote:> > supose you  can manage to use only 1 dinamic Vertex buffer  or  to use 4
o 6
> > static vertex buffer what you  chose an why ?

> If you explain why you think these are the choices you have, I may be
> able to say what I think is preferable, and most likely show you that
> you have other options.

> Eyal

### who is worse 4 Static VB or 1 Dinamic VB ??

I think it'd be good to follow Chronos3D's suggestion in this case.

Do you use the BSP to create the static VB every frame? If so, you
could use a dynamic VB for that, since there's no benefit in it being
static.

If on the other hand you're just generating an index buffer to the
vertices each frame, having them in a static buffer would be fine.

When your static data is really static (doesn't change each frame),
and the data that changes is in dynamic buffers, and assuming the same
vertex structure for all your geometry, you could make do with just
one static VB and one dynamic VB.

That said, you really should just do what will generate the most
readable code, unless you've identified a real performance bottleneck.

Eyal

> Ok

> I have a bsp tree  and i use the vertices to create a static vb

> and i have 5 meshes in anothers vbs

> and my particles in another vbs

> i can convine al the meshes and the particles in  a vb

> but what do you think ?

>>>supose you  can manage to use only 1 dinamic Vertex buffer  or  to use 4

> o 6

>>>static vertex buffer what you  chose an why ?

>>If you explain why you think these are the choices you have, I may be
>>able to say what I think is preferable, and most likely show you that
>>you have other options.

>>Eyal

### who is worse 4 Static VB or 1 Dinamic VB ??

So is not that bad to chage VB ?

> I think it'd be good to follow Chronos3D's suggestion in this case.

> Do you use the BSP to create the static VB every frame? If so, you
> could use a dynamic VB for that, since there's no benefit in it being
> static.

> If on the other hand you're just generating an index buffer to the
> vertices each frame, having them in a static buffer would be fine.

> When your static data is really static (doesn't change each frame),
> and the data that changes is in dynamic buffers, and assuming the same
> vertex structure for all your geometry, you could make do with just
> one static VB and one dynamic VB.

> That said, you really should just do what will generate the most
> readable code, unless you've identified a real performance bottleneck.

> Eyal

> > Ok

> > I have a bsp tree  and i use the vertices to create a static vb

> > and i have 5 meshes in anothers vbs

> > and my particles in another vbs

> > i can convine al the meshes and the particles in  a vb

> > but what do you think ?

> >>>supose you  can manage to use only 1 dinamic Vertex buffer  or  to use
4

> > o 6

> >>>static vertex buffer what you  chose an why ?

> >>If you explain why you think these are the choices you have, I may be
> >>able to say what I think is preferable, and most likely show you that
> >>you have other options.

> >>Eyal

### who is worse 4 Static VB or 1 Dinamic VB ??

It costs a little, but not *that* much. Texture changes are more
expensive, and if you're only dealing with a small number of objects
per frame, I don't think that the VB changes will take a significant
amount of time.

Eyal

> So is not that bad to chage VB ?

>>I think it'd be good to follow Chronos3D's suggestion in this case.

>>Do you use the BSP to create the static VB every frame? If so, you
>>could use a dynamic VB for that, since there's no benefit in it being
>>static.

>>If on the other hand you're just generating an index buffer to the
>>vertices each frame, having them in a static buffer would be fine.

>>When your static data is really static (doesn't change each frame),
>>and the data that changes is in dynamic buffers, and assuming the same
>>vertex structure for all your geometry, you could make do with just
>>one static VB and one dynamic VB.

>>That said, you really should just do what will generate the most
>>readable code, unless you've identified a real performance bottleneck.

>>Eyal

>>>Ok

>>>I have a bsp tree  and i use the vertices to create a static vb

>>>and i have 5 meshes in anothers vbs

>>>and my particles in another vbs

>>>i can convine al the meshes and the particles in  a vb

>>>but what do you think ?

>>>>>supose you  can manage to use only 1 dinamic Vertex buffer  or  to use

> 4

>>>o 6

>>>>>static vertex buffer what you  chose an why ?

>>>>If you explain why you think these are the choices you have, I may be
>>>>able to say what I think is preferable, and most likely show you that
>>>>you have other options.

>>>>Eyal

### who is worse 4 Static VB or 1 Dinamic VB ??

thanks

:)

> It costs a little, but not *that* much. Texture changes are more
> expensive, and if you're only dealing with a small number of objects
> per frame, I don't think that the VB changes will take a significant
> amount of time.

> Eyal

> > So is not that bad to chage VB ?

> >>I think it'd be good to follow Chronos3D's suggestion in this case.

> >>Do you use the BSP to create the static VB every frame? If so, you
> >>could use a dynamic VB for that, since there's no benefit in it being
> >>static.

> >>If on the other hand you're just generating an index buffer to the
> >>vertices each frame, having them in a static buffer would be fine.

> >>When your static data is really static (doesn't change each frame),
> >>and the data that changes is in dynamic buffers, and assuming the same
> >>vertex structure for all your geometry, you could make do with just
> >>one static VB and one dynamic VB.

> >>That said, you really should just do what will generate the most
> >>readable code, unless you've identified a real performance bottleneck.

> >>Eyal

> >>>Ok

> >>>I have a bsp tree  and i use the vertices to create a static vb

> >>>and i have 5 meshes in anothers vbs

> >>>and my particles in another vbs

> >>>i can convine al the meshes and the particles in  a vb

> >>>but what do you think ?

> >>>>>supose you  can manage to use only 1 dinamic Vertex buffer  or  to
use

> > 4

> >>>o 6

> >>>>>static vertex buffer what you  chose an why ?

> >>>>If you explain why you think these are the choices you have, I may be
> >>>>able to say what I think is preferable, and most likely show you that
> >>>>you have other options.

> >>>>Eyal

I had worked on colorizing at running time vertex for
color, keycolor and alpha effects.
What i'm doing is a sprite like rendering with square.
dynamicaly modifying my color verts is faster for me than
using tfactor (what i was not expected).
As the number of vert to modify for each object is 4
(square), setting tfactor for each object is necessary.
as each object may have its own alpha/color blending .it's
not possible to do it an other way.
so, doing tfactor is about 20-30% slower for me than lock-
unlock vb.
I expect that using tfactor is interesting if you have a
huge number of verts to colorize at one time.
the other point is that i'm in swvp rendering (voodoo3)
and maybe in hwvp it's different
anyone can comment?
thank
pb