1. An image obtaining method applied to an electronic device, wherein the electronic device comprises an image capturing device, the method comprising: capturing M image frames of a first object by the image capturing device in a first time period, wherein M is an integer larger than or equal to 2; determining a first region in an i-th image frame of the M image frames based on a first preset rule; obtaining M sub-image frames from the M image frames based on information of the first region, wherein an i-th sub-image frame of the M sub-image frames is determined based on the i-th image frame and the information of the first region; obtaining a j-th image frame of the M image frames; and generating a first dynamic image of the first object by using the j-th image frame and the M sub-image frames, wherein i and j are each integers larger than or equal to 1 and smaller than or equal to M.