@@ -97,11 +97,15 @@ STATIC mp_obj_t imagecapture_parallelimagecapture_capture(mp_obj_t self_in, mp_o
97
97
}
98
98
STATIC MP_DEFINE_CONST_FUN_OBJ_2 (imagecapture_parallelimagecapture_capture_obj , imagecapture_parallelimagecapture_capture );
99
99
100
- //| def continuous_capture_start(self, buffer1: WriteableBuffer, buffer2: WriteableBuffer) -> None:
100
+ //| def continuous_capture_start(self, buffer1: WriteableBuffer, buffer2: WriteableBuffer, / ) -> None:
101
101
//| """Begin capturing into the given buffers in the background.
102
102
//|
103
103
//| Call `continuous_capture_get_frame` to get the next available
104
- //| frame, and `continuous_capture_stop` to stop capturing."""
104
+ //| frame, and `continuous_capture_stop` to stop capturing.
105
+ //|
106
+ //| Until `continuous_capture_stop` (or `deinit`) is called, the
107
+ //| `ParallelImageCapture` object keeps references to ``buffer1`` and
108
+ //| ``buffer2``, so the objects will not be garbage collected."""
105
109
//| ...
106
110
//|
107
111
STATIC mp_obj_t imagecapture_parallelimagecapture_continuous_capture_start (mp_obj_t self_in , mp_obj_t buffer1 , mp_obj_t buffer2 ) {
@@ -125,7 +129,11 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_1(imagecapture_parallelimagecapture_continuous_ca
125
129
126
130
127
131
//| def continuous_capture_stop(self) -> None:
128
- //| """Stop continuous capture"""
132
+ //| """Stop continuous capture.
133
+ //|
134
+ //| Calling this method also causes the object to release its
135
+ //| references to the buffers passed to `continuous_capture_start`,
136
+ //| potentially allowing the objects to be garbage collected."""
129
137
//| ...
130
138
//|
131
139
STATIC mp_obj_t imagecapture_parallelimagecapture_continuous_capture_stop (mp_obj_t self_in ) {
0 commit comments