Rotate screen orientation on Web App Tizen [TV] - web

I'm developing a Web Application on Tizen. My application was first developed on other platforms like iOS and Android.
Basically it starts on Landscape mode and plays remote content such as image, video or opens a web page. It has a menu inside the app to offer people the ability to change the screen orientation inside the app manually.
This approach is quite easy on iOS and Android but on Tizen seems it doesn't work that easy.
I'm following Tizen's official documentation which send's us to : https://w3c.github.io/screen-orientation/
But, can't make it work even though I followed steps written on the link above.
This is what I got when I try to rotate:
Trying with :
screen.orientation.lock('portrait-primary')
Error :
Promise {}
index.html:1 Uncaught (in promise) DOMException: The page needs to be fullscreen in order to call screen.orientation.lock().
P.S. The app is already in fullscreen. The error is not relevant.
Do you have any ideas ?
Thank you

For all to those who are still trying to achieve this:
After having a long discussion with Samsung, they claimed that supporting the TV orientation via code is not possible right now (Not sure if it's gonna be implemented in the future).
These restrictions come due to different operability of the hardware components on different orientation.
The only way to rotate your screen is to do it via Samsung's TV Settings so that it can prepare its hardware for the chosen orientation.

There are a special Samsung TVs for Advertising market (Digital Signage series) that are ready to set the orientation of the screen.
I comercial Samsung TV sets Tizen is not able to rotate some kind of elements (as far I know the video object are one of the HTML elements that cannot be rotated)
I've developed some apps for Tizen and for one customer I tried to make a video wall but it was impossible due the firmware limitation of Tizen (it's a marketing strategy in order to avoid having hotel and digital signage capabilities in commercial TV sets)

Related

How does Scratch play sounds without any problem on mobile?

If you are familiar with scratch, you'll know that Scratch 3 was built to support mobile.
Javascript audio isn't working on mobile devices shows that mobile doesn't support auto playback of audio
Scratch seems to play audio without a problem...
Does anyone know the secret behind Scratch mobile audio playing capabilities? (share pieces of code which scratch uses to play audio on mobile)
(Incase you're wondering why I need to know this, I need to use it on my website)
Read the answer carefully.
Some mobile browsers support automatic playback of audio, but ios, chrome and others require interactive actions to trigger the sound playback.You can try working with the mute attribute..
Scratch can't play sounds automatically. You have to click the Start button on any project. By "interactive actions" they mean clicks, scroll etc,.

Windows Phone camera customization

How can I use the camera in Windows Phone 10 and save screenshots o pictures with out flash (I mean blocking the flash option to the users) Is it possible?
You can create the user experience you want making your own camera app. Universal Windows Platform APIs will give you full control over what your user will be able to do.
Take this sample camera app as a good starting point
https://github.com/Microsoft/Windows-universal-samples/tree/master/Samples/CameraStarterKit
The process of taking a picture using the camera and taking a screenshot are completely different.
here is an article on how to make and save a screenshot, works for win 8.1, also for Windows Phone 10
http://blogs.msdn.com/b/lighthouse/archive/2013/10/18/capturing-snapshot-in-windows-8-1-store-app.aspx

Why am I getting a LAUNCH_ERROR, NOT_FOUND when attempting to play to an audio-only Google Cast device?

I recently purchased a LG Music Flow H3 to test my Google Cast app with an 'audio-only' device. I've enabled audio-only device support within the Google Cast Dashboard and I've registered the device for development. My app works as expected when played to Google Chromecasts, however when attempting to load the receiver app on the LG device I get the following error:
{"reason":"NOT_FOUND","requestId":1,"type":"LAUNCH_ERROR"}
Thinking that perhaps 3rd-party devices can't be registered for development, I went ahead and published my app. Unfortunately this did not address the problem.
Upon further investigation, I'm noticing that other Google Cast apps (i.e. Songza, TuneIn, Pandora, etc. on both Android & iOS) aren't able to play to the LG Music Flow H3 either.
I discovered that the only way to get the H3 to play from Google Cast apps (both my app and others) is to first run the LG Music Flow multi-room audio app. Running the LG Music Flow app appears to effect the device's _googlecast._tcp zeroconf service discoverability. And sometimes the H3 shows up in zeroconf yet you still can't play to the speaker unless the LG Music Flow app is running.
This seams like very strange behavior. I called LG Tech Support, and they recommended I return the device and exchange it for a different one. I did this, and I still get the same result.
Is this how Google Cast on 3rd-Party devices is intended to work? Have I encountered a buggy 3rd-party implementation?
This is not the intended behavior for sure. You are supposed to be able to launch your 3rd party application on the speaker.
And it works for me.
The fact you are not able to use any other 3rd party apps (TuneIn, Pandora etc) indicate this is a some general problem and not specifically with your app.
Couple of steps I would try:
- Setup you H3 speaker on Wifi (vs Ethernet) and get the latest SW version using the Music Flow app.
Have you Factory reset the device? if you did, you will need to go through setup again. I have noticed Google Cast becomes enabled only after first complete setup.
Please try rebooting, and than try casting apps like TuneIn or Pandora and than see if this works (without using the MusicFlow app). I have noticed in the past that if some app is loaded and is behaving badly (for example uses tons of memory) it will put the speaker into a bad state that don't allow any app to work until reboot. So perhaps when you are casting your app, it gets into a bad state causing other apps to fail afterwards.
Have you made sure not to consume to much memory? avoid graphics or video?

WP7 Emulator Browser not displaying anything

I use the webbrowser control to display a webpage from an application, but it just displayed a white screen. I tried Internet Explorer and it did not display anything either.
Any ideas how to fix this problem.
Thanks a lot in advance.
Windows Phone Emulator requires a DirectX 10 or above capable graphics card with a WDDM 1.1 driver. I assume that you got an error message on first start of the emulator that your graphic adapter isn't capable for all functions the emulator is using and that this may impact XNA games and sometimes silverlight like this one:
If your graphic adapter does not fully support DirectX 10 or doesn't has a WDDM 1.1 driver you will only see a white screen instead of the rendered webpage. This also affects all controls using MultiScaleImage, including the webbrowser control. As far as I know there is no solution for this at the moment.
To check if the emulator is running the required GPU emulation take a look at the arrow to open the application list and if it points to the right or left. If it points to the left, NO GPU is available - if it points to the right (as on the hardware phone itself) the GPU is available and rendering should work as expected.
See also this page in the msdn.
You haven't said if you're testing a local/private page or one on the web.
Also test other pages on the web. Can you view anything or just your own page.
If you can't see pages on the public web then you have a networking issue
If you can see public pages but not locally hosted ones then you probably have a different networking issue. If you're on an actual device or the emulator will likely greatly affect this.
The other things it may are:
you're trying to view a page that is to compilcated to be displayed (if there is such a thing - test with a very simple static page first)
the page uses useragent detecction and doesn't recognise the user agent and so is serving nothing
the page has complex javascript which runs before the page is rendered and the javascript is failing and so the page is never displayed.

ios4 multitasking controls & background Audio features question

I'm pretty new to IOS4 audio/multitasking and i cant find an answer on this topic:
Got a, pretty easy, two part question:
What framework works in conjunction with the ipod framework? Everyone's seen the pandora app, so the question is:
How do you get the app to notify the user that music is playing (via the purple play icon in the status bar)?
How does this become controllable via the multitasking control bar (ya know, the ones right next to the lock-aspect button)?
It's all the same process.
The play icon is added when you successfully link up your app with the remote play controls (remoteControlReceivedWithEvent). The controls are just events that are channeled to your remote control aware app.
TYPE of audio doesn't matter, as far as i know (MPAudioPlayer doesn't work in the background though).
Hope that helps the newer coders out there :)

Resources