From: <kro...@us...> - 2011-01-23 16:56:32
|
Revision: 4077 http://mp-plugins.svn.sourceforge.net/mp-plugins/?rev=4077&view=rev Author: kroko_koenig Date: 2011-01-23 16:56:25 +0000 (Sun, 23 Jan 2011) Log Message: ----------- fix exception top handler Modified Paths: -------------- trunk/plugins/AndroidRemote/Android/MediaPortalRemote/readme trunk/plugins/AndroidRemote/Android/MediaPortalRemote/src/mediaportal/remote/main.java trunk/plugins/AndroidRemote/Android/MediaPortalRemote/src/mediaportal/remote/utils/TopExceptionHandler.java trunk/plugins/AndroidRemote/Release/MediaPortalRemote.zip trunk/plugins/AndroidRemote/Server/AndroidRemote/AndroidServer.cs trunk/plugins/AndroidRemote/Server/AndroidRemote/Content/ExecuteCommand.cs trunk/plugins/AndroidRemote/Server/AndroidRemote.suo Added Paths: ----------- trunk/plugins/AndroidRemote/Release/video.jpg trunk/plugins/AndroidRemote/Release/video2.jpg Modified: trunk/plugins/AndroidRemote/Android/MediaPortalRemote/readme =================================================================== --- trunk/plugins/AndroidRemote/Android/MediaPortalRemote/readme 2011-01-21 19:03:28 UTC (rev 4076) +++ trunk/plugins/AndroidRemote/Android/MediaPortalRemote/readme 2011-01-23 16:56:25 UTC (rev 4077) @@ -5,6 +5,7 @@ switch off / hibernate etc. your MP from the remote vibration feedback show what actual playing on the main screen and pause / skip control +usese VLC to stream to the phone Pictures section ---------------- @@ -48,6 +49,8 @@ set the power mode for power control short push is sending WakeOnLan long push will exti etc. the MP (see power mode) +volume buttons will do vol +/- of the mp +menu opens the keyboard Main issues ------------ Modified: trunk/plugins/AndroidRemote/Android/MediaPortalRemote/src/mediaportal/remote/main.java =================================================================== --- trunk/plugins/AndroidRemote/Android/MediaPortalRemote/src/mediaportal/remote/main.java 2011-01-21 19:03:28 UTC (rev 4076) +++ trunk/plugins/AndroidRemote/Android/MediaPortalRemote/src/mediaportal/remote/main.java 2011-01-23 16:56:25 UTC (rev 4077) @@ -73,6 +73,8 @@ public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); + + Thread.setDefaultUncaughtExceptionHandler(new TopExceptionHandler(this)); KeyLock.setKeyguardManager((KeyguardManager) getSystemService(Activity.KEYGUARD_SERVICE)); Vibration @@ -86,7 +88,7 @@ chkStatus(); Intent myIntent = new Intent(this, Splash.class); - startActivityForResult(myIntent, 0); + startActivity(myIntent); } // create MP folder @@ -121,8 +123,6 @@ } - Thread.setDefaultUncaughtExceptionHandler(new TopExceptionHandler(this)); - // Navigation Buttons Button btnPictures = (Button) findViewById(R.id.btn_main_pictures); @@ -175,7 +175,7 @@ btnSettings.setOnClickListener(new View.OnClickListener() { public void onClick(View view) { Vibration.vibrateShort(); - + Toast.makeText(view.getContext(), "not implemented yet. Sorry !", Toast.LENGTH_SHORT) .show(); @@ -281,8 +281,21 @@ } private boolean reportExist() { - File f = new File("stack.trace"); - return f.exists(); + + try + { + BufferedReader reader = new BufferedReader(new InputStreamReader( + this.openFileInput("stack.trace"))); + reader.close(); + + return true; + } + catch (Exception ex){} + + return false; + + //File f = new File("stack.trace"); + //return f.exists(); } private void sendReport() { Modified: trunk/plugins/AndroidRemote/Android/MediaPortalRemote/src/mediaportal/remote/utils/TopExceptionHandler.java =================================================================== --- trunk/plugins/AndroidRemote/Android/MediaPortalRemote/src/mediaportal/remote/utils/TopExceptionHandler.java 2011-01-21 19:03:28 UTC (rev 4076) +++ trunk/plugins/AndroidRemote/Android/MediaPortalRemote/src/mediaportal/remote/utils/TopExceptionHandler.java 2011-01-23 16:56:25 UTC (rev 4077) @@ -59,7 +59,7 @@ } report += "-------------------------------\n\n"; - report += "Remote Version : initial release\n\n"; + report += "Remote Version : 2nd version\n\n"; report += "-------------------------------\n\n"; report += "--------- Device ---------\n\n"; report += "Brand: " + Build.BRAND + "\n"; Modified: trunk/plugins/AndroidRemote/Release/MediaPortalRemote.zip =================================================================== (Binary files differ) Added: trunk/plugins/AndroidRemote/Release/video.jpg =================================================================== (Binary files differ) Property changes on: trunk/plugins/AndroidRemote/Release/video.jpg ___________________________________________________________________ Added: svn:mime-type + application/octet-stream Added: trunk/plugins/AndroidRemote/Release/video2.jpg =================================================================== (Binary files differ) Property changes on: trunk/plugins/AndroidRemote/Release/video2.jpg ___________________________________________________________________ Added: svn:mime-type + application/octet-stream Modified: trunk/plugins/AndroidRemote/Server/AndroidRemote/AndroidServer.cs =================================================================== --- trunk/plugins/AndroidRemote/Server/AndroidRemote/AndroidServer.cs 2011-01-21 19:03:28 UTC (rev 4076) +++ trunk/plugins/AndroidRemote/Server/AndroidRemote/AndroidServer.cs 2011-01-23 16:56:25 UTC (rev 4077) @@ -75,6 +75,36 @@ cacheDB.IsBackground = true; cacheDB.Priority = ThreadPriority.Lowest; cacheDB.Start(); + + logInfo("Init vlc palyer"); + + string sVlcPath; + Microsoft.Win32.RegistryKey regkeyVlcInstallPathKey = Microsoft.Win32.Registry.LocalMachine.OpenSubKey(@"SOFTWARE\VideoLAN\VLC"); + if (regkeyVlcInstallPathKey != null) + { + sVlcPath = (string)regkeyVlcInstallPathKey.GetValue("InstallDir", ""); + + string[] args = new string[] + { + "--audio-desync=-50", + "--no-sout-rtp-sap", + "--sout-transcode-fps=15", + "--sout-rtp-caching=2000", + "--sout-transcode-threads=4", + "--sout-transcode-high-priority", + "--sout-keep", + "--sout=#duplicate{dst='transcode{venc=x264{profile=baseline,level=3,keyint=30,bframes=0,no-cabac,ref=1,no-interlaced,vbv-maxrate=512,vbv-bufsize=256,aq-mode=0,no-mbtree,partitions=none,no-weightb,weightp=0,me=dia,subme=0,no-mixed-refs,no-8x8dct,trellis=0},vcodec=h264,vb=512,vfilter=canvas{width=320,height=160,aspect=320:160,padd},soverlay,aenc=ffmpeg{aac-profile=low},acodec=mp4a,ab=96,channels=2,audio-sync}:gather:rtp{sdp=rtsp://0.0.0.0:5554/MediaPortal.sdp,mp4a-latm}',dst='transcode{vcodec=null,acodec=mp3,ab=160,channels=2}:gather:std{access=http,mux=raw,dst=0.0.0.0:8081}'}", + "-I", + "dumy", + "--no-ignore-config", + "--no-osd", + //"--plugin-path=" + System.IO.Path.Combine(sVlcPath , "plugins") + }; + AndroidServer.vlc = new VideoLan.VlcControl(args); + + AndroidServer.vlc.Visible = false; + GUIGraphicsContext.form.Controls.Add(AndroidServer.vlc); + } } Modified: trunk/plugins/AndroidRemote/Server/AndroidRemote/Content/ExecuteCommand.cs =================================================================== --- trunk/plugins/AndroidRemote/Server/AndroidRemote/Content/ExecuteCommand.cs 2011-01-21 19:03:28 UTC (rev 4076) +++ trunk/plugins/AndroidRemote/Server/AndroidRemote/Content/ExecuteCommand.cs 2011-01-23 16:56:25 UTC (rev 4077) @@ -565,35 +565,7 @@ if (AndroidServer.vlc != null) { if (AndroidServer.vlc.IsPlaying) AndroidServer.vlc.Stop(); - } - string sVlcPath; - Microsoft.Win32.RegistryKey regkeyVlcInstallPathKey = Microsoft.Win32.Registry.LocalMachine.OpenSubKey(@"SOFTWARE\VideoLAN\VLC"); - if (regkeyVlcInstallPathKey != null) - { - - sVlcPath = (string)regkeyVlcInstallPathKey.GetValue("InstallDir", ""); - - string[] args = new string[] - { - "--audio-desync=-50", - "--no-sout-rtp-sap", - "--sout-transcode-fps=15", - "--sout-rtp-caching=2000", - "--sout-transcode-threads=4", - "--sout-transcode-high-priority", - "--sout-keep", - "--sout=#duplicate{dst='transcode{venc=x264{profile=baseline,level=3,keyint=30,bframes=0,no-cabac,ref=1,no-interlaced,vbv-maxrate=512,vbv-bufsize=256,aq-mode=0,no-mbtree,partitions=none,no-weightb,weightp=0,me=dia,subme=0,no-mixed-refs,no-8x8dct,trellis=0},vcodec=h264,vb=512,vfilter=canvas{width=320,height=160,aspect=320:160,padd},soverlay,aenc=ffmpeg{aac-profile=low},acodec=mp4a,ab=96,channels=2,audio-sync}:gather:rtp{sdp=rtsp://0.0.0.0:5554/MediaPortal.sdp,mp4a-latm}',dst='transcode{vcodec=null,acodec=mp3,ab=160,channels=2}:gather:std{access=http,mux=raw,dst=0.0.0.0:8081}'}", - "-I", - "dumy", - "--no-ignore-config", - "--no-osd", - //"--plugin-path=" + System.IO.Path.Combine(sVlcPath , "plugins") - }; - - if (AndroidServer.vlc == null) - AndroidServer.vlc = new VideoLan.VlcControl(args); - string filename = data["filename"].Replace("/", "\\"); directoryList = GetMpShare("movies"); @@ -610,8 +582,8 @@ { // why ever } - } + #endregion #region play video file Modified: trunk/plugins/AndroidRemote/Server/AndroidRemote.suo =================================================================== (Binary files differ) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |