You can use "ImageMagick" to pixlate image..
class User < ActiveRecord::Base
has_attached_file :photo,
:styles => {
:thumb => "100x100#",
:small => "150x150>",
:medium => "200x200",
:pixlated => ['40x40#', 'png']},
:convert_options => {
:pixlated => '-scale 50% -scale 1000%'}
end
change scale % as per your need. You will get pixlated image. I hope it will help you.
for examlple: pixlated.png
original.png