I answer my own question, so it serves other in the same case.
The detection depends on the network. Typically, in French's operator Free, the network does not disconnect you on call rejection (but let you hear a ring tone instead). In Germany, it does. So I think the behaviour of the French network is wrong, or at least not helpful.
There is nothing specific in GSM/3GPP standard for detecting a ring tone, so the only way to go for such network is to perform detection programmatically. It can be done "simply" by checking the time distance between similar "sound" value. The algorithm is something like this:
int range = 5, value = 350, periodFound = 0; // Arbitrary
int period[16] = {};
void onDataReceived(int sampleRate, short * data, int len)
{
for (int i = 0; i < len; i++)
{
if (data[i] >= value - range && data[i] <= value + range)
{
period[periodFound++] = i;
}
if (periodFound == 16) break;
}
// Compute distance between periods (if it's the same, it's a ring tone)
float avg = 0, dev = 0;
int prev = period[0];
for (int i = 1; i < periodFound; i++)
{
avg += (period[i] - prev);
prev = period[i];
}
avg /= periodFound-1;
prev = period[0];
for (int i = 1; i < periodFound; i++)
{
dev += (period[i] - prev - avg) * (period[i] - prev - avg);
prev = period[i]
}
// Last test
if (fabs(avg - expectedPeriod) < range && dev < errorAllowed)
printf("Ring tone!");
}