A 3D T-mesh is generally a cuboid grid which allows hanging vertices. Here, a hanging vertex is an interior vertex, but it is not a corner point of eight cells. Spline function spaces with high order smoothness over 3D T-meshes have great application prospect due to their local refinement and relatively low degrees of freedom, for example, 3D isogeometric analysis and implicit representation of surfaces. However, there are still no available dimension formulae of those kinds of spline spaces for application. In this paper, we explore the dimensions of trivariate quadratic spline spaces with