added still buggy post processing functions