def __video_size(video_h, video_w, shortside):
    """
    Check the video size and return the new values to get the wanted
    video shortside
    :param video_h: Original video height
    :param video_w: Original video width
    :param shortside: shortside
    :return: New video height and width, and also a boolean telling if
    resize is necessary and proportion
    """
    por = 1.0
    resize = False
    if video_h != shortside or video_w != shortside:
        resize = True
        if video_h < video_w:
            por = float(shortside) / video_h
        else:
            por = float(shortside) / video_w
        video_h = int(video_h*por)
        video_w = int(video_w*por)

    return video_h, video_w, resize, por