Centrality, which quantifies the importance of individual nodes, is among the most essential concepts in modern network theory. As there are many ways in which a node can be important, many different centrality measures are in use. Here, we concentrate on versions of the common betweenness and closeness centralities. The former measures the fraction of paths between pairs of nodes that go through a given node, while the latter measures an average inverse distance between a particular node and all other nodes. Both centralities only consider shortest paths (i.e., geodesics) between pairs of nodes. Here we develop a method, based on absorbing Markov chains, that enables us to continuously interpolate both of these centrality measures away from the geodesic limit and toward a limit where no restriction is placed on the length of the paths the walkers can explore. At this second limit, the interpolated betweenness and closeness centralities reduce, respectively, to the well-known current-betweenness and resistance-closeness (information) centralities. The method is tested numerically on four real networks, revealing complex changes in node centrality rankings with respect to the value of the interpolation parameter. Nonmonotonic betweenness behaviors are found to characterize nodes that lie close to intercommunity boundaries in the studied networks.