How to play .ts live tv link in exoPlayer - java

I am trying to develop a TV app
I have a problem
I can't run the link of satellite channels in ExoPlayer
#EXTINF:
http://raoseditor.com:80/live/GLGhcHsrLV/LD5bWcpAaM/151092.ts

You can check for supported formats here https://google.github.io/ExoPlayer/supported-formats.html

The URL you have above, which appears to be for a ts media file, returns a '302' redirect response or a '403' forbidden response, depending on how you connect to it.
This is usually because the content requires some user login and/or some authorisation token to be included in the request.
If you do have authorisation for the content then the first step is to find out the format and make sure it is included in the ExoPlayer supported content list as Ramesh suggests in another answer. Note that the usual broadcast format support by satellite typically (unless it is IP over the satellite broadcast) need to be converted into an IP based format and streaming protocol to be played on an Android device.

Related

Does Google Analytics method Tracker.getReferer() support android app URIs?

I want to track activity referrer information in my android application.
setReferrer in the Google Analytics API seems to be a suitable method (com.google.android.gms.analytics.Tracker.setReferrer)
But I can not find any documentation for it.
What can I pass to it? Only web links? Or android app URIs are supported too?
like: android-app://com.google.android.googlequicksearchbox/https/www.google.com
I get information about the referrer from:
android.app.Activity.getReferrer
android.content.Intent.EXTRA_REFERRER
android.content.Intent.EXTRA_REFERRER_NAME
Edit:
With additional research I found some more information about referrer in Google Analytics via it's Measurement Protocol Parameter dr:
developers.google.com/analytics/devguides/collection/protocol/v1/parameters#dr
Specifies which referral source brought traffic to a website. This value is also used to compute the traffic source. The format of this value is a URL.
But it also does not clarify whether or not android app URIs are supported.
It seems like Google Analytics for mobile apps does not support referrer information at all.
Only install referrer is shown. I can't find activity referrers anywhere even if I send this info.

LibVLC Android stream from minimal HTTP server

I am trying to write an application similar to the well-known Popcorn Time - an app which lets you watch movies over torrents. It basically uses NanoHTTPD as a bridge between the LibVLC player and the torrent library to be able to stream it. I use this exact same HTTP library.
The problem I have is that, even though using chrome's built-in MP4 viewer works fine, I cannot play the video from VLC. I did notice that it sends an 'Icy-Metadata: 1' header in the HTTP request which Chrome doesn't but little is documentated on that so I'm not sure if that's the problem here.
The desktop version of VLC player does not play it either. It stands there, requesting the same over and over again without displaying my video. What could I be missing?
It may be worth noting that nginx serves it properly, but it seems like nginx doesn't even reply with any kind of http header response. Just data.

Java Android GPS send coordinates

I've got many Android devices and I want to create an application that will be able to send the GPS coordinates and some id of the device to a server created on a PC. what is the fastest and easiest way to do do that ? I tried to find some telnet or java spring rest template but couldn't find a decent tutorial.
please help
There are two steps
1) Getting the GPS coordinates
There are a multitude of examples on how to do this; look into LocationListener and read the Obtaining User Location section of the docs.
2) Sending this data to a server
You will probably use an HTTP Post to accomplish this. See e.g. this Android HTTP Communication post and HttpClient class.
As far as getting a unique ID, you can use the suggestion from another post and use Settings.Secure.ANDROID_ID http://developer.android.com/reference/android/provider/Settings.Secure.html#ANDROID_ID

How to transfer images from Android client to Java server

I am trying to developer an Android application which allows to capture pictures with the camera, and send the pictures to a Java server.
I don't need the picture after, so I do not need to store it in the phone locally.
I was able to successfully to transfer simple text from client to server, but I'm having problems with images.
What do I need to do to be able to send images from the Android client, and should anything special be made in the server apart from what it is doing now?
Solution is to use http request with MultipartEntity.

how to extract to, subject etc fron email in android emulator?

I want to extract "To" and "Subject" from email clent which is already configured in android emulator.
so, is any api to extract or to get all email attributes?
Thanx in advance,
No, sorry.
Bear in mind that there is no single email client in Android. The Android open source project has one, but device manufacturers can (and do) replace it. Plus there is Gmail and other third-party mail clients (e.g., K9). Hence, there is no single email client "which is already configured in android". And the open source one is not part of the SDK, so there is nothing in the API for accessing it.

Categories