Home
last modified time | relevance | path

Searched refs:fStream (Results 1 – 25 of 82) sorted by relevance

1234

/third_party/skia/experimental/skrive/src/reader/
DBinaryReader.cpp21 : fStream(std::move(stream)) {} in BinaryReader()
25 const auto next_pos = fStream->getPosition() + sz, in validateSize()
26 block_end = fBlockStack.empty() ? fStream->getLength() in validateSize()
38 return validateSize(sizeof(v)) && fStream->readU8(&v) in readBool()
46 return validateSize(sizeof(v)) && fStream->readScalar(&v) in readFloat()
54 return validateSize(sizeof(v)) && fStream->readU8(&v) in readUInt8()
62 return validateSize(sizeof(v)) && fStream->readU16(&v) in readUInt16()
70 return validateSize(sizeof(v)) && fStream->readU32(&v) in readUInt32()
77 if (!validateSize(sizeof(length)) || !fStream->readU32(&length)) { in readString()
82 return validateSize(length) && fStream->read(str.writable_str(), length) == length in readString()
[all …]
/third_party/flutter/skia/tests/
DFakeStreams.h17 NotAssetMemStream(sk_sp<SkData> data) : fStream(std::move(data)) {} in NotAssetMemStream()
28 return fStream.peek(buf, bytes); in peek()
31 return fStream.read(buf, bytes); in read()
34 return fStream.rewind(); in rewind()
37 return fStream.isAtEnd(); in isAtEnd()
40 SkMemoryStream fStream;
51 , fStream(std::move(data)) in HaltingStream()
59 if (fStream.getPosition() + size > fLimit) { in read()
60 size = fLimit - fStream.getPosition(); in read()
63 return fStream.read(buffer, size); in read()
[all …]
DCodecExactReadTest.cpp31 : fStream(stream) in UnowningStream()
35 return fStream->read(buf, bytes); in read()
39 return fStream->rewind(); in rewind()
43 return fStream->isAtEnd(); in isAtEnd()
46 SkStream* fStream; // Unowned. member in __anonf4a477ef0111::UnowningStream
/third_party/skia/tests/
DFakeStreams.h17 NotAssetMemStream(sk_sp<SkData> data) : fStream(std::move(data)) {} in NotAssetMemStream()
28 return fStream.peek(buf, bytes); in peek()
31 return fStream.read(buf, bytes); in read()
34 return fStream.rewind(); in rewind()
37 return fStream.isAtEnd(); in isAtEnd()
40 SkMemoryStream fStream;
51 , fStream(std::move(data)) in HaltingStream()
59 if (fStream.getPosition() + size > fLimit) { in read()
60 size = fLimit - fStream.getPosition(); in read()
63 return fStream.read(buffer, size); in read()
[all …]
DCodecExactReadTest.cpp30 : fStream(stream) in UnowningStream()
34 return fStream->read(buf, bytes); in read()
38 return fStream->rewind(); in rewind()
42 return fStream->isAtEnd(); in isAtEnd()
45 SkStream* fStream; // Unowned. member in __anona1fbc8ba0111::UnowningStream
/third_party/flutter/skia/src/xml/
DSkXMLWriter.cpp199 SkXMLStreamWriter::SkXMLStreamWriter(SkWStream* stream) : fStream(*stream) in SkXMLStreamWriter()
208 fStream.writeText(" "); in onAddAttributeLen()
209 fStream.writeText(name); in onAddAttributeLen()
210 fStream.writeText("=\""); in onAddAttributeLen()
211 fStream.write(value, length); in onAddAttributeLen()
212 fStream.writeText("\""); in onAddAttributeLen()
219 fStream.writeText(">"); in onAddText()
220 fStream.newline(); in onAddText()
223 tab(fStream, fElems.count() + 1); in onAddText()
224 fStream.write(text, length); in onAddText()
[all …]
/third_party/skia/src/codec/
DSkStreamBuffer.cpp11 : fStream(std::move(stream)) in SkStreamBuffer()
14 , fHasLengthAndPosition(fStream->hasLength() && fStream->hasPosition()) in SkStreamBuffer()
30 const_cast<SkStream*>(fStream.get())->read(dst, bytesToBuffer); in get()
47 const size_t remaining = fStream->getLength() - fStream->getPosition() + fTrulyBuffered; in buffer()
51 const size_t bytesBuffered = fStream->read(fBuffer + fBytesBuffered, extraBytes); in buffer()
75 SkASSERT(length <= fStream->getLength() && in getDataAtPosition()
76 position <= fStream->getLength() - length); in getDataAtPosition()
78 const size_t oldPosition = fStream->getPosition(); in getDataAtPosition()
79 if (!fStream->seek(position)) { in getDataAtPosition()
85 const bool success = fStream->read(dst, length) == length; in getDataAtPosition()
[all …]
DSkRawCodec.cpp219 : fStream(std::move(stream)) in SkRawBufferedStream()
223 SkASSERT(!is_asset_stream(*fStream)); in SkRawBufferedStream()
253 if (fStream->skip(skipLength) != skipLength) { in transferBuffer()
256 const size_t bytesRead = fStream->read(data->writable_data(), size); in transferBuffer()
270 const size_t bytesRead = fStream->read(dst, remaining); in transferBuffer()
292 return SkStreamCopy(&fStreamBuffer, fStream.get()); in bufferMoreData()
307 const size_t bytesRead = fStream->read(tempBuffer.get(), sizeToRead); in bufferMoreData()
314 std::unique_ptr<SkStream> fStream; member in SkRawBufferedStream
326 : fStream(std::move(stream)) in SkRawAssetStream()
329 SkASSERT(is_asset_stream(*fStream)); in SkRawAssetStream()
[all …]
/third_party/flutter/skia/src/codec/
DSkStreamBuffer.cpp11 : fStream(std::move(stream)) in SkStreamBuffer()
14 , fHasLengthAndPosition(fStream->hasLength() && fStream->hasPosition()) in SkStreamBuffer()
30 const_cast<SkStream*>(fStream.get())->read(dst, bytesToBuffer); in get()
47 const size_t remaining = fStream->getLength() - fStream->getPosition() + fTrulyBuffered; in buffer()
51 const size_t bytesBuffered = fStream->read(fBuffer + fBytesBuffered, extraBytes); in buffer()
75 SkASSERT(length <= fStream->getLength() && in getDataAtPosition()
76 position <= fStream->getLength() - length); in getDataAtPosition()
78 const size_t oldPosition = fStream->getPosition(); in getDataAtPosition()
79 if (!fStream->seek(position)) { in getDataAtPosition()
85 const bool success = fStream->read(dst, length) == length; in getDataAtPosition()
[all …]
DSkRawCodec.cpp219 : fStream(std::move(stream)) in SkRawBufferedStream()
223 SkASSERT(!is_asset_stream(*fStream)); in SkRawBufferedStream()
253 if (fStream->skip(skipLength) != skipLength) { in transferBuffer()
256 const size_t bytesRead = fStream->read(data->writable_data(), size); in transferBuffer()
270 const size_t bytesRead = fStream->read(dst, remaining); in transferBuffer()
292 return SkStreamCopy(&fStreamBuffer, fStream.get()); in bufferMoreData()
307 const size_t bytesRead = fStream->read(tempBuffer.get(), sizeToRead); in bufferMoreData()
314 std::unique_ptr<SkStream> fStream; member in SkRawBufferedStream
326 : fStream(std::move(stream)) in SkRawAssetStream()
329 SkASSERT(is_asset_stream(*fStream)); in SkRawAssetStream()
[all …]
/third_party/skia/src/core/
DSkFontDescriptor.h22 : fStream(std::move(stream)), fIndex(index), fAxisCount(axisCount), fAxis(axisCount) in SkFontData()
29 : fStream(std::move(stream)), fIndex(args.getCollectionIndex()) in SkFontData()
38 : fStream(that.fStream->duplicate()) in SkFontData()
47 bool hasStream() const { return fStream != nullptr; } in hasStream()
48 std::unique_ptr<SkStreamAsset> detachStream() { return std::move(fStream); } in detachStream()
49 SkStreamAsset* getStream() { return fStream.get(); } in getStream()
50 SkStreamAsset const* getStream() const { return fStream.get(); } in getStream()
56 std::unique_ptr<SkStreamAsset> fStream;
81 bool hasStream() const { return bool(fStream); } in hasStream()
82 std::unique_ptr<SkStreamAsset> dupStream() const { return fStream->duplicate(); } in dupStream()
[all …]
DSkDocument.cpp12 SkDocument::SkDocument(SkWStream* stream) : fStream(stream), fState(kBetweenPages_State) {} in SkDocument()
56 this->onClose(fStream); in close()
59 fStream = nullptr; in close()
77 fStream = nullptr; in abort()
/third_party/skia/modules/audioplayer/
DSkAudioPlayer_oboe.cpp39 fStream = nullptr; in OboeAudioPlayer()
40 builder.openStream(fStream); in OboeAudioPlayer()
73 return fNumSampleFrames * fStream->getChannelCount() / fStream->getSampleRate(); in onGetDuration()
77 return (fReadFrameIndex * fStream->getChannelCount()) / fStream->getSampleRate(); in onGetTime()
81 fReadFrameIndex = (t * fStream->getSampleRate()) / fStream->getChannelCount(); in onSetTime()
87 case State::kPlaying: fStream->start(); break; in onSetState()
88 case State::kStopped: fStream->close(); break; in onSetState()
89 case State::kPaused : fStream->pause(); break; in onSetState()
107 std::shared_ptr<oboe::AudioStream> fStream; member in __anon44fbe6800111::OboeAudioPlayer
/third_party/skia/src/xml/
DSkXMLWriter.cpp194 : fStream(*stream) in SkXMLStreamWriter()
203 fStream.writeText(" "); in onAddAttributeLen()
204 fStream.writeText(name); in onAddAttributeLen()
205 fStream.writeText("=\""); in onAddAttributeLen()
206 fStream.write(value, length); in onAddAttributeLen()
207 fStream.writeText("\""); in onAddAttributeLen()
214 fStream.writeText(">"); in onAddText()
219 fStream.write(text, length); in onAddText()
227 fStream.writeText("</"); in onEndElement()
228 fStream.writeText(elem->fName.c_str()); in onEndElement()
[all …]
/third_party/flutter/skia/src/utils/
DSkFrontBufferedStream.cpp32 std::unique_ptr<SkStream> fStream; member in FrontBufferedStream
74 : fStream(std::move(stream)) in FrontBufferedStream()
75 , fHasLength(fStream->hasPosition() && fStream->hasLength()) in FrontBufferedStream()
76 , fLength(fStream->getLength() - fStream->getPosition()) in FrontBufferedStream()
89 return fStream->isAtEnd(); in isAtEnd()
127 const size_t buffered = fStream->read(buffer, bytesToBuffer); in bufferAndWriteTo()
146 const size_t bytesReadDirectly = fStream->read(dst, size); in readDirectlyFromStream()
195 if (size > 0 && fBufferedSoFar < fBufferSize && !fStream->isAtEnd()) { in read()
207 if (size > 0 && !fStream->isAtEnd()) { in read()
/third_party/skia/src/sksl/
DSkSLStringStream.h58 fStream.write8(b);
62 fStream.writeText(s);
66 fStream.write(s, size);
70 return fStream.bytesWritten();
75 sk_sp<SkData> data = fStream.detachAsData();
82 fStream.reset();
87 mutable SkDynamicMemoryWStream fStream;
/third_party/skia/client_utils/android/
DFrontBufferedStream.cpp39 std::unique_ptr<SkStream> fStream; member in __anonc0e9a16f0111::FrontBufferedStream
94 : fStream(std::move(stream)) in FrontBufferedStream()
95 , fHasLength(fStream->hasPosition() && fStream->hasLength()) in FrontBufferedStream()
96 , fLength(fStream->getLength() - fStream->getPosition()) in FrontBufferedStream()
116 return fStream->isAtEnd(); in isAtEnd()
154 const size_t buffered = fStream->read(buffer, bytesToBuffer); in bufferAndWriteTo()
173 const size_t bytesReadDirectly = fStream->read(dst, size); in readDirectlyFromStream()
223 if (size > 0 && fBufferedSoFar < fBufferSize && !fStream->isAtEnd()) { in read()
235 if (size > 0 && !fStream->isAtEnd()) { in read()
/third_party/flutter/skia/src/core/
DSkFontDescriptor.h21 : fStream(std::move(stream)), fIndex(index), fAxisCount(axisCount), fAxis(axisCount) in SkFontData()
28 : fStream(that.fStream->duplicate()) in SkFontData()
37 bool hasStream() const { return fStream.get() != nullptr; } in hasStream()
38 std::unique_ptr<SkStreamAsset> detachStream() { return std::move(fStream); } in detachStream()
39 SkStreamAsset* getStream() { return fStream.get(); } in getStream()
40 SkStreamAsset const* getStream() const { return fStream.get(); } in getStream()
46 std::unique_ptr<SkStreamAsset> fStream;
DSkDocument.cpp12 SkDocument::SkDocument(SkWStream* stream) : fStream(stream), fState(kBetweenPages_State) {} in SkDocument()
56 this->onClose(fStream); in close()
59 fStream = nullptr; in close()
77 fStream = nullptr; in abort()
/third_party/flutter/skia/src/sksl/
DSkSLStringStream.h54 fStream.write8(b);
58 fStream.writeText(s);
62 fStream.write(s, size);
67 sk_sp<SkData> data = fStream.detachAsData();
74 fStream.reset();
79 mutable SkDynamicMemoryWStream fStream;
/third_party/flutter/skia/experimental/ffmpeg/
DSkVideoEncoder.cpp175 fStream = avformat_new_stream(fFormatCtx, codec); in init()
176 SkASSERT(fStream); in init()
177 fStream->id = fFormatCtx->nb_streams-1; in init()
178 fStream->time_base = (AVRational){ 1, fps }; in init()
186 fEncoderCtx->time_base = fStream->time_base; in init()
206 if (check_err(avcodec_parameters_from_context(fStream->codecpar, fEncoderCtx))) { in init()
292 av_packet_rescale_ts(fPacket, fEncoderCtx->time_base, fStream->time_base); in sendFrame()
293 SkASSERT(fPacket->stream_index == fStream->index); in sendFrame()
/third_party/skia/tools/viewer/
DSKPSlide.cpp19 : fStream(std::move(stream)) { in SKPSlide()
42 if (!fStream) { in load()
46 fStream->rewind(); in load()
47 fPic = SkPicture::MakeFromStream(fStream.get()); in load()
/third_party/skia/experimental/ffmpeg/
DSkVideoEncoder.cpp174 fStream = avformat_new_stream(fFormatCtx, codec); in init()
175 SkASSERT(fStream); in init()
176 fStream->id = fFormatCtx->nb_streams-1; in init()
177 fStream->time_base = (AVRational){ 1, fps }; in init()
185 fEncoderCtx->time_base = fStream->time_base; in init()
205 if (check_err(avcodec_parameters_from_context(fStream->codecpar, fEncoderCtx))) { in init()
294 av_packet_rescale_ts(fPacket, fEncoderCtx->time_base, fStream->time_base); in sendFrame()
295 SkASSERT(fPacket->stream_index == fStream->index); in sendFrame()
/third_party/flutter/skia/src/images/
DSkJPEGWriteUtility.cpp24 if (!dest->fStream->write(dest->fBuffer, in sk_empty_output_buffer()
40 if (!dest->fStream->write(dest->fBuffer, size)) { in sk_term_destination()
45 dest->fStream->flush(); in sk_term_destination()
49 : fStream(stream) { in skjpeg_destination_mgr()
/third_party/skia/src/images/
DSkJPEGWriteUtility.cpp24 if (!dest->fStream->write(dest->fBuffer, in sk_empty_output_buffer()
40 if (!dest->fStream->write(dest->fBuffer, size)) { in sk_term_destination()
45 dest->fStream->flush(); in sk_term_destination()
49 : fStream(stream) { in skjpeg_destination_mgr()

1234