Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: how to apply antialiasingLevel to RenderTarget?  (Read 1574 times)

0 Members and 1 Guest are viewing this topic.

jill

  • Newbie
  • *
  • Posts: 19
    • View Profile
how to apply antialiasingLevel to RenderTarget?
« on: November 17, 2016, 10:26:58 pm »
How to apply sf::ContextSettings antialiasingLevel to the sf::RenderTarget? This is good to make better quality window display, but the sf::RenderTarget results looks very aliasing.

Mr_Blame

  • Full Member
  • ***
  • Posts: 192
    • View Profile
    • Email
Re: how to apply antialiasingLevel to RenderTarget?
« Reply #1 on: November 24, 2016, 07:35:24 am »
The simplest solution to do this is writing the antialiasing shader and apply it on sf::Sprite, which uses sf::RenderTexture as its texture. Of course, if your rendering is simple and you render directly to the window, then you can set the antialising in context settings. To summarize, there is no way to apply default OpenGL antialising to any sf::RenderTarget(sf::Window and classes, which derive from or, are exceptions)
« Last Edit: November 24, 2016, 07:43:44 am by Mr_Blame »

 

anything