The 28-year-old, who has signed until the end of the 2015 season, spent four seasons at the County Ground during which he took 118 first-class wickets at an average of 28.95 as well as Twenty20 scalps.
Brooks said: "I'm absolutely elated to be joining Yorkshire who are one of the biggest clubs in the country.
"They've shown a lot of interest in me over the last couple of years and it was ultimately too difficult to turn down. I want to be part of a successful young side that has been built at Headingley. Yorkshire enjoyed great success in 2012 and will certainly be challenging again next summer."
Martyn Moxon, Yorkshire's director of cricket, added: "We are really pleased to have acquired Jack's services. We've been looking to strengthen our squad to challenge in the First Division of the LV= County Championship in 2013 and believe that Jack brings a great deal of quality to our existing seam attack."