Home
last modified time | relevance | path

Searched refs:GrSamplerState (Results 1 – 25 of 223) sorted by relevance

123456789

/third_party/flutter/skia/src/gpu/
DGrTextureProducer.cpp37 if (copyParams.fFilter != GrSamplerState::Filter::kNearest) { in CopyOnGpu()
43 if (copyParams.fFilter == GrSamplerState::Filter::kNearest && !needsDomain && !resizing && in CopyOnGpu()
65 SkASSERT(copyParams.fFilter != GrSamplerState::Filter::kMipMap); in CopyOnGpu()
70 GrSamplerState samplerState(GrSamplerState::WrapMode::kClamp, copyParams.fFilter); in CopyOnGpu()
97 const GrSamplerState::Filter* filterModeOrNullForBicubic, in DetermineDomainMode()
123 case GrSamplerState::Filter::kNearest: in DetermineDomainMode()
130 case GrSamplerState::Filter::kBilerp: in DetermineDomainMode()
133 case GrSamplerState::Filter::kMipMap: in DetermineDomainMode()
200 const GrSamplerState::Filter* filterOrNullForBicubic) { in createFragmentProcessorForDomainAndFilter()
210 GrSamplerState::WrapMode wrapMode = in createFragmentProcessorForDomainAndFilter()
[all …]
DGrSamplerState.h16 class GrSamplerState {
21 static constexpr GrSamplerState ClampNearest() { return GrSamplerState(); } in ClampNearest()
22 static constexpr GrSamplerState ClampBilerp() { in ClampBilerp()
23 return GrSamplerState(WrapMode::kClamp, Filter::kBilerp); in ClampBilerp()
26 constexpr GrSamplerState() : GrSamplerState(WrapMode::kClamp, Filter::kNearest) {} in GrSamplerState() function
28 constexpr GrSamplerState(WrapMode wrapXAndY, Filter filter) in GrSamplerState() function
31 constexpr GrSamplerState(const WrapMode wrapModes[2], Filter filter) in GrSamplerState() function
34 constexpr GrSamplerState(const GrSamplerState&) = default;
36 GrSamplerState& operator=(const GrSamplerState& that) {
58 bool operator==(const GrSamplerState& that) const {
[all …]
DGrPrimitiveProcessor.cpp48 static inline GrSamplerState::Filter clamp_filter(GrTextureType type, in clamp_filter()
49 GrSamplerState::Filter requestedFilter) { in clamp_filter()
51 return SkTMin(requestedFilter, GrSamplerState::Filter::kBilerp); in clamp_filter()
57 const GrSamplerState& samplerState, in TextureSampler()
64 GrSamplerState::Filter filterMode, in TextureSampler()
65 GrSamplerState::WrapMode wrapXAndY, in TextureSampler()
71 const GrSamplerState& samplerState, in reset()
83 GrSamplerState::Filter filterMode, in reset()
84 GrSamplerState::WrapMode wrapXAndY, in reset()
87 fSamplerState = GrSamplerState(wrapXAndY, filterMode); in reset()
DGrFragmentProcessor.h416 TextureSampler(sk_sp<GrTextureProxy>, const GrSamplerState&);
419 GrSamplerState::Filter = GrSamplerState::Filter::kNearest,
420 GrSamplerState::WrapMode wrapXAndY = GrSamplerState::WrapMode::kClamp);
424 void reset(sk_sp<GrTextureProxy>, const GrSamplerState&);
426 GrSamplerState::Filter = GrSamplerState::Filter::kNearest,
427 GrSamplerState::WrapMode wrapXAndY = GrSamplerState::WrapMode::kClamp);
445 const GrSamplerState& samplerState() const { return fSamplerState; } in samplerState()
452 GrSamplerState fSamplerState;
DGrTextureProducer.h36 GrSamplerState::Filter fFilter;
71 const GrSamplerState::Filter* filterOrNullForBicubic) = 0;
86 sk_sp<GrTextureProxy> refTextureProxyForParams(const GrSamplerState&,
90 const GrSamplerState::Filter* filterOrNullForBicubic, SkScalar scaleAdjust[2]);
174 const GrSamplerState::Filter* filterModeOrNullForBicubic,
182 const GrSamplerState::Filter* filterOrNullForBicubic);
187 virtual sk_sp<GrTextureProxy> onRefTextureProxyForParams(const GrSamplerState&,
/third_party/flutter/skia/src/gpu/effects/
DGrSimpleTextureEffect.fp12 GrSamplerState samplerParams
28GrSamplerState(GrSamplerState::WrapMode::kClamp, GrSamplerState::Filter::kNearest)));
34 GrSamplerState::Filter filter) {
37 GrSamplerState(GrSamplerState::WrapMode::kClamp, filter)));
42 const GrSamplerState& p) {
50 samplerParams.wrapModeX() == GrSamplerState::WrapMode::kClampToBorder ||
51 samplerParams.wrapModeY() == GrSamplerState::WrapMode::kClampToBorder)
61 GrSamplerState::WrapMode wrapModes[2];
66 wrapModes[0] = GrSamplerState::WrapMode::kClamp;
67 wrapModes[1] = GrSamplerState::WrapMode::kClamp;
[all …]
DGrBicubicEffect.h51 static constexpr GrSamplerState::WrapMode kClampClamp[] = { in Make()
52 GrSamplerState::WrapMode::kClamp, GrSamplerState::WrapMode::kClamp}; in Make()
62 const GrSamplerState::WrapMode wrapModes[2], in Make()
78 const GrSamplerState::WrapMode wrapModes[2],
99 static const GrSamplerState::WrapMode kClampClamp[] = { in Make()
100 GrSamplerState::WrapMode::kClamp, GrSamplerState::WrapMode::kClamp}; in Make()
113 GrSamplerState::Filter* filterMode);
117 const GrSamplerState::WrapMode wrapModes[2], GrTextureDomain::Mode modeX,
DGrBicubicEffect.cpp166 const SkRect& domain, const GrSamplerState::WrapMode wrapModes[2], in GrBicubicEffect()
176 GrSamplerState(wrapModes, GrSamplerState::Filter::kNearest))
214 static const GrSamplerState::WrapMode kClampClamp[] = {GrSamplerState::WrapMode::kClamp, in TestCreate()
215 GrSamplerState::WrapMode::kClamp}; in TestCreate()
236 bool GrBicubicEffect::ShouldUseBicubic(const SkMatrix& matrix, GrSamplerState::Filter* filterMode) { in ShouldUseBicubic()
239 *filterMode = GrSamplerState::Filter::kNearest; in ShouldUseBicubic()
242 *filterMode = GrSamplerState::Filter::kBilerp; in ShouldUseBicubic()
245 *filterMode = GrSamplerState::Filter::kMipMap; in ShouldUseBicubic()
250 *filterMode = GrSamplerState::Filter::kNearest; in ShouldUseBicubic()
DGrDistanceFieldGeoProc.h67 const GrSamplerState& params, float lum, uint32_t flags, in Make()
76 const GrSamplerState& params, uint32_t flags, in Make()
97 void addNewProxies(const sk_sp<GrTextureProxy>* proxies, int numProxies, const GrSamplerState&);
107 const GrSamplerState& params,
151 const GrSamplerState& params, uint32_t flags) { in Make()
168 void addNewProxies(const sk_sp<GrTextureProxy>*, int numActiveProxies, const GrSamplerState&);
180 const GrSamplerState&, uint32_t flags);
229 const GrSamplerState& params, in Make()
250 void addNewProxies(const sk_sp<GrTextureProxy>*, int numActiveProxies, const GrSamplerState&);
258 int numActiveProxies, const GrSamplerState& params,
DGrTextureDomain.h84 static bool IsDecalSampled(GrSamplerState::WrapMode wrapX, GrSamplerState::WrapMode wrapY, in IsDecalSampled()
86 return wrapX == GrSamplerState::WrapMode::kClampToBorder || in IsDecalSampled()
87 wrapY == GrSamplerState::WrapMode::kClampToBorder || in IsDecalSampled()
92 static bool IsDecalSampled(const GrSamplerState::WrapMode wraps[2], Mode modeX, Mode modeY) { in IsDecalSampled()
96 static bool IsDecalSampled(const GrSamplerState& sampler, Mode modeX, Mode modeY) { in IsDecalSampled()
147 const GrSamplerState& sampler);
194 GrSamplerState::Filter filterMode);
201 const GrSamplerState& sampler);
230 const GrSamplerState&);
DGrYUVtoRGBEffect.h28 GrSamplerState::Filter filterMode,
44 const GrSamplerState::Filter filterModes[], int numPlanes, in GrYUVtoRGBEffect()
54 SkASSERT(filterModes[i] != GrSamplerState::Filter::kMipMap);
57 if (filterModes[i] != GrSamplerState::Filter::kNearest) {
68 GrSamplerState(GrSamplerState::WrapMode::kClamp, filterModes[i]));
/third_party/skia/src/gpu/
DGrSamplerState.h18 class GrSamplerState {
34 constexpr GrSamplerState() = default;
36 constexpr GrSamplerState(WrapMode wrapXAndY, Filter filter, MipmapMode mm = MipmapMode::kNone)
39 constexpr GrSamplerState(WrapMode wrapX,
45 constexpr GrSamplerState(const WrapMode wrapModes[2],
50 constexpr /*explicit*/ GrSamplerState(Filter filter) : fFilter(filter) {} in GrSamplerState() function
51 constexpr GrSamplerState(Filter filter, MipmapMode mm) : fFilter(filter), fMipmapMode(mm) {} in GrSamplerState() function
53 constexpr GrSamplerState(const GrSamplerState&) = default;
55 constexpr GrSamplerState& operator=(const GrSamplerState&) = default;
89 constexpr bool operator==(GrSamplerState that) const {
[all …]
/third_party/skia/src/gpu/effects/
DGrTextureEffect.h26 GrSamplerState::Filter = GrSamplerState::Filter::kNearest,
27 GrSamplerState::MipmapMode mipmapMode = GrSamplerState::MipmapMode::kNone);
34 const SkMatrix&, GrSamplerState,
53 GrSamplerState,
68 GrSamplerState,
88 GrSamplerState::WrapMode wx,
89 GrSamplerState::WrapMode wy,
100 GrSamplerState samplerState() const { return fSamplerState; } in samplerState()
148 static ShaderMode GetShaderMode(GrSamplerState::WrapMode,
149 GrSamplerState::Filter,
[all …]
DGrDistanceFieldGeoProc.h65 GrSamplerState params, in Make()
79 GrSamplerState params, in Make()
93 void addNewViews(const GrSurfaceProxyView* views, int numViews, GrSamplerState);
105 GrSamplerState params,
144 GrSamplerState params, uint32_t flags) { in Make()
155 void addNewViews(const GrSurfaceProxyView*, int numActiveViews, GrSamplerState);
169 GrSamplerState,
216 GrSamplerState params, in Make()
231 void addNewViews(const GrSurfaceProxyView*, int numActiveViews, GrSamplerState);
241 int numActiveViews, GrSamplerState params, DistanceAdjust wa,
DGrBicubicEffect.h55 const GrSamplerState::WrapMode wrapX,
56 const GrSamplerState::WrapMode wrapY,
68 const GrSamplerState::WrapMode wrapX,
69 const GrSamplerState::WrapMode wrapY,
82 const GrSamplerState::WrapMode wrapX,
83 const GrSamplerState::WrapMode wrapY,
DGrBicubicEffect.cpp128 const GrSamplerState::WrapMode wrapX, in Make()
129 const GrSamplerState::WrapMode wrapY, in Make()
133 GrSamplerState sampler(wrapX, wrapY, GrSamplerState::Filter::kNearest); in Make()
145 const GrSamplerState::WrapMode wrapX, in MakeSubset()
146 const GrSamplerState::WrapMode wrapY, in MakeSubset()
151 GrSamplerState sampler(wrapX, wrapY, GrSamplerState::Filter::kNearest); in MakeSubset()
164 const GrSamplerState::WrapMode wrapX, in MakeSubset()
165 const GrSamplerState::WrapMode wrapY, in MakeSubset()
179 GrSamplerState sampler(wrapX, wrapY, GrSamplerState::Filter::kNearest); in MakeSubset()
259 GrSamplerState::WrapMode wm[2]; in TestCreate()
/third_party/flutter/skia/src/gpu/effects/generated/
DGrSimpleTextureEffect.h23 GrSamplerState(GrSamplerState::WrapMode::kClamp, in Make()
24 GrSamplerState::Filter::kNearest))); in Make()
30 GrSamplerState::Filter filter) { in Make()
33 GrSamplerState(GrSamplerState::WrapMode::kClamp, filter))); in Make()
38 const GrSamplerState& p) { in Make()
51 GrSamplerState samplerParams) in GrSimpleTextureEffect()
56 GrSamplerState::WrapMode::kClampToBorder || in GrSimpleTextureEffect()
58 GrSamplerState::WrapMode::kClampToBorder)) in GrSimpleTextureEffect()
DGrSimpleTextureEffect.cpp73 GrSamplerState::WrapMode wrapModes[2]; in TestCreate()
78 wrapModes[0] = GrSamplerState::WrapMode::kClamp; in TestCreate()
79 wrapModes[1] = GrSamplerState::WrapMode::kClamp; in TestCreate()
82 GrSamplerState params(wrapModes, testData->fRandom->nextBool() in TestCreate()
83 ? GrSamplerState::Filter::kBilerp in TestCreate()
84 : GrSamplerState::Filter::kNearest); in TestCreate()
/third_party/skia/src/gpu/mtl/
DGrMtlSampler.mm19 GrSamplerState::WrapMode wrapMode, const GrCaps& caps) {
21 case GrSamplerState::WrapMode::kClamp:
23 case GrSamplerState::WrapMode::kRepeat:
25 case GrSamplerState::WrapMode::kMirrorRepeat:
27 case GrSamplerState::WrapMode::kClampToBorder:
45 GrMtlSampler* GrMtlSampler::Create(const GrMtlGpu* gpu, GrSamplerState samplerState) {
48 case GrSamplerState::Filter::kNearest: return MTLSamplerMinMagFilterNearest;
49 case GrSamplerState::Filter::kLinear: return MTLSamplerMinMagFilterLinear;
56 case GrSamplerState::MipmapMode::kNone: return MTLSamplerMipFilterNotMipmapped;
57 case GrSamplerState::MipmapMode::kNearest: return MTLSamplerMipFilterNearest;
[all …]
/third_party/flutter/skia/src/gpu/mtl/
DGrMtlSampler.mm17 GrSamplerState::WrapMode wrapMode, const GrCaps& caps) {
19 case GrSamplerState::WrapMode::kClamp:
21 case GrSamplerState::WrapMode::kRepeat:
23 case GrSamplerState::WrapMode::kMirrorRepeat:
25 case GrSamplerState::WrapMode::kClampToBorder:
39 GrMtlSampler* GrMtlSampler::Create(const GrMtlGpu* gpu, const GrSamplerState& samplerState,
47 GR_STATIC_ASSERT((int)GrSamplerState::Filter::kNearest == 0);
48 GR_STATIC_ASSERT((int)GrSamplerState::Filter::kBilerp == 1);
49 GR_STATIC_ASSERT((int)GrSamplerState::Filter::kMipMap == 2);
61 bool useMipMaps = GrSamplerState::Filter::kMipMap == samplerState.filter() && maxMipLevel > 0;
[all …]
/third_party/skia/src/gpu/vk/
DGrVkSampler.cpp13 static VkSamplerAddressMode wrap_mode_to_vk_sampler_address(GrSamplerState::WrapMode wrapMode) { in wrap_mode_to_vk_sampler_address()
15 case GrSamplerState::WrapMode::kClamp: in wrap_mode_to_vk_sampler_address()
17 case GrSamplerState::WrapMode::kRepeat: in wrap_mode_to_vk_sampler_address()
19 case GrSamplerState::WrapMode::kMirrorRepeat: in wrap_mode_to_vk_sampler_address()
21 case GrSamplerState::WrapMode::kClampToBorder: in wrap_mode_to_vk_sampler_address()
27 static VkSamplerMipmapMode mipmap_mode_to_vk_sampler_mipmap_mode(GrSamplerState::MipmapMode mm) { in mipmap_mode_to_vk_sampler_mipmap_mode()
32 case GrSamplerState::MipmapMode::kNone: return VK_SAMPLER_MIPMAP_MODE_LINEAR; in mipmap_mode_to_vk_sampler_mipmap_mode()
33 case GrSamplerState::MipmapMode::kNearest: return VK_SAMPLER_MIPMAP_MODE_NEAREST; in mipmap_mode_to_vk_sampler_mipmap_mode()
34 case GrSamplerState::MipmapMode::kLinear: return VK_SAMPLER_MIPMAP_MODE_LINEAR; in mipmap_mode_to_vk_sampler_mipmap_mode()
39 GrVkSampler* GrVkSampler::Create(GrVkGpu* gpu, GrSamplerState samplerState, in Create()
[all …]
/third_party/skia/src/gpu/ops/
DTextureOp.cpp134 SkRect normalize_and_inset_subset(GrSamplerState::Filter filter, in normalize_and_inset_subset()
147 if (filter == GrSamplerState::Filter::kNearest) { in normalize_and_inset_subset()
195 bool safe_to_ignore_subset_rect(GrAAType aaType, GrSamplerState::Filter filter, in safe_to_ignore_subset_rect()
203 filter == GrSamplerState::Filter::kNearest && in safe_to_ignore_subset_rect()
232 GrSamplerState::Filter filter, in Make()
233 GrSamplerState::MipmapMode mm, in Make()
248 GrSamplerState::Filter filter, in Make()
249 GrSamplerState::MipmapMode mm, in Make()
272 bool mipped = (fMetadata.mipmapMode() != GrSamplerState::MipmapMode::kNone); in visitProxies()
352 GrSamplerState::Filter filter, in Metadata()
[all …]
/third_party/skia/src/gpu/d3d/
DGrD3DResourceProvider.cpp124 static D3D12_TEXTURE_ADDRESS_MODE wrap_mode_to_d3d_address_mode(GrSamplerState::WrapMode wrapMode) { in wrap_mode_to_d3d_address_mode()
126 case GrSamplerState::WrapMode::kClamp: in wrap_mode_to_d3d_address_mode()
128 case GrSamplerState::WrapMode::kRepeat: in wrap_mode_to_d3d_address_mode()
130 case GrSamplerState::WrapMode::kMirrorRepeat: in wrap_mode_to_d3d_address_mode()
132 case GrSamplerState::WrapMode::kClampToBorder: in wrap_mode_to_d3d_address_mode()
138 static D3D12_FILTER d3d_filter(GrSamplerState sampler) { in d3d_filter()
141 case GrSamplerState::MipmapMode::kNone: in d3d_filter()
142 case GrSamplerState::MipmapMode::kNearest: in d3d_filter()
144 case GrSamplerState::Filter::kNearest: return D3D12_FILTER_MIN_MAG_MIP_POINT; in d3d_filter()
145 case GrSamplerState::Filter::kLinear: return D3D12_FILTER_MIN_MAG_LINEAR_MIP_POINT; in d3d_filter()
[all …]
/third_party/flutter/skia/src/gpu/vk/
DGrVkSampler.cpp14 GrSamplerState::WrapMode wrapMode) { in wrap_mode_to_vk_sampler_address()
16 case GrSamplerState::WrapMode::kClamp: in wrap_mode_to_vk_sampler_address()
18 case GrSamplerState::WrapMode::kRepeat: in wrap_mode_to_vk_sampler_address()
20 case GrSamplerState::WrapMode::kMirrorRepeat: in wrap_mode_to_vk_sampler_address()
22 case GrSamplerState::WrapMode::kClampToBorder: in wrap_mode_to_vk_sampler_address()
28 GrVkSampler* GrVkSampler::Create(GrVkGpu* gpu, const GrSamplerState& samplerState, in Create()
63 bool useMipMaps = GrSamplerState::Filter::kMipMap == samplerState.filter(); in Create()
127 GrVkSampler::Key GrVkSampler::GenerateKey(const GrSamplerState& samplerState, in GenerateKey()
/third_party/flutter/skia/gm/
Dtexturedomaineffect.cpp52 TextureDomainEffect(GrSamplerState::Filter filter) in TextureDomainEffect()
60 if (fFilter == GrSamplerState::Filter::kBilerp) { in onShortName()
62 } else if (fFilter == GrSamplerState::Filter::kMipMap) { in onShortName()
106 GrMipMapped mipMapped = fFilter == GrSamplerState::Filter::kMipMap && in onDraw()
136 if (fFilter != GrSamplerState::Filter::kNearest && in onDraw()
171 GrSamplerState::Filter fFilter;
176 DEF_GM(return new TextureDomainEffect(GrSamplerState::Filter::kNearest);)
177 DEF_GM(return new TextureDomainEffect(GrSamplerState::Filter::kBilerp);)
178 DEF_GM(return new TextureDomainEffect(GrSamplerState::Filter::kMipMap);)

123456789