def rsc_nsew(rsc_data):
    """return tuple of (north, south, east, west) from rsc data"""

    north = rsc_data["y_first"]
    west = rsc_data["x_first"]
    east = west + rsc_data["width"] * rsc_data["x_step"]
    south = north + rsc_data["file_length"] * rsc_data["y_step"]
    return north, south, east, west