Matrix-valued images gain increasing importance both as the output of new imaging techniques and as the result of image processing operations, bearing the need for robust and efficient filters for such images. Recently, a median filter for matrix-valued images has been introduced. We propose a new approach for the numerical computation of matrix-valued median filters, and closely related mid-range filters, based on sound convex programming techniques. Matrix-valued medians are uniquely computed as global optima with interior point solvers. The robust performance is validated with experimental results for matrixvalued data including texture analysis and denoising.