mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-11-06 14:04:04 +00:00
Add proper optional argument defaults for optional callbacks
This commit is contained in:
2 files changed
+53
-39
No files matched your search
@@ -450,18 +450,21 @@ expression.
|
||||
:param Callable[[CaptureContext,str,str,int,renderdoc.SDChunk,renderdoc.ActionDescription,str], bool] filter: The
|
||||
callback to call for each candidate event to perform filtering.
|
||||
Callback function signature must match :func:`EventFilterCallback`.
|
||||
:param Callable[[CaptureContext,str,str], str] parser: The callback to call when the parsing the
|
||||
parameters and checking for any errors. This can be ``None`` if no pre-parsing is required.
|
||||
:param Callable[[CaptureContext,str,str], str] parser=None: **Optional parameter**. The callback to
|
||||
call when the parsing the parameters and checking for any errors. This can be ``None`` if no
|
||||
pre-parsing is required.
|
||||
Callback function signature must match :func:`FilterParseCallback`.
|
||||
:param Callable[[CaptureContext,str,str], List[str]] completer: The callback to call when trying
|
||||
to provide autocomplete suggestions. This can be ``None`` if no completion is desired/applicable.
|
||||
:param Callable[[CaptureContext,str,str], List[str]] completer=None: **Optional parameter**. The
|
||||
callback to call when trying to provide autocomplete suggestions. This can be ``None`` if no
|
||||
completion is desired/applicable.
|
||||
Callback function signature must match :func:`AutoCompleteCallback`.
|
||||
:return: Whether or not the registration was successful.
|
||||
:rtype: bool
|
||||
)");
|
||||
virtual bool RegisterEventFilterFunction(const rdcstr &name, const rdcstr &description,
|
||||
EventFilterCallback filter, FilterParseCallback parser,
|
||||
AutoCompleteCallback completer) = 0;
|
||||
EventFilterCallback filter,
|
||||
FilterParseCallback parser = NULL,
|
||||
AutoCompleteCallback completer = NULL) = 0;
|
||||
|
||||
DOCUMENT(R"(Unregisters an event browser filter function that was previously registered.
|
||||
|
||||
|
||||
@@ -1223,14 +1223,14 @@ The details of the types of messages that can be received are listed under
|
||||
This function will block but only to a limited degree. If no message is waiting after a small time
|
||||
it will return with a No-op message to allow further processing.
|
||||
|
||||
:param Callable[[float], None] progress: A callback that will be repeatedly called with an updated progress
|
||||
value when a long blocking message is coming through, e.g. a capture copy. Can be ``None`` if no
|
||||
progress is desired.
|
||||
:param Callable[[float], None] progress=None: **Optional parameter**. A callback that will be
|
||||
repeatedly called with an updated progress value when a long blocking message is coming through,
|
||||
e.g. a capture copy. Can be ``None`` if no progress is desired.
|
||||
Callback function signature must match :func:`ProgressCallback`.
|
||||
:return: The message that was received.
|
||||
:rtype: TargetControlMessage
|
||||
)");
|
||||
virtual TargetControlMessage ReceiveMessage(RENDERDOC_ProgressCallback progress) = 0;
|
||||
virtual TargetControlMessage ReceiveMessage(RENDERDOC_ProgressCallback progress = NULL) = 0;
|
||||
|
||||
DOCUMENT("Cycle the currently active window if there are more windows to capture.");
|
||||
virtual void CycleActiveWindow() = 0;
|
||||
@@ -1325,13 +1325,14 @@ separate thread.
|
||||
If this is ``False``, the function will not interact or block forever on user interaction and will
|
||||
always assume the input is effectively 'cancel' or empty. This may cause the symbol resolution to
|
||||
fail.
|
||||
:param Callable[[float], None] progress: A callback that will be repeatedly called with an updated progress
|
||||
value for the resolver process. Can be ``None`` if no progress is desired.
|
||||
:param Callable[[float], None] progress=None: **Optional parameter**. A callback that will be
|
||||
repeatedly called with an updated progress value for the resolver process. Can be ``None`` if no
|
||||
progress is desired.
|
||||
Callback function signature must match :func:`ProgressCallback`.
|
||||
:return: The result of the operation.
|
||||
:rtype: ResultDetails
|
||||
)");
|
||||
virtual ResultDetails InitResolver(bool interactive, RENDERDOC_ProgressCallback progress) = 0;
|
||||
virtual ResultDetails InitResolver(bool interactive, RENDERDOC_ProgressCallback progress = NULL) = 0;
|
||||
|
||||
DOCUMENT(R"(Retrieve the details of each stackframe in the provided callstack.
|
||||
|
||||
@@ -1514,13 +1515,15 @@ This is primarily useful for when a capture is only stored locally and must be r
|
||||
the capture must be available on the machine where the replay happens.
|
||||
|
||||
:param str filename: The path to the file on the local system.
|
||||
:param Callable[[float], None] progress: A callback that will be repeatedly called with an updated progress
|
||||
value for the copy. Can be ``None`` if no progress is desired.
|
||||
:param Callable[[float], None] progress=None: **Optional parameter**. A callback that will be
|
||||
repeatedly called with an updated progress value for the copy. Can be ``None`` if no progress is
|
||||
desired.
|
||||
Callback function signature must match :func:`ProgressCallback`.
|
||||
:return: The path on the remote system where the capture was saved temporarily.
|
||||
:rtype: str
|
||||
)");
|
||||
virtual rdcstr CopyCaptureToRemote(const rdcstr &filename, RENDERDOC_ProgressCallback progress) = 0;
|
||||
virtual rdcstr CopyCaptureToRemote(const rdcstr &filename,
|
||||
RENDERDOC_ProgressCallback progress = NULL) = 0;
|
||||
|
||||
DOCUMENT(R"(Copy a capture file that is stored on the remote system to the local system.
|
||||
|
||||
@@ -1528,12 +1531,13 @@ This function will block until the copy is fully complete, or an error has occur
|
||||
|
||||
:param str remotepath: The remote path where the file should be copied from.
|
||||
:param str localpath: The local path where the file should be saved.
|
||||
:param Callable[[float], None] progress: A callback that will be repeatedly called with an updated progress
|
||||
value for the copy. Can be ``None`` if no progress is desired.
|
||||
:param Callable[[float], None] progress=None: **Optional parameter**. A callback that will be
|
||||
repeatedly called with an updated progress value for the copy. Can be ``None`` if no progress is
|
||||
desired.
|
||||
Callback function signature must match :func:`ProgressCallback`.
|
||||
)");
|
||||
virtual void CopyCaptureFromRemote(const rdcstr &remotepath, const rdcstr &localpath,
|
||||
RENDERDOC_ProgressCallback progress) = 0;
|
||||
RENDERDOC_ProgressCallback progress = NULL) = 0;
|
||||
|
||||
DOCUMENT(R"(Open a capture file for remote capture and replay. The capture will be opened and
|
||||
replayed on the remote system, and proxied to the local system with a given renderer. As much work
|
||||
@@ -1551,8 +1555,9 @@ or an error has occurred.
|
||||
:param str filename: The path on the remote system where the file is. If the file is only available
|
||||
locally you can use :meth:`CopyCaptureToRemote` to transfer it over the remote connection.
|
||||
:param ReplayOptions opts: The options controlling how the capture should be replayed.
|
||||
:param Callable[[float], None] progress: A callback that will be repeatedly called with an updated progress
|
||||
value for the opening. Can be ``None`` if no progress is desired.
|
||||
:param Callable[[float], None] progress=None: **Optional parameter**. A callback that will be
|
||||
repeatedly called with an updated progress value for the opening. Can be ``None`` if no progress is
|
||||
desired.
|
||||
Callback function signature must match :func:`ProgressCallback`.
|
||||
:return: A tuple containing the status of opening the capture, whether success or failure, and the
|
||||
resulting :class:`ReplayController` handle if successful.
|
||||
@@ -1560,7 +1565,7 @@ or an error has occurred.
|
||||
)");
|
||||
virtual rdcpair<ResultDetails, IReplayController *> OpenCapture(
|
||||
uint32_t proxyid, const rdcstr &filename, const ReplayOptions &opts,
|
||||
RENDERDOC_ProgressCallback progress) = 0;
|
||||
RENDERDOC_ProgressCallback progress = NULL) = 0;
|
||||
|
||||
DOCUMENT(R"(Close a capture analysis handle previously opened by :meth:`OpenCapture`.
|
||||
|
||||
@@ -1594,14 +1599,15 @@ empty or unrecognised.
|
||||
|
||||
:param str filename: The filename of the file to open.
|
||||
:param str filetype: The format of the given file.
|
||||
:param Callable[[float], None] progress: A callback that will be repeatedly called with an updated progress
|
||||
value if an import step occurs. Can be ``None`` if no progress is desired.
|
||||
:param Callable[[float], None] progress=None: **Optional parameter**. A callback that will be
|
||||
repeatedly called with an updated progress value if an import step occurs. Can be ``None`` if no
|
||||
progress is desired.
|
||||
Callback function signature must match :func:`ProgressCallback`.
|
||||
:return: The result of the operation.
|
||||
:rtype: ResultDetails
|
||||
)");
|
||||
virtual ResultDetails OpenFile(const rdcstr &filename, const rdcstr &filetype,
|
||||
RENDERDOC_ProgressCallback progress) = 0;
|
||||
RENDERDOC_ProgressCallback progress = NULL) = 0;
|
||||
|
||||
DOCUMENT(R"(Initialises the file handle from a raw memory buffer.
|
||||
|
||||
@@ -1611,14 +1617,15 @@ For the :paramref:`OpenBuffer.filetype` parameter, see :meth:`OpenFile`.
|
||||
|
||||
:param bytes buffer: The buffer containing the data to process.
|
||||
:param str filetype: The format of the given file.
|
||||
:param Callable[[float], None] progress: A callback that will be repeatedly called with an updated progress
|
||||
value if an import step occurs. Can be ``None`` if no progress is desired.
|
||||
:param Callable[[float], None] progress=None: **Optional parameter**. A callback that will be
|
||||
repeatedly called with an updated progress value if an import step occurs. Can be ``None`` if no
|
||||
progress is desired.
|
||||
Callback function signature must match :func:`ProgressCallback`.
|
||||
:return: The result of the operation.
|
||||
:rtype: ResultDetails
|
||||
)");
|
||||
virtual ResultDetails OpenBuffer(const bytebuf &buffer, const rdcstr &filetype,
|
||||
RENDERDOC_ProgressCallback progress) = 0;
|
||||
RENDERDOC_ProgressCallback progress = NULL) = 0;
|
||||
|
||||
DOCUMENT(R"(When a capture file is opened, an exclusive lock is held on the file on disk. This
|
||||
makes it impossible to copy the file to another location at the user's request. Calling this
|
||||
@@ -1641,18 +1648,21 @@ representation back to native RDC.
|
||||
|
||||
:param str filename: The filename to save to.
|
||||
:param str filetype: The format to convert to.
|
||||
:param SDFile file: An optional :class:`SDFile` with the structured data to source from. This is
|
||||
useful in case the format specifies that it doesn't need buffers, and you already have a
|
||||
:class:`ReplayController` open with the structured data. This saves the need to load the file
|
||||
again. If ``None`` then structured data will be fetched if not already present and used.
|
||||
:param Callable[[float], None] progress: A callback that will be repeatedly called with an updated progress
|
||||
value for the conversion. Can be ``None`` if no progress is desired.
|
||||
:param SDFile file=None: **Optional parameter**. An optional :class:`SDFile` with the structured
|
||||
data to source from. This is useful in case the format specifies that it doesn't need buffers, and
|
||||
you already have a :class:`ReplayController` open with the structured data. This saves the need to
|
||||
load the file again. If ``None`` then structured data will be fetched if not already present and
|
||||
used.
|
||||
:param Callable[[float], None] progress=None: **Optional parameter**. A callback that will be
|
||||
repeatedly called with an updated progress value for the conversion. Can be ``None`` if no progress
|
||||
is desired.
|
||||
Callback function signature must match :func:`ProgressCallback`.
|
||||
:return: The result of the operation.
|
||||
:rtype: ResultDetails
|
||||
)");
|
||||
virtual ResultDetails Convert(const rdcstr &filename, const rdcstr &filetype, const SDFile *file,
|
||||
RENDERDOC_ProgressCallback progress) = 0;
|
||||
virtual ResultDetails Convert(const rdcstr &filename, const rdcstr &filetype,
|
||||
const SDFile *file = NULL,
|
||||
RENDERDOC_ProgressCallback progress = NULL) = 0;
|
||||
|
||||
DOCUMENT(R"(Returns the list of capture file formats.
|
||||
|
||||
@@ -1733,15 +1743,16 @@ Once the replay is created, this :class:`CaptureFile` can be shut down, there is
|
||||
by the :class:`ReplayController`.
|
||||
|
||||
:param ReplayOptions opts: The options controlling how the capture should be replayed.
|
||||
:param Callable[[float], None] progress: A callback that will be repeatedly called with an updated progress
|
||||
value for the opening. Can be ``None`` if no progress is desired.
|
||||
:param Callable[[float], None] progress=None: **Optional parameter**. A callback that will be
|
||||
repeatedly called with an updated progress value for the opening. Can be ``None`` if no progress is
|
||||
desired.
|
||||
Callback function signature must match :func:`ProgressCallback`.
|
||||
:return: A tuple containing the status of opening the capture, whether success or failure, and the
|
||||
resulting :class:`ReplayController` handle if successful.
|
||||
:rtype: Tuple[ResultDetails,ReplayController]
|
||||
)");
|
||||
virtual rdcpair<ResultDetails, IReplayController *> OpenCapture(
|
||||
const ReplayOptions &opts, RENDERDOC_ProgressCallback progress) = 0;
|
||||
const ReplayOptions &opts, RENDERDOC_ProgressCallback progress = NULL) = 0;
|
||||
|
||||
DOCUMENT(R"(Returns the structured data for this capture.
|
||||
|
||||
|
||||
Reference in new issue
Block a user