iosswift3icarousel

How to change icarousel radius according to the screen size?


Hello I want to make half circle rotating wheel. So I used iCarousel for this. My problem is how to change the radius of the wheel according to the screen size.

These are my constraints. enter image description here

This red view is the iCarousel view enter image description here


Solution

  • There is an values iCarouselOptionRadius . This value definesradius of the Rotary, Cylinder and Wheel transforms .The radius of the Rotary, Cylinder and Wheel transforms in pixels/points. This is usually calculated so that the number of visible items exactly fits into the specified arc. You can manipulate this value to increase or reduce the item spacing (and the radius of the circle).

    I hope you equipped with all demos of iCarousel. Check the Options Demo for an example of the effect that iCarouselOption values parameters have. You can download complete demo from here.

    Hope it helps. Happy Coding!!