Commit Graph

33 Commits

Author SHA1 Message Date
baldurk 1c05c5e5d1 Add option to renderdoccmd replay to specify a loop count 2018-10-02 16:23:40 +01:00
baldurk 390096e796 Add missing includes on android
* Thanks to @Themaister for this fix
2018-09-25 15:09:54 +01:00
baldurk 569f11b757 Make sure to get eglTerminate function pointer
* Fixes 100% crash on startup introduce by #993
2018-05-26 14:41:39 +01:00
tabi.katalin d2cdca45a5 Fix bad alloc error when creating window surface
The screen doesn't refresh when changing between captures during replay on remote Android device because it fails to display the splash screen and the new preview window.
2018-05-24 10:45:46 +01:00
baldurk 627a965d69 Specify GLES2 renderable type when fetching egl config
* Fixes preview display on PowerVR
2018-05-11 20:39:43 +01:00
baldurk 13dd17d6f2 Always 'release' the preview window even if it wasn't created.
* This helps on android where we might fail to create the preview window
  if our app isn't in the front, but we still want to let the base loop
  know that we're done previewing and let it go back to the generic
  splash screen.
2018-02-02 18:40:28 +00:00
baldurk 2147cb0b9f Create and destroy PThreadLocks globally
* If we destroy them at the end of android_main we might destroy them
  while the thread is running and cause incorrect code flows where we
  try to join and restart the thread while it's blocking.
* Don't get me started on why android_main exits when you get alt-tabbed
  away from...
2018-01-31 18:24:15 +00:00
baldurk 6fe179bea3 Only join a previous command thread and restart if it has exited
* APP_CMD_INIT_WINDOW can be called when the application hasn't fully
  shutdown, and the thread is still running. Hold a lock while we're
  inside renderdoccmd() so that we know if the thread has exited or not.
* This would be easier if android had pthread_tryjoin_np()...
2018-01-22 20:04:17 +00:00
michaelrgb 89eb933be5 If user resumes APK after server shutdown, restart cmdthread.
Also make sure ANativeActivity_finish/DetachCurrentThread are called.
2018-01-03 11:11:25 +01:00
baldurk 0ea854a9da Don't return android windowing data if we have no window 2018-01-02 14:34:34 +00:00
baldurk 7347e19d8c Add check & print of shader compile and program link status 2018-01-02 12:34:46 +00:00
baldurk 7abc319a2c Add default precision for logo fragment shader 2018-01-02 12:34:26 +00:00
baldurk e305029ddd Update copyright years to 2018 2018-01-01 17:55:29 +00:00
baldurk 96e39cb781 Add a preview window ability to remote servers. Always on for android
* On android in particular this shows some sense of what's happening on
  the device and gives user feedback that it's not completely dead.
2018-01-01 17:31:23 +00:00
baldurk 6572cd97f5 Tidy up handling of windowing data, make it a bit more type safe 2018-01-01 17:31:19 +00:00
baldurk b8bd99a24a Add a simple preview placeholder for android
* This means that at least when nothing else is happening the remote
  server isn't completely blank and unresponsive.
2018-01-01 12:41:12 +00:00
Michael Rennie 70f55a1458 Start/Shutdown Android server from RemoteManager dialog.
ANativeActivity_finish when renderdoccmd() returns.
2017-06-14 05:03:46 -07:00
baldurk 3ab7510c7f Avoid calling XOpenDisplay multiple times, fixes crashes on Intel Mesa
* See https://bugs.freedesktop.org/show_bug.cgi?id=99831
  https://bugs.freedesktop.org/show_bug.cgi?id=54971
* It's not clear if it's invalid to call XOpenDisplay more than once but
  at the very least it's only really used as convenience to avoid
  plumbing the display handle through.
2017-05-30 12:02:00 +01:00
baldurk 6930841705 Rename ReplayRenderer to ReplayController
* It's not a renderer, it's an interface to controlling the replay and
  any 'renderer' type work actually happens in ReplayOutput.
2017-04-18 14:57:47 +01:00
baldurk bd199ca8e6 Remove declarations for C interface from renderdoc_replay.h header
* The functions are still exported and that's all renderdocui cares for.
* The interface is no longer to be used so gets in the way of the
  generated SWIG bindings.
2017-04-18 14:57:36 +01:00
baldurk d40fc8471d Change API enums to enum class, remove now redundant prefixing
* This gives a little nicer syntax, a bit better type safety, and also
  reflects better for SWIG bindings. Overall it's a minor change but
  better.
* We don't update the C# UI at all, since it's soon to be removed and
  not worth the effort/code churn.
* For now so we're ABI compatible with C#, all enums are uint32_t, but
  that is an obvious optimisation in future to reduce struct packing.
* We avoid 'None' as an enum value, because it's a reserved word in
  python so will cause problems generating bindings.
2017-04-18 14:57:33 +01:00
baldurk 487a1b7903 Start moving towards C++ only UI code. Assume C++ for the replay API
* The C# P/Invoke stuff doesn't directly use the header, and we are soon
  going to deprecate the C interface entirely.
2017-03-13 17:56:00 +00:00
baldurk 030cbfde9a Batch update copyright years everywhere 2017-01-06 12:13:31 +00:00
Michael Rennie 80b2974b7e Pass in apk parameters via am start ... -e renderdoccmd "args"
Examples:
adb shell am start -n org.renderdoc.renderdoccmd/.Loader -e renderdoccmd "remoteserver"
adb shell am start -n org.renderdoc.renderdoccmd/.Loader -e renderdoccmd "replay /sdcard/capture.rdc"
2016-08-25 14:42:14 +01:00
baldurk f8b3fd3e1e Update renderdoccmd for new remote server code, add daemonise for server 2016-08-19 17:26:08 +02:00
Michael Rennie 396b83699b Fixed vulkan library used for Android replay, plus cmdline args. 2016-08-10 12:21:40 +02:00
Michael Rennie e08ce7239c Android build fixes 2016-08-02 11:52:12 +02:00
baldurk ebb889a7ee Report supported windowing systems from replay, and choose which to use
* This is primarily for vulkan, which supports either xlib or xcb (and
  not necessarily both). GL still only supports xlib, windows and
  android only support one system regardless of API.
* This should also support xlib again for fetching keystates etc.
2016-07-22 18:23:30 +02:00
baldurk e81895b060 [Coverity] Remove use of rand() now SetFrameEvent takes 'bool force'
* I honestly can't figure out how to tell Coverity that rand() use isn't
  a security flaw, but it's on longer needed so...
2016-07-20 16:01:48 +02:00
baldurk 99c0177cd9 Remove unused GetUsername() function 2016-07-12 19:39:41 +02:00
baldurk ced8a62af6 Add replay command (with optional remote replay) 2016-07-12 17:39:23 +02:00
baldurk eb9a545104 Move common functions declarations into header 2016-07-12 17:10:42 +02:00
Michael Rennie ad2b266f95 Makefiles to build apk for RenderDocCmd on Android & More replay fixes. 2016-06-17 13:50:00 +02:00