Yes. You can transfer course within three weeks of the academic year starting (if you want to change that particular academic year and not want to wait another academic year again) according to CUSU's website.
Depending on how much overlap there is for Civil and Mechanical in the first year, you MIGHT be able to change course later. I was on an MEng Electronics and CompSci course at Edinburgh, but I moved over to straight CompSci just before semester 1 finished and I was allowed to do this due to the large amount of overlap across the two degrees. But obviously Cardiff and Edinburgh are two different universities, so YMMV.