Lines Matching defs:generator

37 // Ref-counted tuple(SkImageGenerator, SkMutex) which allows sharing one generator among N images
69 // The following generator accessors are safe without acquiring the mutex (const getters).
96 // Helper for exclusive access to a shared generator.
183 ScopedGenerator generator(fSharedGenerator);
184 return generator->refEncodedData();
190 ScopedGenerator generator(fSharedGenerator);
191 return generator->isValid(context);
197 // TODO: can we do this more efficiently, by telling the generator we want to
227 // TODO: The correct thing is to clone the generator, and modify its color space. That's hard,
228 // because we don't have a clone method, and generator is public (and derived-from by clients).
244 sk_sp<SkImage> SkImage::MakeFromGenerator(std::unique_ptr<SkImageGenerator> generator) {
246 validator(SharedGenerator::Make(std::move(generator)), nullptr, nullptr);
354 // The pixels after yuv->rgb will be in the generator's color space.
356 // color space. To correct this, apply a color space conversion from the generator's color
360 ScopedGenerator generator(fSharedGenerator);
361 srcColorSpace = generator->getInfo().colorSpace();
378 ScopedGenerator generator(fSharedGenerator);
380 sk_sp<SkCachedData> data(SkYUVPlanesCache::FindAndRef(generator->uniqueID(), yuvaPixmaps));
388 if (!generator->queryYUVAInfo(supportedDataTypes, &yuvaPixmapInfo) ||
396 if (!generator->getYUVAPlanes(tempPixmaps)) {
409 * 2. Ask the generator to natively create one
410 * 3. Ask the generator to return YUV planes, which the GPU can convert
411 * 4. Ask the generator to return RGB(A) data, which the GPU can convert
475 // 2. Ask the generator to natively create one.
477 ScopedGenerator generator(fSharedGenerator);
478 if (auto view = generator->generateTexture(rContext,
488 // 3. Ask the generator to return YUV planes, which the GPU can convert. If we will be mipping
491 // TODO: Update to create the mipped surface in the textureProxyViewFromPlanes generator and
503 // 4. Ask the generator to return a bitmap, which the GPU can convert.