Electronic device for generating three-dimensional photo based on images acquired from plurality of cameras, and method therefor
An example electronic device may display, based on at least a portion of a plurality of images obtained through a first camera of the electronic device, a preview image on the display; receive a shooting input while displaying the preview image; in response to receiving the shooting input, obtain a first image including a first visual object through the first camera; obtain a second image including a second visual object through a second camera of the electronic device; obtain a third image converted from the second image and including the second visual object having a size corresponding to a size of the first visual object; and obtain a fourth image to provide animation with respect to a subject, by displaying the third image after displaying the first image.
1 . An electronic device; comprising:
a display;
a plurality of cameras including a first camera having a first field-of-view (FoV) and a second camera having a second field-of-view (FoV) different from the first FoV of the first camera;
memory including one or more storage media storing instructions; and
at least one processor comprising processing circuitry; and
wherein the instructions, when executed by the at least one processor individually or collectively, cause the electronic device to:
display, based on at least a portion of a plurality of images obtained through the first camera, a preview image on the display, wherein each of the plurality of images includes a first visual object corresponding to a subject included in the first FoV;
receive a shooting input while displaying the preview image;
in response to receiving the shooting input, obtain a first image including the first visual object through the first camera and obtain a second image including a second visual object corresponding to the subject through the second camera;
obtain a third image, which includes the second visual object, by scaling a portion of the second image based on a distance between the electronic device and the subject so that the second visual object has a size corresponding to a size of the first visual object in the first image; and
obtain an animation with respect to the subject by displaying the third image after displaying the first image.
2 . The electronic device of claim 1 , comprising:
a sensor, and
wherein the instructions, when executed by the at least one processor individually or collectively, cause the electronic device to:
in response to receiving the shooting input, identify the distance between the electronic device and the subject using the sensor,
wherein the scaled portion of the second image has a FoV corresponding to the FoV of the first image and is determined based on the distance between the electronic device and the subject, and on a separation distance of the first camera and the second camera.
3 . The electronic device of claim 2 , wherein the instructions, when executed by the at least one processor individually or collectively, cause the electronic device to:
in a state that a plurality of subjects including the subject is included in the first FoV, display a plurality of visual objects respectively corresponding to the plurality of subjects in the preview image;
display a visual guide superimposed on the first visual object, in response to receiving an input for focusing the first visual object among the plurality of visual objects within the preview image; and
identify the distance between the electronic device and the subject indicated by the visual guide using the sensor, in response to receiving the shooting input after receiving the focusing input.
4 . The electronic device of claim 2 , wherein the instructions, when executed by the at least one processor individually or collectively, cause the electronic device to:
Scale the second image further based on at least one of a zoom factor of the first camera associated with the first image, or data indicating position relationship between the first FoV and the second FoV.
5 . The electronic device of claim 1 , wherein
wherein the instructions, when executed by the at least one processor individually or collectively, cause the electronic device to:
in response to receiving the shooting input,
identify, as the second camera, one of a plurality of different cameras of the electronic device, each having a FoV different from the first FoV of the first camera, which is disposed at a position where an image having a disparity with respect to the first image can be obtained.
6 . The electronic device of claim 1 , wherein the instructions, when executed by the at least one processor individually or collectively, cause the electronic device to:
in response to obtaining the first image, combine a third visual object that is different from the first visual object and the second visual object to the first image; and
in response to obtaining the second image, combine a fourth visual object that is obtained by converting the third visual object to provide an animation having a disparity with respect to the third visual object, to the second image.
7 . The electronic device of claim 1 , wherein the instructions, when executed by the at least one processor individually or collectively, cause the electronic device to:
in response to obtaining the first image and the third image, obtain one or more fourth images between the first image and the third image by an interpolating of the first image and the third image,
wherein the animation is obtained by displaying the one or more fourth images after displaying the third image.
8 . A method of an electronic device, comprising:
displaying, based on at least portion of a plurality of images obtained through a first camera among a plurality of cameras of the electronic device, a preview image on a display of the electronic device, wherein each of the plurality of images includes a first visual object corresponding to a subject included in a first field-of-view (FoV);
receiving a shooting input while displaying the preview image;
in response to receiving the shooting input, obtaining a first image including the first visual object through the first camera and
obtaining a second image including a second visual object corresponding to the subject through a second camera among the plurality of cameras different from the first camera;
obtaining a third image, which includes the second visual object, by scaling a portion of the second image based on a distance between the electronic device and the subject so that the second visual object has a size corresponding to a size of the first visual object in the first image; and
obtaining an animation with respect to the subject by displaying the third image after displaying the first image.
9 . The method of claim 8 , further comprising:
in response to receiving the shooting input, identifying the distance between the electronic device and the subject using a sensor of the electronic device,
wherein the scaled portion of the second image has a FoV corresponding to the FoV of the first image and is determined based on the distance between the electronic device and the subject, and on a separation distance of the first camera and the second camera.
10 . The method of claim 8 , wherein the displaying the preview image comprises:
in a state that a plurality of subjects including the subject is included in the first FoV, displaying a plurality of visual objects respectively corresponding to the plurality of subjects in the preview image, including the first visual object; and
displaying a visual guide superimposed on the first visual object in response to receiving an input for focusing the first visual object among the plurality of visual objects within the preview image,
wherein identifying the distance comprises:
identifying the distance between the electronic device and the subject indicated by the visual guide using a sensor, in response to receiving the shooting input after receiving the focusing input.
11 . The method of claim 8 ,
wherein the method further comprises:
in response to receiving the shooting input,
identifying, as the second camera, one of a plurality of different cameras of the electronic device, each having a FoV different from the first FoV of the first camera, which is disposed at a position where an image having a disparity with respect to the first image can be obtained.
12 . The method of claim 8 , further comprising:
in response to obtaining the first image, combining a third visual object that is different from the first visual object and the second visual object, to the first image; and
in response to obtaining the second image, combining a fourth visual object, that is obtained by converting the third visual object to provide an animation having a disparity with respect to the third visual object, to the second image.
13 . The method of claim 8 , further comprising:
in response to obtaining the first image and the third image, obtaining one or more fourth images between the first image and the third image, by an interpolating of the first image and the third image,
wherein the animation is obtained by displaying the one or more fourth images after displaying the third image.
14 . A non-transitory computer readable storage medium storing instructions, wherein the instructions, when executed by an electronic device including a display and a plurality of cameras including a first camera having a first field-of-view (FoV) and a second camera having a second field-of-view (FoV) different from the first FoV, cause the electronic device to:
display, based on at least a portion of a plurality of images obtained through the first camera, a preview image on the display, wherein each of the plurality of images includes a first visual object corresponding to a subject included in the first FoV;
receive a shooting input while displaying the preview image;
in response to receiving the shooting input, obtain a first image including the first visual object through the first camera and obtain a second image including a second visual object corresponding to the subject through the second camera;
obtain a third image, which includes the second visual object, by scaling a portion of the second image based on a distance between the electronic device and the subject so that the second visual object has a size corresponding to a size of the first visual object in the first image; and
obtain an animation with respect to the subject by displaying the third image after displaying the first image.
15 . The non-transitory computer readable storage medium of claim 14 , wherein the instructions, when executed by the electronic device of claim, cause the electronic device to:
in a state that a plurality of subjects including the subject is included in the first FoV, display a plurality of visual objects respectively corresponding to the plurality of subjects in the preview image;
display a visual guide superimposed on the first visual object, in response to receiving an input for focusing the first visual object among the plurality of visual objects within the preview image; and
identify the distance between the electronic device and the subject indicated by the visual guide using a sensor, in response to receiving the shooting input after receiving the focusing input.
16 . The non-transitory computer readable storage medium of claim 14 , wherein the instructions, when executed by the electronic device of claim, cause the electronic device to:
Scale the second image further based on at least one of a zoom factor of the first camera associated with the first image, or data indicating position relationship between the first FoV and the second FoV.
17 . The non-transitory computer readable storage medium of claim 14 , wherein the instructions, when executed by the electronic device of claim, cause the electronic device to:
in response to receiving the shooting input,
identify, as the second camera, one of a plurality of different cameras of the electronic device, each having a FoV different from the first FoV of the first camera, which is disposed at a position where an image having a disparity with respect to the first image can be obtained.