Home
last modified time | relevance | path

Searched refs:SkDescriptor (Results 1 – 25 of 81) sorted by relevance

1234

/third_party/skia/src/core/
DSkDescriptor.cpp16 std::unique_ptr<SkDescriptor> SkDescriptor::Alloc(size_t length) { in Alloc()
19 return std::unique_ptr<SkDescriptor>(new (allocation) SkDescriptor{}); in Alloc()
22 void SkDescriptor::operator delete(void* p) { ::operator delete(p); } in operator delete()
23 void* SkDescriptor::operator new(size_t) { in operator new()
27 void* SkDescriptor::addEntry(uint32_t tag, size_t length, const void* data) { in addEntry()
44 void SkDescriptor::computeChecksum() { in computeChecksum()
45 fChecksum = SkDescriptor::ComputeChecksum(this); in computeChecksum()
48 const void* SkDescriptor::findEntry(uint32_t tag, uint32_t* length) const { in findEntry()
64 std::unique_ptr<SkDescriptor> SkDescriptor::copy() const { in copy()
65 std::unique_ptr<SkDescriptor> desc = SkDescriptor::Alloc(fLength); in copy()
[all …]
DSkDescriptor.h18 class SkDescriptor : SkNoncopyable {
22 return sizeof(SkDescriptor) + entryCount * sizeof(Entry); in ComputeOverhead()
25 static std::unique_ptr<SkDescriptor> Alloc(size_t length);
42 SkASSERT(SkDescriptor::ComputeChecksum(this) == fChecksum); in assertChecksum()
48 std::unique_ptr<SkDescriptor> copy() const;
52 bool operator==(const SkDescriptor& other) const;
53 bool operator!=(const SkDescriptor& other) const { return !(*this == other); }
69 SkDescriptor() = default;
73 static uint32_t ComputeChecksum(const SkDescriptor* desc);
76 uint32_t fLength{sizeof(SkDescriptor)}; // must be second
[all …]
DSkScalerContext.h28 class SkDescriptor; variable
275 SkScalerContext(sk_sp<SkTypeface>, const SkScalerContextEffects&, const SkDescriptor*);
332 const SkDescriptor* desc);
334 static SkDescriptor* AutoDescriptorGivenRecAndEffects(
339 static std::unique_ptr<SkDescriptor> DescriptorGivenRecAndEffects(
362 static SkDescriptor* CreateDescriptorAndEffectsUsingPaint(
411 const SkDescriptor& desc);
DSkStrikeCache.h108 const SkDescriptor& getDescriptor() const override { in getDescriptor()
164 sk_sp<SkStrike> findStrike(const SkDescriptor& desc) SK_EXCLUDES(fLock);
195 sk_sp<SkStrike> internalFindStrikeOrNull(const SkDescriptor& desc) SK_REQUIRES(fLock);
219 static const SkDescriptor& GetKey(const sk_sp<SkStrike>& strike) { in GetKey()
222 static uint32_t Hash(const SkDescriptor& descriptor) { in Hash()
226 SkTHashTable<sk_sp<SkStrike>, SkDescriptor, StrikeTraits> fStrikeLookup SK_GUARDED_BY(fLock);
DSkRemoteGlyphCache.cpp40 static SkDescriptor* auto_descriptor_from_desc(const SkDescriptor* source_desc, in auto_descriptor_from_desc()
100 void writeDescriptor(const SkDescriptor& desc) { in writeDescriptor()
102 auto result = allocate(desc.getLength(), alignof(SkDescriptor)); in writeDescriptor()
135 if (descLength < sizeof(SkDescriptor)) return false; in readDescriptor()
138 auto* result = this->ensureAtLeast(descLength, alignof(SkDescriptor)); in readDescriptor()
224 size_t operator()(const SkDescriptor* key) const;
225 bool operator()(const SkDescriptor* lhs, const SkDescriptor* rhs) const;
227 size_t MapOps::operator()(const SkDescriptor* key) const { in operator ()()
231 bool MapOps::operator()(const SkDescriptor* lhs, const SkDescriptor* rhs) const { in operator ()()
247 const SkDescriptor& getDescriptor() const override { in getDescriptor()
[all …]
DSkStrikeSpec.h31 SkStrikeSpec(const SkDescriptor& descriptor, sk_sp<SkTypeface> typeface);
95 const SkDescriptor& descriptor() const { return *fAutoDescriptor.getDesc(); } in descriptor()
149 const SkDescriptor& descriptor() const;
DSkStrikeForGPU.h19 class SkDescriptor; variable
34 virtual const SkDescriptor& getDescriptor() const = 0;
/third_party/flutter/skia/src/core/
DSkDescriptor.cpp16 std::unique_ptr<SkDescriptor> SkDescriptor::Alloc(size_t length) { in Alloc()
18 return std::unique_ptr<SkDescriptor>(static_cast<SkDescriptor*>(::operator new (length))); in Alloc()
21 void SkDescriptor::operator delete(void* p) { ::operator delete(p); } in operator delete()
23 void* SkDescriptor::addEntry(uint32_t tag, size_t length, const void* data) { in addEntry()
40 void SkDescriptor::computeChecksum() { in computeChecksum()
41 fChecksum = SkDescriptor::ComputeChecksum(this); in computeChecksum()
44 const void* SkDescriptor::findEntry(uint32_t tag, uint32_t* length) const { in findEntry()
60 std::unique_ptr<SkDescriptor> SkDescriptor::copy() const { in copy()
61 std::unique_ptr<SkDescriptor> desc = SkDescriptor::Alloc(fLength); in copy()
66 bool SkDescriptor::operator==(const SkDescriptor& other) const { in operator ==()
[all …]
DSkDescriptor.h17 class SkDescriptor : SkNoncopyable {
21 return sizeof(SkDescriptor) + entryCount * sizeof(Entry); in ComputeOverhead()
24 static std::unique_ptr<SkDescriptor> Alloc(size_t length);
29 fLength = sizeof(SkDescriptor); in init()
41 SkASSERT(SkDescriptor::ComputeChecksum(this) == fChecksum); in assertChecksum()
47 std::unique_ptr<SkDescriptor> copy() const;
51 bool operator==(const SkDescriptor& other) const;
52 bool operator!=(const SkDescriptor& other) const { return !(*this == other); }
67 SkDescriptor() = default;
70 static uint32_t ComputeChecksum(const SkDescriptor* desc);
[all …]
DSkStrikeCache.h72 ExclusiveStrikePtr findStrikeExclusive(const SkDescriptor&);
75 const SkDescriptor& desc,
81 const SkDescriptor& desc,
87 bool desperationSearchForImage(const SkDescriptor& desc,
90 bool desperationSearchForPath(const SkDescriptor& desc, SkGlyphID glyphID, SkPath* path);
92 SkScopedStrike findOrCreateScopedStrike(const SkDescriptor& desc,
97 const SkDescriptor&, const SkScalerContextEffects&, const SkTypeface&);
131 Node* findAndDetachStrike(const SkDescriptor&);
133 const SkDescriptor& desc,
138 const SkDescriptor& desc,
DSkRemoteGlyphCache.h31 class SkDescriptor; variable
42 size_t operator()(const SkDescriptor* key) const;
43 bool operator()(const SkDescriptor* lhs, const SkDescriptor* rhs) const;
47 using SkDescriptorMap = std::unordered_map<const SkDescriptor*, T, SkDescriptorMapOperators,
51 std::unordered_set<const SkDescriptor*, SkDescriptorMapOperators, SkDescriptorMapOperators>;
145 SkScopedStrike findOrCreateScopedStrike(const SkDescriptor& desc,
162 SkGlyphCacheState* getOrCreateCache(const SkDescriptor& desc,
DSkStrikeCache.cpp23 const SkDescriptor& desc, in Node()
54 const SkDescriptor& getDescriptor() const override { in getDescriptor()
140 const SkDescriptor& desc, in CreateScalerContext()
157 const SkDescriptor& desc, const SkScalerContextEffects& effects, const SkTypeface& typeface) in findOrCreateStrikeExclusive()
162 auto SkStrikeCache::findOrCreateStrike(const SkDescriptor& desc, in findOrCreateStrike()
173 SkScopedStrike SkStrikeCache::findOrCreateScopedStrike(const SkDescriptor& desc, in findOrCreateScopedStrike()
261 SkExclusiveStrikePtr SkStrikeCache::findStrikeExclusive(const SkDescriptor& desc) { in findStrikeExclusive()
265 auto SkStrikeCache::findAndDetachStrike(const SkDescriptor& desc) -> Node* { in findAndDetachStrike()
279 static bool loose_compare(const SkDescriptor& lhs, const SkDescriptor& rhs) { in loose_compare()
305 bool SkStrikeCache::desperationSearchForImage(const SkDescriptor& desc, SkGlyph* glyph, in desperationSearchForImage()
[all …]
DSkScalerContext.h28 class SkDescriptor; variable
252 SkScalerContext(sk_sp<SkTypeface>, const SkScalerContextEffects&, const SkDescriptor*);
309 static SkDescriptor* MakeDescriptorForPaths(SkFontID fontID,
312 static SkDescriptor* AutoDescriptorGivenRecAndEffects(
317 static std::unique_ptr<SkDescriptor> DescriptorGivenRecAndEffects(
340 static SkDescriptor* CreateDescriptorAndEffectsUsingPaint(
392 const SkDescriptor& desc);
DSkRemoteGlyphCache.cpp30 static SkDescriptor* auto_descriptor_from_desc(const SkDescriptor* source_desc, in auto_descriptor_from_desc()
58 static const SkDescriptor* create_descriptor( in create_descriptor()
100 void writeDescriptor(const SkDescriptor& desc) { in writeDescriptor()
102 auto result = allocate(desc.getLength(), alignof(SkDescriptor)); in writeDescriptor()
135 if (descLength < sizeof(SkDescriptor)) return false; in readDescriptor()
138 auto* result = this->ensureAtLeast(descLength, alignof(SkDescriptor)); in readDescriptor()
176 size_t SkDescriptorMapOperators::operator()(const SkDescriptor* key) const { in operator ()()
180 bool SkDescriptorMapOperators::operator()(const SkDescriptor* lhs, const SkDescriptor* rhs) const { in operator ()()
199 SkGlyphCacheState(const SkDescriptor& descriptor,
210 const SkDescriptor& getDescriptor() const override { in getDescriptor()
[all …]
DSkStrikeInterface.h19 class SkDescriptor; variable
52 virtual const SkDescriptor& getDescriptor() const = 0;
100 virtual SkScopedStrike findOrCreateScopedStrike(const SkDescriptor& desc,
DSkScalerContext.cpp45 const SkDescriptor& desc) { in PreprocessRec()
76 const SkDescriptor* desc) in SkScalerContext()
869 const SkDescriptor* desc) in SkScalerContext_Empty()
896 extern SkScalerContext* SkCreateColorScalerContext(const SkDescriptor* desc);
899 const SkScalerContextEffects& effects, const SkDescriptor* desc, bool allowFailure) const in createScalerContext()
1109 SkDescriptor* SkScalerContext::MakeDescriptorForPaths(SkFontID typefaceID, in MakeDescriptorForPaths()
1119 SkDescriptor* SkScalerContext::CreateDescriptorAndEffectsUsingPaint( in CreateDescriptorAndEffectsUsingPaint()
1142 descSize += SkDescriptor::ComputeOverhead(entryCount); in calculate_size_and_flatten()
1148 SkDescriptor* desc) { in generate_descriptor()
1161 SkDescriptor* SkScalerContext::AutoDescriptorGivenRecAndEffects( in AutoDescriptorGivenRecAndEffects()
[all …]
/third_party/skia/tests/
DDescriptorTest.cpp17 static void SetLength(SkDescriptor* desc, size_t length) { desc->fLength = length; } in SetLength()
18 static void SetCount(SkDescriptor* desc, uint32_t count) { desc->fCount = count; } in SetCount()
22 const size_t size = sizeof(SkDescriptor); in DEF_TEST()
24 auto desc = SkDescriptor::Alloc(size); in DEF_TEST()
31 sizeof(SkDescriptor) + sizeof(SkDescriptor::Entry) + sizeof(SkScalerContextRec); in DEF_TEST()
33 auto desc = SkDescriptor::Alloc(size); in DEF_TEST()
46 sizeof(SkDescriptor) + sizeof(SkDescriptor::Entry) + sizeof(SkScalerContextRec); in DEF_TEST()
48 auto desc = SkDescriptor::Alloc(size + extra_space); in DEF_TEST()
61 const size_t size = sizeof(SkDescriptor) + 3 * sizeof(SkDescriptor::Entry) + in DEF_TEST()
64 auto desc = SkDescriptor::Alloc(size); in DEF_TEST()
[all …]
/third_party/flutter/skia/tests/
DDescriptorTest.cpp17 static void SetLength(SkDescriptor* desc, size_t length) { desc->fLength = length; } in SetLength()
21 const size_t size = sizeof(SkDescriptor); in DEF_TEST()
23 auto desc = SkDescriptor::Alloc(size); in DEF_TEST()
31 sizeof(SkDescriptor) + sizeof(SkDescriptor::Entry) + sizeof(SkScalerContextRec); in DEF_TEST()
33 auto desc = SkDescriptor::Alloc(size); in DEF_TEST()
47 sizeof(SkDescriptor) + sizeof(SkDescriptor::Entry) + sizeof(SkScalerContextRec); in DEF_TEST()
49 auto desc = SkDescriptor::Alloc(size + extra_space); in DEF_TEST()
63 const size_t size = sizeof(SkDescriptor) + 3 * sizeof(SkDescriptor::Entry) + in DEF_TEST()
66 auto desc = SkDescriptor::Alloc(size); in DEF_TEST()
81 sizeof(SkDescriptor) + sizeof(SkDescriptor::Entry) + sizeof(SkScalerContextRec) - 4; in DEF_TEST()
[all …]
/third_party/flutter/skia/src/gpu/text/
DGrStrikeCache.h31 GrTextStrike(const SkDescriptor& fontScalerKey);
77 static const SkDescriptor& GetKey(const GrTextStrike& strike) { in GetKey()
81 static uint32_t Hash(const SkDescriptor& desc) { return desc.getChecksum(); } in Hash()
109 sk_sp<GrTextStrike> getStrike(const SkDescriptor& desc) { in getStrike()
124 sk_sp<GrTextStrike> generateStrike(const SkDescriptor& desc) { in generateStrike()
131 using StrikeHash = SkTDynamicHash<GrTextStrike, SkDescriptor>;
/third_party/skia/src/gpu/text/
DGrStrikeCache.h62 static const SkDescriptor& GetKey(const sk_sp<GrTextStrike>& strike);
63 static uint32_t Hash(const SkDescriptor& strikeSpec);
66 using StrikeHash = SkTHashTable<sk_sp<GrTextStrike>, const SkDescriptor&, HashTraits>;
DGrStrikeCache.cpp34 const SkDescriptor& GrStrikeCache::HashTraits::GetKey(const sk_sp<GrTextStrike>& strike) { in GetKey()
38 uint32_t GrStrikeCache::HashTraits::Hash(const SkDescriptor& descriptor) { in Hash()
/third_party/flutter/skia/tools/fonts/
DRandomScalerContext.cpp17 class SkDescriptor;
23 const SkDescriptor*,
44 const SkDescriptor* desc, in RandomScalerContext()
148 const SkDescriptor* desc) const { in onCreateScalerContext()
/third_party/skia/tools/fonts/
DRandomScalerContext.cpp16 class SkDescriptor;
22 const SkDescriptor*,
42 const SkDescriptor* desc, in RandomScalerContext()
145 const SkScalerContextEffects& effects, const SkDescriptor* desc) const in onCreateScalerContext()
DTestTypeface.cpp31 class SkDescriptor;
152 const SkDescriptor* desc) in SkTestScalerContext()
196 const SkScalerContextEffects& effects, const SkDescriptor* desc) const in onCreateScalerContext()
/third_party/skia/src/ports/
DSkScalerContext_mac_ct.h33 class SkDescriptor; variable
44 SkScalerContext_Mac(sk_sp<SkTypeface_Mac>, const SkScalerContextEffects&, const SkDescriptor*);

1234