In this work, we present a novel approach to the bit allocation problem that aims to minimize overall distortion subject to a bit rate constraint. The optimal solution can be found by the Lagrangian method with dynamic programming. However, the optimal bit allocation for block-based interframe coding is practically unattainable because of the interframe dependency of macroblocks caused by motion compensation. To reduce the computational burden while maintaining a result close to the optimum, i.e., near optimum, we propose an alternative method. First, we present a partitioned form of the bit allocation problem: a "frame-level problem" and "one-frame macroblock-level problems." We show that the solution to this new form is also the solution to the conventional bit allocation problem. Further, we propose a bit allocation algorithm using a "two-phase optimization technique" with an interframe dependency model and a rate-distortion model.