private boolean hasScaleTypeDrawableAtIndex(int index) {
    DrawableParent parent = getParentDrawableAtIndex(index);
    return (parent instanceof ScaleTypeDrawable);
  }
Returns whether the given layer has a scale type drawable.
drawee/src/main/java/com/facebook/drawee/generic/GenericDraweeHierarchy.java