Commit Graph

6460 Commits

Author SHA1 Message Date
baldurk 657c343ac8 Support multi-line input in the python shell 2017-11-20 20:01:02 +00:00
baldurk 31b7662db1 Fix adding empty tree widget items in performance counter selection 2017-11-20 20:01:01 +00:00
baldurk 0a20a544c7 Fix double-unwrap when fetching counters in vulkan. Closes #806 2017-11-20 20:01:01 +00:00
Cory Bloor 58b628ee8b Fix unused variables
In almost all cases these can be removed. The only exception is in
ShaderViewer.cpp, where regIdx should have been used.
2017-11-18 00:17:06 +01:00
Cory Bloor b227229d9f Fix Qt selection instructions
pyrenderdoc uses pkg-config to find Qt rather than qmake, so we need to
give it the custom location too. I didn't notice this originally,
because it found my system version of Qt5 and compiled fine. Only when
I started doing static analysis and set up my exclusion list for Qt
headers did I notice there were multiple sets of headers being used.
2017-11-18 00:17:06 +01:00
Cory Bloor f7b9f0be0d Optimized BFREV opcode in dxbc_debug
Main goal was to fix undefined behaviour, but it's also 50x faster...

cppcheck:
[renderdoc/driver/shaders/dxbc/dxbc_debug.cpp:1163]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour
2017-11-18 00:17:06 +01:00
Cory Bloor 5e60d90dd4 Fix memory leak in posix_process
From cppcheck:
[renderdoc/os/posix/posix_process.cpp:319]: (error) Memory leak: argv
2017-11-18 00:17:06 +01:00
baldurk c4207fbd5b Add a missing enum docstring 2017-11-17 17:52:21 +00:00
baldurk 2e508adb43 Fix compile issue about mismatched override/non-override in class 2017-11-17 17:52:15 +00:00
baldurk 734ad2fbd9 Batch and sort updates to related resources 2017-11-17 17:45:27 +00:00
baldurk e790555914 Fix another case with not enough column data and protect against crashes 2017-11-17 17:06:51 +00:00
baldurk b118664bc2 Fix register space filling - resize before grabbing dest pointer 2017-11-17 16:33:06 +00:00
baldurk 0e3cd3d575 Clear timeline bar current state when closing capture 2017-11-17 16:33:06 +00:00
baldurk 016bc29609 Add a tool menu item that will recompress a capture file 2017-11-17 16:33:05 +00:00
baldurk 13de20612b Use typed enum for serialising VkMemoryType::propertyFlags 2017-11-17 16:33:05 +00:00
baldurk 6efb21b8e9 Fix replay of vulkan map commands passing the wrong range size 2017-11-17 16:33:04 +00:00
baldurk d206a012f3 Fix incorrect data-to-column count when adding data to treewidget
* We also add an error in case it happens again.
2017-11-17 16:33:00 +00:00
baldurk 7d501f6ef5 Check for live resources existing before translating to live ID. 2017-11-17 16:31:04 +00:00
baldurk 4a4089f316 Add generic user-provided notes to save along with the capture.
* In future one of the notes items would be for gathered hardware info.
  Not automatically, but with one button press the full configuration
  can be embedded.
2017-11-17 16:31:03 +00:00
baldurk 19974e1771 Move bookmark storage centrally and save it with capture. Refs #501 2017-11-17 16:31:03 +00:00
baldurk c34d4f6122 Add Ctrl+F4 as an alternative shortcut for closing the capture
* Hopefully this is less muscle-memoried than Ctrl+W as 'close tab'.
2017-11-17 16:31:02 +00:00
baldurk c00a6ca8ef Add notion of UI modifications to a capture, saved in .rdc sections 2017-11-17 16:31:01 +00:00
baldurk bb6452c334 Expand IStackResolver into ICaptureAccess to allow section read/write 2017-11-17 16:31:01 +00:00
baldurk a238d3022a Move section data types into the public replay interface 2017-11-17 16:31:00 +00:00
baldurk 0f38c4770b Fix error in bitfield macro 2017-11-17 16:30:59 +00:00
baldurk 0b899d90b6 Add ability to replace sections in RDCFile 2017-11-17 16:30:59 +00:00
baldurk b1c0de3016 Add and tweak some FileIO OS-specific functions
* fflush is a no-op wrapper but nice to have for consistency.
* ftruncateat will take a file read-write handle and truncate it at a
  given length. Useful if re-writing a file and the new data ends up
  being shorter than the oldd ata.
* Move in addition to Copy, and success/fail bool return on both.
2017-11-17 16:30:58 +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 e399365ba2 Add simple utility functions for serialising QVariantMap to/from JSON 2017-11-17 16:30:57 +00:00
baldurk 824ec81864 Make sure Resource is properly null'd out in pipeline state if unbound 2017-11-17 16:30:56 +00:00
baldurk 200f0799a4 Generate clickable links to resource inspector in RDTreeWidget 2017-11-17 16:30:56 +00:00
baldurk 1776b4e6c0 Declare ResourceId Qt metatype in public header so it's QVariant'able 2017-11-17 16:30:55 +00:00
baldurk 25de6726f6 Add some cross-linking for panels that view a single resource
* We add a button with a link icon to indicate that it goes to the
  resource details. We'll re-use the crosshair as a visual metaphor for
  any interactive widget that goes to the resource inspector.
* To remove any possible confusion, we change the icon for the texture
  list and locked tabs in the texture viewer to not include the link.
2017-11-17 16:30:54 +00:00
baldurk 2ac0802b10 When a custom name is changed, refresh the UI to propagate it properly 2017-11-17 16:30:54 +00:00
baldurk 7c8628b237 Centralise resource naming with capture context to allow customisation
* We remove the now unneeded name fields in buffer/texture descriptions
  and some of the pipeline state structs.
* A single function will give the human-readable name for a resource id.
  This will look up a custom set of renames, on top of the names from
  the resource descriptions.
2017-11-17 16:30:53 +00:00
baldurk d009ed3b30 Add a resource inspector window for viewing resource details 2017-11-17 16:30:52 +00:00
baldurk bace05d926 Split out code to populate RDTreeWidget with structured data 2017-11-17 16:30:51 +00:00
baldurk 60e530de88 Split out utility function to group together resource usage events 2017-11-17 16:30:51 +00:00
baldurk 152abc501a Fetch structured file on capture load so it's available persistently 2017-11-17 16:30:50 +00:00
baldurk 3ac3e6c3f1 Fill out resource descriptions in each driver
* For Vulkan and D3D12, we now create a dummy command buffer to ensure
  that there's actually a chunk available to correspond to the command
  buffer that gets submitted or recorded to.
2017-11-17 16:30:50 +00:00
baldurk 1c614029d8 Add a way to return basic information about all resources in a capture
* This provides a way to find the name of any resource besides 'special'
  resources like textures and buffers. In a follow-up commit, the names
  will be removed from their descriptors.
* It also allows us to list which chunks in the structured file were
  used to initialise the resource, giving the ability to look up and
  display the initialisation parameters.
* At the same time we also list the derived/parent resources to better
  allow the user to browse between related resources.
2017-11-17 16:30:49 +00:00
baldurk 8997cb9f07 Fix copy-paste error that searched ReadOnlyResources array for UAVs. 2017-11-17 16:30:48 +00:00
baldurk fb6211a3db Return user data from RDTreeWidget for UserRole variants 2017-11-17 16:30:47 +00:00
baldurk 79b51591c2 Add ForwardingDelegate for use in RD extended widgets.
* This item delegate will forward on either to a specified other
  delegate or to the base implementation. This allows chaining delegates
  (i.e. having one built-in to the widget, which forwards to a user-set
  delegate).
2017-11-17 16:30:47 +00:00
baldurk 0c1c171b4f Update toolwindowmanager to c0943da98b811f39f4fda56306bbeb741fb1214b 2017-11-17 16:30:46 +00:00
baldurk 2d15fe2c05 Fix incorrect chunk type in PersistentMapMemoryBarrier 2017-11-17 16:30:43 +00:00
Peter Gal 2ae9e8a4bc [EGL] Move GLWindowingData creation into it's own method
The GLWindowingData creation was done at three places
with almost no difference.
2017-11-17 17:30:16 +01:00
Peter Gal ca95a9c3ab [EGL] Move symbol loading into one file
The EGL function pointer loading was scattered
in two files thus it is hard to keep track where
the symbols were loaded.

Introduced a class which holds all internally used
EGL function pointers with a helper method to
load the required pointers. Not all EGL pointers
are loaded just the used ones (just like before).
2017-11-17 17:30:16 +01:00
Peter Gal 9c84b7f716 [GL/GLES] Fix incorrect chunk type serialization
In some cases a few GL wrapper methods are called
with incorrect gl_CurChunk during serialization.

This can happen if the capturing application calls
a GL method - for which the gl_CurChunk will be set correctly -
and the wrapped method calls another wrapped GL method
but for that the gl_CurChunk will be incorrect.

Also during the ActivateContext call the gl_CurChunk
was not set.

For now do a hotfix for glDrawArrays and initial context.
2017-11-17 17:30:05 +01:00
baldurk 004514e556 Give a little more room to pixel history when displaying it 2017-11-10 18:36:11 +00:00