init XHMedia class