Other possibilities are:
rotcw2 = Reverse/*Transpose;
rotccw2 = Transpose/*Reverse;
rotcw3[x_]:=Transpose[Reverse[x]]
rotccw3[x_]:= Reverse[Transpose[x]]
rotcw4 = Transpose[Reverse[#]]&
rotccw4 = Reverse[Transpose[#]]&
rotcw5 = (Reverse /@ Transpose[#])&
rotccw5 = (Transpose[Reverse /@ #])&
Or using Table:
Table[a[[dimx - j + 1, i]], {i, dimy}, {j, dimx}] // MatrixForm
Table[a[[j, dimy - i + 1]], {i, dimy}, {j, dimx}] // MatrixForm
You can probably also use SparseArray or MapIndexed... There are many many ways of doing this, it just depends on what you feel most comfortable using... @* or /* or /@ or #...& might seem intimidating for some people...