I have a WkWebView loaded with a <video> and when I use CrossSimpleAudioPlayer in the C# code, the webview goes black, the CrossSimpleAudioPlayer audio plays for about 1 second, and then the audio stops and the webview is restored. Is there a way to get the two to coexist peacefully?
Edit: Looks like this is the culprit, thanks again, Apple:
Setting AVAudioSession Category has no effect on sound from WKWebView
and
https://bugs.webkit.org/show_bug.cgi?id=167788
Related
I want to design audio player view to play my audio file.
I am bit confused about AVAudioPlayer working.
When I use AVAudioPlayer, it plays my audio file very well.
But I also want PLAY/PAUSE button and seek bar which will show the progress bar.
My question is that,
is there any inbuilt library or code that I can directly inherit and apply...?
or do I need to create those buttons and seek bar programatically and add them on view while playing the file...?
Thanks in advance.
I tried to search but all shows AVAudioPlayer working,
Nothing found four PLAY/PAUSE buttons additions
I am currently making a music player, and I made my own control view using UIButtons for Play, Pause, Next, Previous, and a UISlider for seeking. There is no built in AvAudioPlayer controls that I know of for this purpose.
In my Windows Phone application I'm loading a html site into a view, really simple stuff with this method:
var itemView = view as NorwegianBrowserView;
var webBrowser = itemView.browserContainer;
webBrowser.Navigate(new Uri(_globalAccessObjects.ActiveNorwayLink,UriKind.RelativeOrAbsolute));
The site loads everything except a video clip. Or well it knows the video is there but it just shows a black square. And pressing that black square does nothing.
As i side note i can add that i got the same application for iOS and Android and they both got no problem in loading the very same website(+ they load the video). And here i can press the video clip and it will start playing.
Am i loading the website into my view the wrong way? or does microsoft.phone.controls.webbrowser not support a video clip?
Any help is much appreciated.
The ability to play video clips in line in a web page is dependent upon the version of Windows Phone you are running on and the format of the video.
Only Window Phone 8.1 supports playing video within a page. Unfortunately this isn't yet widely available.
Even then the video format may still be an issue and if not supported could lead to a placeholder image being displayed.
I am trying to access youtube.com through a WebKit WebView in my native Mac App.
The problem is that YouTube videos just show as black squares (see image below). However, if I click them they start to play (but stay black) - the sounds starts. I can also right click and the YouTube right click menu comes up (with things like 'Stats for Nerds').
Does anyone know what is happening here?
I use the standard WebView component, dragged in in Interface Builder. In my header I have the standard:
IBOutlet WebView *firstWebView;
and in my .m the standard:
[firstWebView setHidden:FALSE];
[[firstWebView mainFrame] loadRequest:[NSURLRequest requestWithURL: [NSURL URLWithString:#"http://youtube.com"]]];
The same thing happens when I access a site with an embedded YouTube video.
Thanks!
Sam
Found the answer - as of OS X Mavericks you'll need to call this for WebView's if you want Flash to render correctly:
[self.webView setLayerUsesCoreImageFilters:YES];
Docs: https://developer.apple.com/library/mac/releasenotes/AppKit/RN-AppKit/#//apple_ref/doc/uid/TP30000741-CH2-SW49
I am trying to find the solution to have the control of play/pause when my app is playing the own music in Background. I am using AVAudioPlayer and didnĀ“t find the way to implement this controls. When the app is "close" the music play perfectly but I have to open the app again to pause or change music when needed.
Any solution ?
If you're running iOS 4 you can try putting the app in the background whilst playing music, and then pressing the home button twice for the 'multitasking' bar.
Swipe the bar to the right, which shows you the normal playback controls for Music, YouTube, etc.
If you use the AVAudioPlayer I'm quite sure you can use those same controls to control your app's playback of media.
Bryan
*EDIT does using the remote on the iPhone headphones work?
I'm developing an application that has to display some html content that contains an html5 video (no flash/silverlight plugins). The html and the video are playing fine in safari, but when displayed inside the webview in my application i get a black box where the video should be. But the video seems to be playing, because if i click fullscreen, the video goes fullscreen and is correclty displayed, and also the audio is present, in fullscreen and non fullscreen mode. It seems like the video is played behind the page.
Maybe i'm missing something as a newbe?
does anyone has an html5 video correctly displayed inside a webview on a mac os x 10.6?
Thanks a lot!