Record video and sound with backtrack
This is really the same trick as what is needed for a music video.  There are two options for it.  If you want to record the actual performance, play the backtrack while recording the video and synchronize it after the fact.  You can either directly mic the instrument and play the backtrack aloud or you can use headphones or in-ear monitors to play the backtrack and split off a feed to go in to the camera for purposes of synchronization.

Alternately, you can do your audio recording completely separate from the video.  Record the audio in an ideal studio environment with clean trumpet while using headphones for the backtrack, produce the final audio and then playback the audio while recording the video.  This is the option that is generally closer to what a music video does and is what I would personally recommend for best overall quality.

In either case, you take the video track and the audio track (or tracks) and line them up after the fact in a traditional video NLE (non-linear editor).  You could accomplish it with something as basic as Windows Movie Maker, though personally, I'd use something like Adobe Premiere and maybe Audition for the audio (simply because Audition and Premiere integrate so nicely.)