Local regime-switching models are a natural consequence of combining the concept of a local volatility model with that of a regime-switching model. However, even though Elliott et al. (2015) have derived a Dupire formula for a local regime-switching model, its calibration still remains a challenge, primarily due to the fact that the derived volatility function for each state involves all the state price variables whereas only one market price is available for model calibration, and a direct implementation of Elliott et al.'s formula may not yield stable results. In this paper, a closed system for option pricing and data extraction under the classical regime-switching model is proposed with a special approach, splitting one market price into two "market-implied state prices". The success of our approach hinges on the recovery of the two local volatility functions being transformed into an optimal control problem, which is solved through the Tikhonov regularization. In addition, an efficient algorithm is proposed to obtain the optimal solution by iteration. Our numerical experiments show that different shapes of local volatility functions can be accurately and stably recovered with the newly-proposed algorithm, and this algorithm also works quite well with real market data.