Well, they're both dangerous because the effects of the stimulant will mask the side effects of the depressant (heroin in your case) and the effects of the heroin will mask the effects of the stimulant.
Given that cocaine has a 1-2 hour duration of action (we're talking single dose here - shorter duration of action if you're going the IV route) and methamphetamine has a longer duration of action (again, depending on the ROA....but its still much longer than cocaine) - this is a tricky question.
If you were to mix heroin and methamphetamine at the same time...chances are the methamphetamine is going to be going strong when the heroin wears off. However, since you have a tolerance to stimulants...the duration could be shorter.
On the other hand, if you were to mix heroin and cocaine at the same time...chances are the heroin is going to last a bit longer than the cocaine.
As I mentioned before, the true danger of the speedball (and other "psuedo-speedballs") is that one drug counter-acts the side effects of the other drug, so many users end up taking more. A lot of speedball deaths (and overdoses) occur when the user consumes too much of a depressant (historically a "true speedball" is morphine and cocaine in the same needle - but since heroin is a morphine pro-drug...) because the stimulant is masking the fact that the user is actually overdosing on the depressant. Once the stimulant wears off, however, the overdose occurs. Contrary to popular belief, mixing uppers and downers (not just opiates and cocaine - I'm talking uppers and downers in general now) does not actually "pull your heart in two different directions".
Sorry this isn't just a cut-and-dry answer....