The J-PET detector being developed at the Jagiellonian University is a positron emission tomograph composed of the long strips of polymer scintillators. At the same time, it is a detector system that will be used for studies of the decays of positronium atoms. The shape of photomultiplier signals depends on the hit time and hit position of the gamma quantum. In order to take advantage of this fact, a dedicated sampling front-end electronics that enables to sample signals in voltage domain with the time precision of about 20 ps and novel reconstruction method based on the comparison of examined signal with the model signals stored in the library has been developed. As a measure of the similarity, we use the Mahalanobis distance. The achievable position and time resolution depend on the number and values of the threshold levels at which the signal is sampled. A reconstruction method as well as preliminary results are presented and discussed.