XNA 4.0 10k more draw different cube(not hardware instance)

Started by
8 comments, last by jinjin54321 11 years, 5 months ago
I'm using XNA 4.0 and I need 10k more draw cube(i don't need lighting and texture color.only just cube color).

I found hardware instance cube. But this is not possible. Because all cube is diffent.

how can many cube very fast draw ?



ps. current performance 1k cube(not texture image,only color) 15fps...-_-;
Advertisement
What's different about the cubes? Hardware instancing may still be possible.

Direct3D has need of instancing, but we do not. We have plenty of glVertexAttrib calls.

WIth hardware instancing, drawing some thousand cubes should be almost trivial, unless drawing the cubes eat take a lot of pixel fill rate.

What is the difference between each cube? Hardware instancing doesn't exclude differences with the objects, for example all the objects have typically a different transformation, so using the same idea, they can have different color for example, or even different texture.

Cheers!

  • all cubes size different . is possible hardware instance ?

all cubes size different . is possible hardware instance ?


Well size is something that you can express with the transformation matrix, and since all the cubes already need one to have different position and orientation, you'll just need to scale the transformation matrix to produce smaller and bigger cubes.

Cheers!

[quote name='jinjin54321' timestamp='1351429646' post='4994690']
all cubes size different . is possible hardware instance ?


Well size is something that you can express with the transformation matrix, and since all the cubes already need one to have different position and orientation, you'll just need to scale the transformation matrix to produce smaller and bigger cubes.

Cheers!
[/quote]

Thank you!!!!!!!!! ... Can I found example source?

[quote name='jinjin54321' timestamp='1351429646' post='4994690']
all cubes size different . is possible hardware instance ?


Well size is something that you can express with the transformation matrix, and since all the cubes already need one to have different position and orientation, you'll just need to scale the transformation matrix to produce smaller and bigger cubes.

Cheers!
[/quote]

Oh.. I real Want XNA 3D Candle Chart So..I Need Cube... Do you know Candle Chart? Candles Many different(Size...Up Down Candle..) .
Is this Possible Hardware Instance ?

http://www.online-stock-trading-guide.com/image-files/candlestick-chart-large.png

I want this style 3d chart... ..;; is this possible hardware instance?
Yes,

Googling "XNA 4.0 instancing" gives pretty good results for the described problem.

Cheers!
Yes, that kind of chart is possible to do with instancing. Just use non-uniform scaling. That is, scale more at the y/z-direction.

Cheers!

Yes, that kind of chart is possible to do with instancing. Just use non-uniform scaling. That is, scale more at the y/z-direction.

Cheers!


Oh!~ My God!~~~ Thank you!!!!!!! Thank you!!! Thank you!!!;;; biggrin.png

This topic is closed to new replies.

Advertisement