When I was building my cornetto, something I did was to develop a mathematical model for my instrument, somewhere between a perfectly conical and a cylindrical instrument, then I built the horn a little bit longer and measured the the frequency it produced, and use that to calibrate my model then I interpolated where I needed to cut to get the right length. It was remarkably close to the standard length. You could do this pretty easily with a trumpet, since you know the length of the various tubes and frequencies, IE you know the approximate length of the tubing in the the first valve adds a whole tone, you are going to need to remove about that(mind you not as much) from the whole horn to get the correct tone, however that isn't exact but you could play with the tuning slide to get an idea about how much you need to adjust it one way or the other. Ideally you have some slop in the tuning slide for the main tuning. Once you get that note tuned, you can work on the other slides, in theory these need to be more exact since you don't tune them, but they also will be easier to work with since you don't need to mess with the braces, so you could remove little be little until you get the slide tuned.