Moves all frame data code into separate thread for smooth performance.