rendertask method modified