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

Author Topic: Just a question.  (Read 1331 times)

0 Members and 1 Guest are viewing this topic.

Lolilolight

  • Hero Member
  • *****
  • Posts: 1232
    • View Profile
Just a question.
« on: April 03, 2014, 09:08:12 pm »
I've a question, why you pretransform vertices only when their size is 4 or less ?


zsbzsb

  • Hero Member
  • *****
  • Posts: 1409
  • Active Maintainer of CSFML/SFML.NET
    • View Profile
    • My little corner...
    • Email
Re: Just a question.
« Reply #1 on: April 03, 2014, 09:08:58 pm »
How can a vertice which is a single point have a size?
Motion / MotionNET - Complete video / audio playback for SFML / SFML.NET

NetEXT - An SFML.NET Extension Library based on Thor

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Just a question.
« Reply #2 on: April 03, 2014, 10:37:22 pm »
Because it's the GPU's job to transform vertices. But when you have very few vertices to transform (<= 4 so I handle sprites) before changing the modelview matrix, it's sometimes more efficient to transform on the CPU and avoid changing the modelview matrix so often.
Laurent Gomila - SFML developer

Lolilolight

  • Hero Member
  • *****
  • Posts: 1232
    • View Profile
Re: Just a question.
« Reply #3 on: April 04, 2014, 07:33:33 pm »
Ok thanks for your answer. :)


 

anything