Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: How to draw a *single* vertex ?  (Read 14830 times)

0 Members and 1 Guest are viewing this topic.

ThomasAn.

  • Newbie
  • *
  • Posts: 18
    • View Profile
Re: How to draw a *single* vertex ?
« Reply #15 on: May 28, 2013, 09:10:05 pm »
That means I would have to waste a vertex array per shape; instead of a vertex array for the WHOLE system. Using more vertices per particle would kill performance. No? (both in number of vertices and multiple draw calls)

Or, it would have to be a vertex array of quads (is this even possible; vertex array or vertex arrays) ? And each quad having a circle texture assigned to it ? (even this already quadruples the computational load)

Can all these shapes be drawn in sfml with a single call to window.draw ?
« Last Edit: May 28, 2013, 09:24:36 pm by ThomasAn. »

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: How to draw a *single* vertex ?
« Reply #16 on: May 28, 2013, 10:09:09 pm »
Yes of course, a single vertex array can contain multiple shapes. A single vertex array containing textured quads is the way to go for what you want to do.
Laurent Gomila - SFML developer

ThomasAn.

  • Newbie
  • *
  • Posts: 18
    • View Profile
Re: How to draw a *single* vertex ?
« Reply #17 on: May 28, 2013, 11:20:45 pm »
Thank you.
I will look into that approach and adjust accordingly.