autologin in wordpress when loged in non wp-site

Not tested, but try to do a post request via ajax. The file you call via ajax should look something like this:

require( dirname(__FILE__) . '/wp-load.php' );
$user = filter_input( INPUT_POST, FILTER_SANITIZE_STRING );
$pass = filter_input( INPUT_POST, FILTER_SANITIZE_STRING );
is_wp_error(
            wp_signon(
                      array(
                            'user_login'=>$user,
                            'user_password'=>$pass
                            ) 
                     )
            ) ? die( -1 ) : die( 0 );

Put this code in a file (e.g. ajax-login.php) and call it vai ajax. Then WordPress should set a cookie to grant access.