async def blur(self, ctx, member: discord.Member = None): await ctx.trigger_typing() if member is None: member = ctx.author url = str( member.avatar_url_as(format="png", static_format="png", size=1024)) img = await self.bot.dagp.image_process(ImageFeatures.blur(), url) await ctx.send( file=discord.File(fp=img.image, filename=f"pixel.{img.format}"))
async def blur( self, ctx, thing: typing.Union[discord.Member, discord.PartialEmoji, discord.Emoji, str] = None, ): async with ctx.channel.typing(): url = await self.get_url(ctx, thing) img = await dagpi.image_process(ImageFeatures.blur(), url) file = discord.File(fp=img.image, filename=f"pixel.{img.format}") await ctx.send(file=file)
async def _blur(self, ctx, *, member: discord.Member): ''' Forgotten your glasses? ''' with ctx.channel.typing(): url = str( member.avatar_url_as(format="png", static_format="png", size=1024)) img = await self.dagpiclient.image_process(ImageFeatures.blur(), url) file = discord.File(fp=img.image, filename=f"blur.{img.format}") await ctx.send(file=file)
async def dag_blur(self, ctx: Context, *, item=None): """ Adds a blury effect to your image. """ meth = await self.do_dagpi(ctx, ImageFeatures.blur(), item) await self.dag_embed(ctx, meth, ctx.command.name)