This paper proposes an efficient method for designing nearly perfect reconstruction (NPR) and perfect reconstruction (PR) cosine modulated filter banks (CMFBs) with prototype filters having an approximate cosine-rolloff (CR) transition band. It is shown that the flatness condition required for an NPR CMFB can be automatically satisfied by using a prototype filter with a CR transition band. The design problem is then formulated as a convex minimax optimization problem, and it can be solved by second-order cone programming (SOCP). By using the NPR CMFB so obtained as an initial guess to nonlinear optimizers such as Fmincon in Matlab, high-quality PR CMFBs can be obtained. The advantages of the proposed method are that it does not require a user-supplied initial guess of the prototype filter and bumps in the passband of the analysis filters can be effectively suppressed.