How to update the segments of a BufferGeometry?

I would use shaders for that purpose.