added variable stream count