Lines Matching defs:buffer

120 static void writeAligned(void*& buffer, size_t& size, T value) {
121 size -= FlattenableUtils::align<alignof(T)>(buffer);
122 FlattenableUtils::write(buffer, size, value);
126 void*& buffer, size_t& size, int*& fds, size_t& count) const {
134 uint32_t& flags = *static_cast<uint32_t*>(buffer);
137 FlattenableUtils::advance(buffer, size, sizeof(uint32_t));
141 status_t err = mGraphicBuffer->flatten(buffer, size, fds, count);
143 size -= FlattenableUtils::align<4>(buffer);
147 status_t err = mFence->flatten(buffer, size, fds, count);
149 size -= FlattenableUtils::align<4>(buffer);
153 status_t err = mSurfaceDamage.flatten(buffer, size);
155 FlattenableUtils::advance(buffer, size, mSurfaceDamage.getFlattenedSize());
157 err = mHdrMetadata.flatten(buffer, size);
159 FlattenableUtils::advance(buffer, size, mHdrMetadata.getFlattenedSize());
166 writeAligned(buffer, size, mCrop);
167 writeAligned(buffer, size, mTransform);
168 writeAligned(buffer, size, mScalingMode);
169 writeAligned(buffer, size, low32(mTimestamp));
170 writeAligned(buffer, size, high32(mTimestamp));
171 writeAligned(buffer, size, mIsAutoTimestamp);
172 writeAligned(buffer, size, mDataSpace);
173 writeAligned(buffer, size, low32(mFrameNumber));
174 writeAligned(buffer, size, high32(mFrameNumber));
175 writeAligned(buffer, size, mSlot);
176 writeAligned(buffer, size, mIsDroppable);
177 writeAligned(buffer, size, mAcquireCalled);
178 writeAligned(buffer, size, mTransformToDisplayInverse);
179 writeAligned(buffer, size, mAutoRefresh);
180 writeAligned(buffer, size, mQueuedBuffer);
181 writeAligned(buffer, size, mIsStale);
182 writeAligned(buffer, size, mApi);
188 static void readAligned(const void*& buffer, size_t& size, T& value) {
189 size -= FlattenableUtils::align<alignof(T)>(buffer);
190 FlattenableUtils::read(buffer, size, value);
194 void const*& buffer, size_t& size, int const*& fds, size_t& count) {
201 FlattenableUtils::read(buffer, size, flags);
205 status_t err = mGraphicBuffer->unflatten(buffer, size, fds, count);
207 size -= FlattenableUtils::align<4>(buffer);
212 status_t err = mFence->unflatten(buffer, size, fds, count);
214 size -= FlattenableUtils::align<4>(buffer);
219 status_t err = mSurfaceDamage.unflatten(buffer, size);
221 FlattenableUtils::advance(buffer, size, mSurfaceDamage.getFlattenedSize());
223 err = mHdrMetadata.unflatten(buffer, size);
225 FlattenableUtils::advance(buffer, size, mHdrMetadata.getFlattenedSize());
235 readAligned(buffer, size, mCrop);
236 readAligned(buffer, size, mTransform);
237 readAligned(buffer, size, mScalingMode);
238 readAligned(buffer, size, timestampLo);
239 readAligned(buffer, size, timestampHi);
241 readAligned(buffer, size, mIsAutoTimestamp);
242 readAligned(buffer, size, mDataSpace);
243 readAligned(buffer, size, frameNumberLo);
244 readAligned(buffer, size, frameNumberHi);
246 readAligned(buffer, size, mSlot);
247 readAligned(buffer, size, mIsDroppable);
248 readAligned(buffer, size, mAcquireCalled);
249 readAligned(buffer, size, mTransformToDisplayInverse);
250 readAligned(buffer, size, mAutoRefresh);
251 readAligned(buffer, size, mQueuedBuffer);
252 readAligned(buffer, size, mIsStale);
253 readAligned(buffer, size, mApi);