New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce postprocessing API #3645

Open
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
9 participants
@dmarcos
Copy link
Collaborator

dmarcos commented Jun 15, 2018

This is a proposal for a built-in post-processing API. Setting up post-processing in a comprehensive manner that works well in 2D and VR modes is not trivial to do. It requires tight integration with the render loop. A built-in effects API will help raise the visual quality of the content and will make very easy for everybody to experiment with the different effects while ensuring good performance. At first we would not have a public API for user defined effects since many are not suitable for stereo rendering. By providing the effects we can control how and what order are applied to guarantee consistent results and FPS. Once we settle on an API we can consider open it up.

The API is built by defining effect- prefixed scene level components for each effect. The order they are applied is fixed and independent on how and when they are defined. e.g:

  <a-scene effect-bloom="strength: 1.6" effect-sepia background="color: black">
      <a-box color="white" position="0 1.6 -2"></a-box>
  </a-scene>

This PR just contains a bloom and sepia effects but I will expand before merge. I would love to hear what effects people want to see first.

bloom

@ngokevin

This comment has been minimized.

Copy link
Member

ngokevin commented Jun 15, 2018

This PR just contains a bloom and sepia effects but I will expand before merge. I would love to hear what effects people want to see first.

SSAO please!

@ngokevin

This comment has been minimized.

Copy link
Member

ngokevin commented Jun 15, 2018

Having functionality based on a prefix and HTML attribute ordering is a bit magic. I would define the order effects: effects-bloom, effects-sepia.

@dmarcos

This comment has been minimized.

Copy link
Collaborator

dmarcos commented Jun 15, 2018

The order does NOT depend on attribute position. The order is fixed and will be documented. e.g: 1. tint, 2. vignette, 3. sepia, 4. bloom... it won’t be user configurable

@dmarcos

This comment has been minimized.

Copy link
Collaborator

dmarcos commented Jun 15, 2018

@feiss

This comment has been minimized.

Copy link
Contributor

feiss commented Jun 15, 2018

I would love to hear what effects people want to see first.

Santa is coming! :D My wish list, in order: SSAO, Screen space reflections, Chromatic Aberration, Noise/grain.

@zomboh

This comment has been minimized.

Copy link

zomboh commented Jun 16, 2018

This is awesome and will give webVR visuals a much needed push! feiss's list is pretty much it, I think those are the most needed (SSAO above all). As a super low-priority one I'd suggest a glitch/digital distortion effect.

@TechThomas

This comment has been minimized.

Copy link

TechThomas commented Jun 16, 2018

I would love to see effects related to simulations of how people would see aframe experiences with various vision problems. Filters for viewing red/green color blindness would be the first one I would appreciate! Reference: Be Kind to the Color Blind

@vylevylevyle

This comment has been minimized.

Copy link

vylevylevyle commented Jun 18, 2018

THANK YOU!!!!! SSAO, Screen Space Reflections, Chromatic Abberation, Motion Blur would definitely be wanted. PLEASE PLEASE ADD DoF for 2D!!!!!

@alfa256

This comment has been minimized.

Copy link

alfa256 commented Jun 18, 2018

Looks great, color grading/tonemapping/color curves or however you like to call it would be high on the list for me.

@musicscene

This comment has been minimized.

Copy link

musicscene commented Jul 6, 2018

Based on some basic paint.net effects I like, my favorites are:

Artistic - Ink, Oil, and Pencil
Blurs - Gaussian, Motion, Radial
Distortion - Crystalize, Tile Reflection, Dents
Style - Edge Detect, Emboss

All should be animatable! :)

@arpu

This comment has been minimized.

Copy link
Contributor

arpu commented Aug 22, 2018

looks very nice but why not use the soucecode from Threejs examples as import ?
like the https://github.com/mrdoob/three.js/blob/dev/examples/js/postprocessing/UnrealBloomPass.js

@arpu

This comment has been minimized.

Copy link
Contributor

arpu commented Aug 22, 2018

it would be possible with the webpack three plugin
mrdoob/three.js#9562 (comment)

@arpu

This comment has been minimized.

Copy link
Contributor

arpu commented Aug 26, 2018

or maybe using this threejs https://github.com/vanruesc/postprocessing
i only add some findings to this PR

some more shaders
https://github.com/libretro/glsl-shaders

@ngokevin ngokevin added this to the 0.9.0 milestone Sep 26, 2018

@dmarcos dmarcos modified the milestones: 0.9.0, 1.0.0 Oct 23, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment