Commit Graph

102 Commits

Author SHA1 Message Date
Kevin McCullough e213cfafa9 Modifying the TextureList to use EventBrowser-style chooser. 2020-10-15 22:19:44 +01:00
baldurk 936e6372cb Remove use of 3rdparty/ prefix from includes
* We instead always have 3rdparty/ in the relevant include search paths and rely
  on that. Each library still has its own unique base dir within 3rdparty to
  clarify where the include is coming from.
2020-03-11 18:00:53 +00:00
baldurk 2916c0f9f7 Update copyright years to 2020 2020-01-06 16:20:45 +00:00
baldurk 4458ab3205 Remove assumptions that captures are always frames
* Previously we had "Frame X" and "Start of Frame" hardcoded in the event
  browser, and the end of frame was in many cases assumed to be a present call.
  However with the in-application API this is not necessarily true.
* Presents are now serialised separately in all APIs and displayed wherever they
  happen in the frame, and if there is no present at the end of the frame an
  "End of Capture" marker is inserted. Similarly API-defined captures are not
  given a potentially misleading frame number.
2019-11-21 17:09:01 +00:00
baldurk 4e6af7a47a Don't crash if the event browser isn't open when opening a capture 2019-10-10 16:48:42 +01:00
baldurk e3d902e686 Don't try to set find icons if no capture is loaded 2019-09-30 16:30:40 +01:00
baldurk 78ae520e3a Hide find/jump toolbars when closing a capture 2019-08-01 12:00:23 +01:00
baldurk de37c7d005 Check if the capture is closed while a timing request is pending 2019-04-12 15:11:26 +01:00
baldurk 86ff87863e Update copyright years to 2019 2019-02-01 18:32:13 +00:00
baldurk 317e89f7cb Add QIODevice::Text for text writing, to convert newlines. Refs #1246 2019-01-28 19:55:39 +00:00
baldurk 69a76bfb41 Use ASCII name for duration column in draw list export. Refs #1246 2019-01-24 10:15:36 +00:00
baldurk ce88558a7c Refactor RDTreeWidgetDelegate into RichTextViewDelegate that is reusable
* This allows us to add rich text support much more easily into other itemviews
  like RDTableView.
* We set it up for debug messages so that resource links in debug messages can
  be linked.
2018-12-17 17:10:34 +00:00
baldurk 8447e43e78 Fix panel menus 2018-10-23 15:15:39 +01:00
baldurk 94dfb9890b Allow registering window, panel and context menu items with callbacks 2018-10-23 14:23:12 +01:00
baldurk 995caa2636 Implement empty-marker hiding options for event browser 2018-10-04 16:07:36 +01:00
baldurk 10b82e6255 Fix possible race condition with capture loading
* The event browser called SetEventID from OnCaptureLoaded, which would then
  call OnEventChanged on all viewers, which if they kicked off work could happen
  at the same time as the later call to OpCaptureLoaded for them.
* In the mesh viewer this seemed to lead to a race condition and had a chance to
  corrupt memory.
2018-07-13 15:43:55 +01:00
baldurk 650a80db47 When searching start at selected not current event. Closes #1030
* When selecting a marker region, the more intuitive search is to find children
  of the marker first before searching onwards, even if the 'current event' is
  at the end of the marker region.
2018-07-09 16:28:03 +01:00
baldurk 0dda96a045 Change previous/next/parent IDs in DrawcallDescription to pointers
* This is a legacy holdover from the C# interop not being able to preserve
  pointers easily.
2018-06-18 18:39:06 +01:00
baldurk 082ab4d75d GUIInvoke takes a QObject* to avoid callbacks after object lifetime
* The GUIInvoke object takes a QObject, and uses QPointer to check that
  it hasn't been deleted when the callback fires. This prevents delayed
  callbacks from executing after the object has been deleted and
  crashing.
* In most cases the pointer is just 'this'.
2018-05-08 11:54:34 +01:00
baldurk 2d0f675ca8 Add socket-based interop with RGP and profile embedding in captures 2018-04-25 19:10:51 +01:00
Baldur Karlsson 68a3f3a31f Filter out previous/next drawcall shortcuts when text editing.
Closes #911

editing.
path.
'ad0678a'.
2018-03-12 15:46:44 +00:00
baldurk cad5520238 Tweak the event browser to support richtext in drawcall names
* This lets Resource ID text become links to the resource inspector even
  in drawcall names (like glBlitFramebuffer(src, dst)).
2018-02-13 21:10:06 +00:00
baldurk 65ef82466c Re-organise Analytics structures a bit to be more processing friendly 2018-01-19 13:57:02 +00:00
baldurk e305029ddd Update copyright years to 2018 2018-01-01 17:55:29 +00:00
baldurk ebaefc82a9 Normalise and make python/public interface more consistent
* We enforce a naming scheme more strongly - types, member functions,
  and enum values must be UpperCaseCamel, and member variables must be
  lowerCaseCamel. No underscores allowed.
* eventId not eventID or EID, and Id preferred to ID in general. Also
  for resourceId.
* Removed some lingering hungarian m_Foo naming.
* Some pipeline state structs that are almost identical between the
  different APIs are pulled out into common structs. Where something
  doesn't make sense (e.g. viewport enable for vulkan) it will just be
  set to a sensible default (in that case always true).
* Changed scissors to be x/y & width/height instead of sometimes
  left/top/right/bottom
* Abbreviations are discouraged, e.g. operation not op, function not
  func.
2017-12-22 13:02:36 +00:00
baldurk 0b527fab49 Use rdc types instead of Qt containers in public QRenderDoc interface
* This is to support python bindings - the pyside implementation of
  QVector, QString, etc is not available to SWIG, so SWIG treates these
  all as opaque types.
* Rather than trying to set up bindings that work for rdcarray and
  QList/QVector, or implementing separate bindings, we instead just say
  that the public interface must use the rdc types. In most cases they
  seamlessly convert to/from Qt types anyway.
* In a couple of places we use an array of pairs instead of a map. In
  future we probably want an rdcdict or rdcmap with proper dict bindings
  in python.
2017-12-13 22:43:01 +00:00
baldurk a6ebf09785 Add analytics system - disabled for now
* This is a *very* light-touch analytics system that will track the
  simplest and most anonymous statistics that can be useful in
  determining which features are most used or perhaps underused, and
  where it's best to direct development attention.
* It is entirely implemented in the UI layer, no analytics-gathering
  code exists in the library that's injected into programs, and of
  course no capture data (screenshots, resource contents, shaders, etc
  etc) is transmitted.
* Once it's turned on, it will apply to both development and release
  builds. It tracks stats over a month, and then at the beginning of a
  new month it sends the previous data.
* When the user first starts up a build with analytics if there's no
  previous analytics database then they are informed of the new code and
  asked to approve it. They have the option of selecting to manually
  verify any sent reports, or just opt-ing out entirely.
2017-11-29 19:01:22 +00:00
baldurk 38acc56084 Unregister shortcuts when closing windows that registered shortcuts
* This prevents leaking for cases where new widgets are created (and
  the small chance a widget pointer could be re-used and cause serious
  problems), and multiple-registration errors for global shortcuts.
2017-11-22 19:11:25 +00:00
baldurk e75a468d3c Remove direct include of Code/CaptureContext.h in almost all files
* This is a leftover from before the interface was hoisted out, and most
  windows were still calling directly to CaptureContext instead of via
  the public ICaptureContext interface
2017-11-22 19:11:20 +00:00
baldurk 19974e1771 Move bookmark storage centrally and save it with capture. Refs #501 2017-11-17 16:31:03 +00:00
baldurk 33ff48811b Normalise terminology in UI code - don't call captures 'logs'
* Log is an overloaded term since it can also mean the debug log. We now
  consistently refer to capture files as capture files or just captures
  for short. The log is just for log messages and diagnostics.
* The user-facing UI was mostly already consistent, but many of the
  public interfaces exposed to python needed to be renamed, and it made
  more sense just to make everything consistent.
2017-11-17 16:30:57 +00:00
baldurk e6c5c03896 Remove rdctype namespace. Rename rdctype::str -> rdcstr, rdcarray, etc
* Since these types are more prevalent than originally designed, it
  makes more sense to remove the namespace for ease of typing/naming.
* Also add a specialised type 'bytebuf' for an array of bytes.
* This makes mapping easier to SWIG since there's no special casing for
  namespaced arrays. Especially so for nested cases like
  rdctype::array<rdctype::str> -> rdcarray<rdcstr>
2017-11-03 16:04:59 +00:00
baldurk 5e59616a8c Update rdctype::array to have a more stl-like mutable interface
* For the most part the interface is stl-compatible, but we have a few
  little changes of our own for convenience.
* This class is still needed after deleting the C# UI, because we don't
  want to pass C++ stl structs over module boundaries and possibly run
  into hard to diagnose incompatibilities.
2017-11-03 16:01:58 +00:00
baldurk 0d7a064443 Right align both durations in event browser and perf counter data 2017-10-27 12:26:02 +01:00
baldurk 6b230d8de0 Use float formatter for duration column in event browser 2017-10-27 12:26:02 +01:00
baldurk 4c24b0f28f Remove use of ToQStr to convert rdctype::str to QString 2017-08-18 14:13:22 +01:00
baldurk a6f0d07e09 Remove most stylesheet use as this messes with a custom style
* Use palettes where a certain colour is needed.
* Still need some solution for table borders in grid layouts
2017-07-28 19:06:44 +01:00
baldurk 58d40fdc26 Don't show 0.0 as the default drawcall duration 2017-07-28 19:06:39 +01:00
baldurk 8a0432add9 Fix crashes if drawcall list goes away when log is closed 2017-07-25 09:23:04 +01:00
baldurk 41092e869f Allow clicking 'next draw' from the frame start marker at EID 0 2017-07-17 12:36:04 +01:00
baldurk 1676f2698e Disable previous/next buttons when there's no previous/next drawcall 2017-07-17 11:30:31 +01:00
baldurk df9f72b857 Add option to ignore icon size when sizing rows in a RDTreeView 2017-07-13 13:57:33 +01:00
baldurk d44528794a Change qrenderdoc icons to Farm-Fresh, to add high-DPI versions. 2017-06-19 16:17:20 +01:00
baldurk 7fe267d548 Only add log viewer at the end of constructors, so the window is ready
* Otherwise if OnLogFileLoaded gets called while adding the log viewer
  the window might be partially constructed and crash.
2017-06-09 12:08:39 +01:00
baldurk 199c26adbf Put the MainWindow in charge of handling 'global' type shortcuts
* QShortcut falls down on duplicates. It can have activatedAmbiguously
  events, but these happen in arbitrary order and the shortcuts on
  menu items just swallow the ambiguous activate so it's not useful.
* Instead we just let MainWindow pick up ShortcutOverride events and
  consult a mapping of which shortcuts to use. We can use a smarter
  selection method to choose the more 'local' shortcut if two shortcuts
  that conflict exist.
2017-06-08 18:23:10 +01:00
baldurk a4fe376c32 Add column selection popup for event browser and persist column state
* We can add in the Draw # column now, and set up the default state to
  not include the duration column.
2017-06-03 00:53:54 +01:00
baldurk 63bf0310d3 Fix summing of durations in event browser 2017-06-03 00:46:11 +01:00
baldurk 3b6f63be0d Make event browser columns properly resizable and re-orderable
* Annoyingly although Qt has an internal bool allowUserMoveOfSection0
  which does exactly what we want allowing the tree column to be
  movable, we can't enable it because it's private. So instead we have
  to re-implement section moving ourselves.
* Minor tweak - also made RDTreeWidgets non-movable by default since
  usually we don't want to allow it.
2017-06-03 00:38:02 +01:00
baldurk 10aa73528d Reset event browser before it's added
* When we add it, if a log is already open that's when we get the
  callback to OnLogFileOpened to initialised. If we close afterwards,
  we'll be in an inconsistent state.
2017-06-01 18:50:14 +01:00
baldurk b311e65dbd Change margins to be a minimum instead of adding them
* The style itself may have added some margins and we don't want to add
  extra margins, just set a minimum.
2017-06-01 18:47:42 +01:00