131 {
133 bytesWritten = 0;
134 bytesConsumed = 0;
136 nuint availableIn = (nuint)
source.Length;
137 while ((int)availableOut > 0)
138 {
140 {
141 byte* ptr2 = ptr;
143 {
144 byte* ptr4 = ptr3;
145 if (global::Interop.Brotli.BrotliEncoderCompressStream(
_state, operation, ref availableIn, &ptr2, ref availableOut, &ptr4, out UIntPtr _) == global::Interop.BOOL.FALSE)
146 {
148 }
149 bytesConsumed += source.Length - (int)availableIn;
150 bytesWritten += destination.Length - (int)availableOut;
151 if ((
int)availableOut == destination.Length && global::Interop.Brotli.BrotliEncoderHasMoreOutput(
_state) == global::Interop.BOOL.FALSE && availableIn == 0)
152 {
154 }
157 }
158 }
159 }
161 }
SafeBrotliEncoderHandle _state