CN111223045B - Puzzle method, device and terminal equipment - Google Patents
Puzzle method, device and terminal equipment Download PDFInfo
- Publication number
- CN111223045B CN111223045B CN201911120026.9A CN201911120026A CN111223045B CN 111223045 B CN111223045 B CN 111223045B CN 201911120026 A CN201911120026 A CN 201911120026A CN 111223045 B CN111223045 B CN 111223045B
- Authority
- CN
- China
- Prior art keywords
- image
- user
- images
- characteristic information
- jigsaw
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T3/00—Geometric image transformations in the plane of the image
- G06T3/40—Scaling of whole images or parts thereof, e.g. expanding or contracting
- G06T3/4038—Image mosaicing, e.g. composing plane images from plane sub-images
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02P—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
- Y02P90/00—Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
- Y02P90/30—Computing systems specially adapted for manufacturing
Landscapes
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Processing Or Creating Images (AREA)
Abstract
Description
技术领域technical field
本申请属于图像处理技术领域,尤其涉及一种拼图方法、装置及终端设备。The present application belongs to the technical field of image processing, and in particular relates to a mosaic method, device and terminal equipment.
背景技术Background technique
随着桌上型计算机、笔记本电脑、手机、平板电脑、个人数字助理等终端设备的不断普及,在这些终端设备中安装文字处理软件、媒体播放软件、辅助设计软件、信息管理软件、美图软件等各种类型的应用软件来实现各种应用功能,已经成为一种流行趋势,为人们的日常生产和生活带来了极大便利。例如,蒙太奇图片制作(Andreamosaic)软件能将多张图像拼接形成一张目标图像的蒙太奇效果图,极具趣味性。With the continuous popularization of terminal equipment such as desktop computers, notebook computers, mobile phones, tablet computers, and personal digital assistants, word processing software, media player software, auxiliary design software, information management software, and Meitu software are installed in these terminal equipment. It has become a popular trend to realize various application functions by using various types of application software such as mobile phones, and it has brought great convenience to people's daily production and life. For example, Andreamosaic software can splice multiple images to form a montage rendering of a target image, which is very interesting.
然而,现有的图像处理软件是将一个文件夹中的所有图像都作为素材图像,然后以一种简单的图像组合方式拼接形成拼接效果图,无法随意更改素材图像,灵活性差。However, the existing image processing software uses all the images in a folder as material images, and then stitches them together in a simple way to form a stitching effect image. The material images cannot be changed arbitrarily, and the flexibility is poor.
申请内容application content
有鉴于此,本申请实施例提供了一种拼图方法、装置及终端设备,以解决现有的图像处理软件无法随意更改素材图像,灵活性差的问题。In view of this, the embodiment of the present application provides a collage method, device and terminal equipment to solve the problem that existing image processing software cannot change material images at will and has poor flexibility.
本申请实施例的第一方面提供了一种拼图方法,包括:The first aspect of the embodiment of the present application provides a puzzle method, including:
获取至少一个素材图集中所有素材图像的图像特征信息;Obtain image feature information of all material images in at least one material atlas;
将目标图像分割为与预设色域范围的宽度对应的预设数量个子图像区域,生成所述目标图像的拼图特征信息;dividing the target image into a preset number of sub-image regions corresponding to the width of the preset color gamut range, and generating mosaic feature information of the target image;
根据所述拼图特征信息和所述图像特征信息,从所述至少一个素材图集中筛选出图像特征信息与所述拼图特征信息相匹配的素材图像,作为选定素材图像;According to the collage feature information and the image feature information, select material images whose image feature information matches the collage feature information from the at least one material atlas as selected material images;
将所述选定素材图像拼接形成所述目标图像的拼接效果图。Stitching the selected material images to form a stitching effect map of the target image.
本申请实施例的第二方面提供了一种拼图装置,包括:The second aspect of the embodiment of the present application provides a jigsaw puzzle device, including:
获取模块,用于获取至少一个素材图集中所有素材图像的图像特征信息;An acquisition module, configured to acquire image feature information of all material images in at least one material atlas;
生成模块,用于将目标图像分割为与预设色域范围的宽度对应的预设数量个子图像区域,生成所述目标图像的拼图特征信息;A generating module, configured to divide the target image into a preset number of sub-image regions corresponding to the width of the preset color gamut range, and generate mosaic feature information of the target image;
筛选模块,用于根据所述拼图特征信息和所述图像特征信息,从所述至少一个素材图集中筛选出图像特征信息与所述拼图特征信息相匹配的素材图像,作为选定素材图像;A screening module, configured to, according to the collage feature information and the image feature information, filter out material images whose image feature information matches the collage feature information from the at least one material atlas as selected material images;
拼图模块,用于将所述选定素材图像拼接形成所述目标图像的拼接效果图。A mosaic module, configured to stitch the selected material images to form a mosaic effect map of the target image.
对应的预设数量个本申请实施例的第三方面提供了一种终端设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现如本申请实施例的第一方面所述拼图方法的步骤。The third aspect of the corresponding preset number of embodiments of the present application provides a terminal device, including a memory, a processor, and a computer program stored in the memory and operable on the processor, the processor The steps of the jigsaw puzzle method described in the first aspect of the embodiments of the present application are implemented when the computer program is executed.
本申请实施例的第四方面提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现如本申请实施例的第一方面所述拼图方法的步骤。The fourth aspect of the embodiment of the present application provides a computer-readable storage medium, the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the computer program described in the first aspect of the embodiment of the present application is implemented. Describe the steps of the jigsaw puzzle method.
本申请实施例通过获取至少一个素材图集中所有素材图像的图像特征信息,将目标图像分割为与预设色域范围的宽度对应的预设数量个子图像区域,生成目标图像的拼图特征信息,然后根据拼图特征信息和图像特征信息,从至少一个素材图集中筛选出图像特征信息与拼图特征信息相匹配的素材图像,作为选定素材图像,将选定素材图像拼接形成目标图像的拼接效果图,可以从至少一个素材图集中筛选出图像特征信息与拼图特征信息相匹配的素材图像,作为选定素材图像,并拼接形成目标图像的拼接效果图,灵活性好。In the embodiment of the present application, by acquiring the image feature information of all material images in at least one material atlas, the target image is divided into a preset number of sub-image regions corresponding to the width of the preset color gamut range, and the mosaic feature information of the target image is generated, and then According to the mosaic feature information and the image feature information, filter out the material image whose image feature information matches the mosaic feature information from at least one material atlas, as the selected material image, and stitch the selected material image to form a mosaic effect diagram of the target image, The material image whose image feature information matches the collage feature information can be selected from at least one material atlas, used as the selected material image, and spliced to form a splicing effect map of the target image, which has good flexibility.
附图说明Description of drawings
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application, the accompanying drawings that need to be used in the descriptions of the embodiments or the prior art will be briefly introduced below. Obviously, the accompanying drawings in the following description are only for the present application For some embodiments, those of ordinary skill in the art can also obtain other drawings based on these drawings without creative effort.
图1是本申请实施例提供的拼图方法的第一种流程示意图;Fig. 1 is a schematic flow chart of the first puzzle method provided by the embodiment of the present application;
图2是本申请实施例提供的图像预览界面的示意图;FIG. 2 is a schematic diagram of an image preview interface provided by an embodiment of the present application;
图3是本申请实施例提供的图集选择过程的示意图;FIG. 3 is a schematic diagram of an atlas selection process provided by an embodiment of the present application;
图4是本申请实施例提供的拼图方法的第二种流程示意图;Fig. 4 is a second schematic flow chart of the jigsaw puzzle method provided by the embodiment of the present application;
图5是本申请实施例提供的拼图方法的第三种流程示意图;Fig. 5 is a schematic flow chart of the third puzzle method provided by the embodiment of the present application;
图6是本申请实施例提供的拼图方法的第四种流程示意图;Fig. 6 is a schematic flowchart of the fourth puzzle method provided by the embodiment of the present application;
图7是本申请实施例提供的拼图方法的第五种流程示意图;Fig. 7 is a schematic flow chart of the fifth puzzle method provided by the embodiment of the present application;
图8是本申请实施例提供的拼图界面的示意图;Fig. 8 is a schematic diagram of a jigsaw puzzle interface provided by an embodiment of the present application;
图9是本申请实施例提供的拼图方法的第六种流程示意图;Fig. 9 is a schematic flowchart of the sixth puzzle method provided by the embodiment of the present application;
图10是本申请实施例提供的拼图方法的第七种流程示意图;Fig. 10 is a schematic flowchart of the seventh puzzle method provided by the embodiment of the present application;
图11是本申请实施例提供的拼图方法的第八种流程示意图;Fig. 11 is a schematic flow chart of the eighth puzzle method provided by the embodiment of the present application;
图12是本申请实施例提供的拼图装置的结构示意图;Fig. 12 is a schematic structural diagram of a jigsaw puzzle device provided in an embodiment of the present application;
图13是本申请实施例提供的终端设备的结构示意图。FIG. 13 is a schematic structural diagram of a terminal device provided by an embodiment of the present application.
具体实施方式Detailed ways
为了使本技术领域的人员更好地理解本申请方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚地描述,显然,所描述的实施例是本申请一部分的实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都应当属于本申请保护的范围。In order to enable those skilled in the art to better understand the solution of the application, the technical solution in the embodiment of the application will be clearly described below in conjunction with the drawings in the embodiment of the application. Obviously, the described embodiment is the Some examples, but not all examples. Based on the embodiments in this application, all other embodiments obtained by persons of ordinary skill in the art without creative efforts shall fall within the scope of protection of this application.
本申请的说明书和权利要求书及上述附图中的术语“包括”以及它们任何变形,意图在于覆盖不排他的包含。例如包含一系列步骤或单元的过程、方法或系统、产品或设备没有限定于已列出的步骤或单元,而是可选地还包括没有列出的步骤或单元,或可选地还包括对于这些过程、方法、产品或设备固有的其它步骤或单元。此外,术语“第一”、“第二”和“第三”等是用于区别不同对象,而非用于描述特定顺序。The terms "comprising" and any variations thereof in the specification and claims of the present application and the above drawings are intended to cover non-exclusive inclusion. For example, a process, method or system, product or equipment comprising a series of steps or units is not limited to the listed steps or units, but optionally also includes steps or units not listed, or optionally further includes Other steps or units inherent in these processes, methods, products or apparatus. In addition, the terms "first", "second", and "third", etc. are used to distinguish different objects, not to describe a specific order.
本申请实施例提供一种拼图方法,应用于包括显示屏和人机交互器件的桌上型计算机、笔记本电脑、手机、平板电脑、个人数字助理,或者,能够与显示屏和人机交互设备通信连接的计算机主机、(云)服务器等终端设备,具体可以由终端设备的处理器在运行相应的计算机程序时执行。所述拼图方法用于从素材图集中筛选出图像特征信息与拼图特征信息相匹配的素材图像,作为选定素材图像,并拼接形成所述目标图像的拼接效果图。The embodiment of the present application provides a collage method, which is applied to desktop computers, notebook computers, mobile phones, tablet computers, personal digital assistants including display screens and human-computer interaction devices, or can communicate with display screens and human-computer interaction devices The connected terminal devices such as computer hosts and (cloud) servers can specifically be executed by the processor of the terminal device when running the corresponding computer program. The collage method is used to select material images whose image feature information matches the collage feature information from the material atlas, as the selected material images, and splicing to form the splicing effect map of the target image.
在应用中,处理器可以是中央处理单元(Central Processing Unit,CPU),还可以是其他通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。In an application, the processor may be a central processing unit (Central Processing Unit, CPU), or other general-purpose processors, a digital signal processor (Digital Signal Processor, DSP), an application specific integrated circuit (Application Specific Integrated Circuit, ASIC) , Field-Programmable Gate Array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor, or the processor may be any conventional processor, or the like.
如图1所示,本申请实施例提供的拼图方法,包括:As shown in Figure 1, the jigsaw puzzle method provided by the embodiment of the present application includes:
步骤S101、获取至少一个素材图集中所有素材图像的图像特征信息。Step S101. Obtain image feature information of all material images in at least one material atlas.
在应用中,终端设备的存储介质中可以预先存储有至少一个用于进行拼图的素材图集,每个素材图集中可以仅包括同一类型的素材图像。在步骤S101中,可以根据用户的实际需要获取用户选择的至少一个素材图集中所有素材图像的图像特征信息。图像特征信息可以包括素材图像的大小和颜色值。In the application, the storage medium of the terminal device may pre-store at least one material atlas for collage, and each material atlas may only include material images of the same type. In step S101, image feature information of all material images in at least one material atlas selected by the user may be acquired according to the actual needs of the user. The image characteristic information may include the size and color value of the material image.
在一个实施例中,步骤S101包括:In one embodiment, step S101 includes:
获取用户选择的至少一个素材图集中所有素材图像的图像特征信息;其中,一个所述素材图集中包括同一类型的素材图像。Acquiring image feature information of all material images in at least one material atlas selected by the user; wherein, one of the material atlases includes material images of the same type.
在一个实施例中,步骤S101之前,包括:In one embodiment, before step S101, including:
在检测到用户对目标图像的拼图启动操作时,进入所述目标图像的拼图界面。When it is detected that the collage start operation of the user on the target image is detected, the collage interface of the target image is entered.
在应用中,目标图像可以是显示在终端设备的桌面界面、相册的图像预览界面、任意文件夹界面或拼图图片制作软件(例如,蒙太奇图片制作软件)界面中的图像。拼图启动操作可以是对目标图像或显示目标图像的界面的任意触发操作,可以根据实际需要进行设置。例如,可以在显示目标图像的界面中设置拼图启动按钮或图标,拼图启动操作可以是对拼图启动按钮或图标的点击、按压或触摸等任意触控操作。拼图启动操作还可以是语音控制操作或手势控制操作。In the application, the target image may be an image displayed on a desktop interface of a terminal device, an image preview interface of an album, an interface of any folder, or an interface of collage picture making software (for example, montage picture making software). The collage start operation may be any trigger operation on the target image or the interface displaying the target image, and may be set according to actual needs. For example, a puzzle start button or icon can be set in the interface displaying the target image, and the puzzle start operation can be any touch operation such as clicking, pressing or touching the puzzle start button or icon. The puzzle start operation may also be a voice control operation or a gesture control operation.
如图2所示,示例性的示出一个图像预览界面1,图像预览界面1中显示有目标图像11和拼图启动按钮12。As shown in FIG. 2 , an
在一个实施例中,步骤S101包括:In one embodiment, step S101 includes:
在检测到用户对拼图界面显示的图集选择区域的触发操作时,进入图集选择界面;Enter the gallery selection interface when the trigger operation of the user on the gallery selection area displayed on the collage interface is detected;
在检测到用户对所述图集选择界面显示的至少一个素材图集的选择操作时,获取用户选择的至少一个素材图集中所有素材图像的图像特征信息。When a user's selection operation on at least one material atlas displayed on the atlas selection interface is detected, image feature information of all material images in at least one material atlas selected by the user is acquired.
在应用中,图集选择区域可以是图集选择按钮或图标,触发操作可以是对图集选择按钮或图标的点击、按压或触摸等任意触控操作。选择操作可以是对图集选择界面显示的至少一个素材图集中任意素材图集中选择框的点击、按压或触摸等任意触控操作。触发操作或选择操作还可以是语音控制操作或手势控制操作。In the application, the gallery selection area may be a gallery selection button or icon, and the trigger operation may be any touch operation such as clicking, pressing or touching the gallery selection button or icon. The selection operation may be any touch operation such as clicking, pressing or touching a selection box in any material atlas in at least one material atlas displayed on the atlas selection interface. The trigger operation or selection operation may also be a voice control operation or a gesture control operation.
在应用中,用户完成素材图集选择之后,拼图界面中会按照用户的选择顺序显示用户选择的所有素材图集的缩略图,用户可以继续选择其他素材图集,也可以消对已经选择的素材图集的选择,每个素材图集的缩略图用于显示该素材图集中的部分素材图像。In the app, after the user completes the material atlas selection, the collage interface will display the thumbnails of all the material atlases selected by the user according to the user's selection order, and the user can continue to select other material atlases, or cancel the selected materials Atlas selection, the thumbnail of each material atlas is used to display part of the material images in the material atlas.
在应用中,用户可以按照自定义的优先级顺序选择素材图集,系统(即执行拼图方法的计算机程序或操作系统)会默认用户先选择的素材图集的优先级高于后选择的素材图集,在后续拼图过程中,系统会按照优先级顺序优先从优先级高的素材图集中筛选出可用于进行拼图的素材图像。In the application, the user can select material atlases according to a custom priority order, and the system (that is, the computer program or operating system that implements the mosaic method) will default to the priority of the material atlases selected by the user first over the material images selected later In the subsequent collage process, the system will filter out the material images that can be used for collage from the high-priority material atlas according to the order of priority.
如图3所示,示例性的示出图集选择过程的示意图。图3中示例性的示出拼图界面3中显示有图集选择区域31;图集选择界面32中显示有多个素材图集(图3中示例性的示意出六个可供选择的素材图集,分别表示为素材图集一、素材图集二、素材图集三、素材图集四、素材图集五、素材图集六),各素材图集中显示有选择框(图3中示例性的表示为距形框);用户完成素材图集选择操作之后,拼图界面3中按照用户的选择顺序显示用户选择的所有素材图集的缩略图(图3中示例性的示出两个素材图集,并在每个素材图集的缩略图中示意出该素材图集中的三张素材图像,分别表示为素材图像一、素材图像二和素材图像三)和图集选择区域31。As shown in FIG. 3 , it is a schematic diagram schematically showing an atlas selection process. Exemplary shown in Fig. 3
如图4所示,在一个实施例中,步骤S101之前,包括:As shown in Figure 4, in one embodiment, before step S101, including:
步骤S401、对待分类的素材图像进行图像识别,将包含相同元素的素材图像划分为同一类型;Step S401, perform image recognition on the material images to be classified, and classify the material images containing the same elements into the same type;
步骤S402、生成至少一个素材图集,将同一类型的素材图像加入同一素材图集。Step S402, generating at least one material atlas, and adding material images of the same type into the same material atlas.
在应用中,为了方便用户选择其需要的素材图集,需要预先对素材图像进行分类,将包含不同元素的素材图像划分为不同类型,将同一类型的素材图像加入同一素材图集中,用户可以对每个素材图集进行命名。素材图像中的元素可以是人脸或物品,素材图像中也可以包括由多种元素组成的特定场景。In the application, in order to facilitate users to select the material atlas they need, it is necessary to classify material images in advance, divide material images containing different elements into different types, and add material images of the same type to the same material atlas, and users can Each material atlas is named. Elements in the material image may be human faces or objects, and the material image may also include a specific scene composed of various elements.
如图5所示,在一个实施例中,步骤S401包括:As shown in Figure 5, in one embodiment, step S401 includes:
步骤S501、在检测到用户的模板素材图像选择操作时,获取用户选择的素材图像作为模板素材图像;Step S501, when the user's template material image selection operation is detected, the material image selected by the user is acquired as the template material image;
步骤S502、对所述模板素材图像进行图像识别,获取所述模板素材图像中的元素作为目标元素;Step S502, performing image recognition on the template material image, and acquiring elements in the template material image as target elements;
步骤S503、根据所述目标元素,对待分类的素材图像进行图像识别,将包含所述目标元素的素材图像划分为同一类型。Step S503 , performing image recognition on the material images to be classified according to the target elements, and classifying the material images containing the target elements into the same type.
在应用中,用户需要将包含某一特定元素的素材图像从待分类的素材图像中筛选出来并加入同一素材图集中时,可以选择一张包含该特定元素的素材图像作为模板素材图像,使得系统可以自动识别该模板素材图像中的特定元素,然后从众多待分类的素材图像中识别出包含该特定元素的其他素材图像。In the application, when the user needs to filter a material image containing a specific element from the material images to be classified and add it to the same material atlas, he can select a material image containing the specific element as a template material image, so that the system The specific element in the material image of the template can be automatically identified, and then other material images containing the specific element can be identified from many material images to be classified.
在应用中,在步骤S501中用户选择的素材图像可以为待分类或已分类的素材图像中的一张,模板素材图像选择操作可以是对用户选择的素材图像的任意触发操作。在步骤S502和步骤S503中,根据模板素材图像中元素类型的不同,可以采用相应的图像识别算法进行图像识别,例如,元素为人脸时,可以采用人脸识别算法;元素为物品时,可以采用物品识别算法;素材图像包括特定场景时,可以采用场景识别算法。In the application, the material image selected by the user in step S501 may be one of the material images to be classified or classified, and the template material image selection operation may be any trigger operation on the material image selected by the user. In steps S502 and S503, according to the different types of elements in the template material image, corresponding image recognition algorithms can be used for image recognition. For example, when the element is a face, the face recognition algorithm can be used; Object recognition algorithm; when the material image includes a specific scene, the scene recognition algorithm can be used.
在应用中,用户可以依次选择包含不同元素或场景的素材图像作为模板素材图像,使得系统可以依次根据各模板素材图像,依次生成不同的素材图集。用户也可以一次选择包含不同元素或场景的多个素材图像作为模板素材图像,使得系统可以一次根据所有模板素材图像,快速生成多个不同的素材图集。In the application, the user can sequentially select material images containing different elements or scenes as template material images, so that the system can sequentially generate different material atlases according to each template material image. Users can also select multiple material images containing different elements or scenes as template material images at one time, so that the system can quickly generate multiple different material atlases based on all template material images at one time.
步骤S102、将目标图像分割为与预设色域范围的宽度对应的预设数量个子图像区域,生成所述目标图像的拼图特征信息。Step S102 , dividing the target image into a preset number of sub-image regions corresponding to the width of the preset color gamut range, and generating mosaic feature information of the target image.
在应用中,预设色域范围可以由用户预先自定义设置,若用户预先未设置,则采用系统默认的色域范围或者采用用户上一次设置的色域范围。预设色域范围的宽度与子图像区域的数量和拼接形成目标图像所需的素材图像的数量负相关。预设色域范围越宽,需要的颜色分级越少,子图像区域的数量和所需素材图像的数量就越少,反之,子图像区域的数量和所需素材图像的数量就越少。In the application, the preset color gamut range can be pre-defined by the user. If the user does not set it in advance, the system default color gamut range or the color gamut range set by the user last time will be used. The width of the preset color gamut range is negatively related to the number of sub-image regions and the number of material images required to be stitched to form the target image. The wider the preset color gamut range, the less color grading is required, and the fewer sub-image regions and the number of footage images required, and vice versa.
在应用中,用户可以根据素材图像的数量自定义调整预设色域范围,例如,假若用户最开始设置的预设色域范围,使得目标图像被分割为第一数量(例如,80×60)个子图像区域,则对应需要第一数量张素材图像;若用户选择的素材图集中素材图像的数量不足,则用户可以调整预设色域范围,使预设色域范围更加宽泛,使得目标图像被分割为第二数量(例如,40×30)个子图像区域,则对应需要第二数量张素材图像;若用户选择的素材图集中素材图像的数量仍不足,则用户可以继续调整预设色域范围,直到用户选择的素材图集中素材图像的数量足够为止。在用户选择的素材图集中素材图像的数量不足且用户未调整预设色域范围的情况下,系统也可以默认采取复用素材图像的方式来完成拼图,根据实际需要在至少两个子图像区域设置同一素材图像,对同一素材图像进行重复利用。In the application, the user can customize and adjust the preset color gamut range according to the number of material images. For example, if the user initially sets the preset color gamut range, the target image is divided into the first number (for example, 80×60) sub-image area, corresponding to the first number of material images; if the number of material images in the material atlas selected by the user is insufficient, the user can adjust the preset color gamut to make the preset color gamut wider, so that the target image is captured Divided into a second number (for example, 40×30) of sub-image areas, the corresponding second number of material images is required; if the number of material images in the material atlas selected by the user is still insufficient, the user can continue to adjust the preset color gamut range , until the number of material images in the material atlas selected by the user is sufficient. If the number of material images in the material atlas selected by the user is insufficient and the user has not adjusted the preset color gamut range, the system can also adopt the method of multiplexing material images by default to complete the collage. According to actual needs, set in at least two sub-image areas The same material image, reuse the same material image.
在应用中,拼图界面显示有色域范围设置区域,色域范围设置区域可以为色域范围输入框、色域范围调节进度条、色域范围选择按钮或图标。In the application, the collage interface displays a color gamut range setting area, which can be a color gamut range input box, a color gamut range adjustment progress bar, a color gamut range selection button or an icon.
在应用中,拼图特征信息包括子图像区域的数量以及各子图像区域的大小和颜色值,在进行拼图时,一个子图像区域需要对应设置一张与该子图像区域的大小和颜色值匹配的素材图像。In the application, the collage feature information includes the number of sub-image areas and the size and color value of each sub-image area. Footage image.
步骤S103、根据所述拼图特征信息和所述图像特征信息,从所述至少一个素材图集中筛选出图像特征信息与所述拼图特征信息相匹配的素材图像,作为选定素材图像。Step S103 , according to the collage feature information and the image feature information, select material images whose image feature information matches the collage feature information from the at least one material atlas as selected material images.
在应用中,素材图集可以是用户选择的素材图集,也可以是系统默认选择的素材图集。素材图集中的素材图像的大小和颜色值不一定符合子图像区域的大小和颜色值,因此,需要筛选出图像特征信息与拼图特征信息相匹配的素材图像,作为选定素材图像进行拼图。In the application, the material atlas can be the material atlas selected by the user, or the material atlas selected by the system by default. The size and color value of the material image in the material atlas may not match the size and color value of the sub-image area. Therefore, it is necessary to filter out the material image whose image feature information matches the collage feature information, and then use it as the selected material image for collage.
步骤S104、将所述选定素材图像拼接形成所述目标图像的拼接效果图。Step S104, stitching the selected material images to form a stitching effect map of the target image.
在应用中,拼接效果图是由多个选定素材图像拼接形成的与目标图像的画面完全相同的图像。In the application, the mosaic effect image is an image that is completely identical to the frame of the target image formed by mosaicing multiple selected material images.
如图6所示,在一个实施例中,步骤S103包括:As shown in Figure 6, in one embodiment, step S103 includes:
步骤S601、根据每个所述子图像区域的颜色值,从所述至少一个素材图集中筛选出与每个所述子图像区域颜色值相匹配的素材图像,作为选定素材图像,一个所述子图像对应一个所述选定素材图像;Step S601. According to the color value of each sub-image area, select a material image matching the color value of each sub-image area from the at least one material atlas, as a selected material image, one of the The sub-image corresponds to one of said selected material images;
步骤S104包括:Step S104 includes:
步骤S602、根据每个所述子图像区域的大小,裁剪或放大与每个所述子图像区域对应的选定素材图像,使每个所述子图像区域与对应的选定素材图像的大小相同;Step S602, according to the size of each sub-image area, crop or enlarge the selected material image corresponding to each of the sub-image areas, so that each of the sub-image areas is the same size as the corresponding selected material image ;
步骤S603、根据每个所述子图像区域的位置,将与每个所述子图像区域对应的选定素材图像放置到所述目标图像中的对应位置,拼接形成所述目标图像的拼接效果图。Step S603, according to the position of each sub-image area, place the selected material image corresponding to each sub-image area in the corresponding position in the target image, and stitch to form a mosaic effect diagram of the target image .
在应用中,步骤S601中,颜色值相匹配是指颜色值相同或属于同一色域;步骤S602中,子图像区域和与其对应的选定素材图像的大小不相同时,需要裁剪或放大对应的选定素材图像,使二者的大小相同。裁剪的方式可以为居中裁剪或以选定素材图像中目标元素所在的位置为中心进行裁剪,使得裁剪之后的选定素材图像包含目标元素且与子图像区域的大小相同。In the application, in step S601, the matching of color values means that the color values are the same or belong to the same color gamut; Select the footage image so that both are the same size. The cropping method can be center cropping or cropping with the position of the target element in the selected material image as the center, so that the selected material image after cropping contains the target element and has the same size as the sub-image area.
如图7所示,在一个实施例中,步骤S103之后,包括:As shown in Figure 7, in one embodiment, after step S103, includes:
步骤S701、在拼图界面显示所述目标图像的拼图信息;其中,所述拼图信息包括形成所述拼接效果图的至少一个素材图集以及各素材图集中的选定素材图像在所述拼接效果图中的占比。Step S701, displaying the collage information of the target image on the collage interface; wherein, the collage information includes at least one material atlas forming the mosaic effect diagram and selected material images in each material atlas in the mosaic effect diagram proportion in.
在应用中,在拼接形成目标图像的拼接效果图之后,在拼图界面显示目标图像的拼图信息,拼图信息可以包括形成拼接效果图的至少一个素材图集以及各素材图集中的选定素材图像在拼接效果图中的占比,还可以包括拼接效果图的缩略图和目标图像的缩略图。In the application, after splicing to form the mosaic effect image of the target image, the mosaic information of the target image is displayed on the mosaic interface, and the mosaic information may include at least one material atlas forming the mosaic effect image and selected material images in each material atlas. The ratio in the stitching effect image may also include a thumbnail of the stitching effect image and a thumbnail of the target image.
如图8所示,示例性的示出拼图界面3中显示有图集选择区域31、拼接效果图的缩略图33、构成拼接效果图的素材图集(图3中示例性的示出两个素材图集,并在每个素材图集的缩略图中示意出该素材图集中的三张选定素材图像,分别表示为选定素材图像一、选定素材图像二和选定素材图像三)和各素材图集中的选定素材图像的在拼接效果图中的占比(图3中示例性的示出两个素材图集对应的占比分别为占比一和占比二)。As shown in FIG. 8 , an example shows that an
如图9所示,在一个实施例中,步骤S701之后,包括:As shown in Figure 9, in one embodiment, after step S701, includes:
步骤S901、当各素材图集中的选定素材图像在所述拼接效果图中的占比之和小于1时,提示用户更改所述预设色域范围或增加素材图像;Step S901, when the sum of the proportions of the selected material images in each material atlas in the mosaic effect map is less than 1, prompt the user to change the preset color gamut range or add material images;
步骤S902、当检测到用户的色域范围更改操作时,将所述目标图像分割为与更改后的预设色域范围的宽度对应的预设数量个子图像区域,重新生成所述目标图像的拼图特征信息;Step S902, when the user's color gamut change operation is detected, the target image is divided into a preset number of sub-image regions corresponding to the width of the changed preset color gamut range, and a collage of the target image is regenerated characteristic information;
步骤S903、当检测到用户的素材图像增加操作时,识别用户增加的图像的类型是否属于用户选择的至少一个素材图集中素材图像的类型,并提示识别结果;其中,所述素材图像增加操作包括图像拍摄操作或图像导入操作;Step S903, when the user's material image addition operation is detected, identify whether the type of the image added by the user belongs to the type of material image in at least one material atlas selected by the user, and prompt the identification result; wherein, the material image addition operation includes Image capture operation or image import operation;
步骤S904、当用户增加的图像的类型属于用户选择的至少一个素材图集中素材图像的类型时,提示用户是否将所述增加的图像作为新增的素材图像;Step S904, when the type of the image added by the user belongs to the type of material image in at least one material atlas selected by the user, prompting the user whether to use the added image as a newly added material image;
步骤S905、当检测到用户将所述增加的图像作为新增的素材图像的触发操作时,根据所述新增的素材图像更新所述拼接效果图和所述拼图信息。Step S905 , when it is detected that the user uses the added image as a trigger operation of the added material image, update the mosaic effect map and the collage information according to the added material image.
在应用中,在步骤S901中,当用户选择的至少一个素材图集中的素材图像的数量小于目标图像中子图像区域的数量时,拼接效果图为未完成的半成品,选定素材图像的在所述拼接效果图中的占比之和小于1,系统可以在拼图界面显示未完成的拼接效果图的缩略图,此时,系统会提示用户更改预设色域范围,用户可将预设色域范围调整为一个较宽泛的范围或者增加素材图像。在步骤S902中,用户更改预设色域范围之后,系统即根据更改之后的预设色域范围重新执行步骤S102~S104和S701。在步骤S903中,在用户启动相机应用执行图像拍摄操作拍摄图像,或者,通过无线(例如,WiFi或蓝牙)或有线(例如,USB接口)通信方式执行图像导入操作导入图像时,系统会采用图像识别算法自动识别用户增加的图像中元素的类型,然后提示用户识别结果。在步骤S905中,当用户将增加的图像作为新增的素材图像时,根据新增的素材图像的类型,将新增的素材图像加入相应的素材图集,并根据新增的素材图像重新执行步骤S103、S104和S701更新拼接效果图和拼图信息。In the application, in step S901, when the number of material images in at least one material atlas selected by the user is less than the number of sub-image regions in the target image, the mosaic effect image is an unfinished semi-finished product, and the selected material image in the If the sum of the ratios in the mosaic effect picture above is less than 1, the system can display the thumbnail of the unfinished mosaic effect picture on the collage interface. At this time, the system will prompt the user to change the preset color gamut range. Range adjustments for a wider range or augmented footage images. In step S902, after the user changes the preset color gamut range, the system re-executes steps S102-S104 and S701 according to the changed preset color gamut range. In step S903, when the user starts the camera application to perform an image capture operation to capture an image, or performs an image import operation to import an image through a wireless (for example, WiFi or Bluetooth) or wired (for example, USB interface) communication method to import an image, the system will use the image The recognition algorithm automatically recognizes the type of elements in the image added by the user, and then prompts the user for the recognition result. In step S905, when the user uses the added image as the newly added material image, according to the type of the newly added material image, add the newly added material image to the corresponding material atlas, and execute again according to the newly added material image Steps S103, S104 and S701 update the mosaic rendering and collage information.
如图10所示,在一个实施例中,步骤S701之后,包括:As shown in Figure 10, in one embodiment, after step S701, includes:
步骤S1001、当各素材图集中的选定素材图像的在所述拼接效果图中的占比之和小于1时,在所述拼图界面显示拉起拍照区域;Step S1001, when the sum of the proportions of the selected material images in each material atlas in the mosaic effect map is less than 1, display the pull-up photographing area on the collage interface;
步骤S1002、在检测到用户对所述拉起拍照区域的触发操作时,启动相机应用并进入相机预览界面;Step S1002, when the trigger operation of pulling up the photographing area by the user is detected, start the camera application and enter the camera preview interface;
步骤S1003、识别所述相机预览界面中显示的预览图像的类型是否属于用户选择的至少一个素材图集中素材图像的类型,并提示识别结果;Step S1003, identifying whether the type of the preview image displayed in the camera preview interface belongs to the type of the material image in at least one material atlas selected by the user, and prompting for the identification result;
步骤S1004、在检测到用户对所述预览图像的拍摄操作时,拍摄所述预览图像作为新增的素材图像;Step S1004, when detecting the user's shooting operation on the preview image, taking the preview image as a newly added material image;
步骤S1005、根据所述新增的素材图像更新所述拼接效果图和所述拼图信息。Step S1005, updating the mosaic effect image and the mosaic information according to the newly added material image.
在应用中,在步骤S1001中,当用户选择的至少一个素材图集中的素材图像的数量小于目标图像中子图像区域的数量时,拼接效果图为未完成的半成品,选定素材图像的在拼接效果图中的占比之和小于1,系统可以在拼图界面显示未完成的拼接效果图的缩略图,此时,系统会在拼图界面显示拉起拍照区域,拉起拍照区域可以是拉起拍照按钮或图标,使用户可通过拍照方式来增加素材图像。在步骤S1002中,系统检测到用户对拉起拍照区域的触发操作之后,即启动相机应用并进入相机预览界面。在步骤S1003中,系统会采用图像识别算法自动识别用户增加的图像中元素的类型,然后提示用户识别结果。在步骤S1004中,用户根据识别结果获知预览图像的类型属于用户选择的素材图集中素材图像的类型,可以作为素材图像之后,即可对预览图像执行拍摄操作,拍摄预览图像作为新增的素材图像。在步骤S1005中,根据新增的素材图像的类型,将新增的素材图像加入相应的素材图集,并根据新增的素材图像重新执行步骤S103、S104和S701更新拼接效果图和拼图信息。In the application, in step S1001, when the number of material images in at least one material atlas selected by the user is less than the number of sub-image regions in the target image, the mosaic rendering is an unfinished semi-finished product, and the selected material images are being mosaic The sum of the proportions in the effect map is less than 1, the system can display the thumbnail of the unfinished collage effect image on the collage interface, at this time, the system will display the pull-up photo area on the collage interface, and the pull-up photo area can be the pull-up photo A button or icon that enables users to add material images by taking pictures. In step S1002, after the system detects the user's trigger operation of pulling up the photographing area, it starts the camera application and enters the camera preview interface. In step S1003, the system uses an image recognition algorithm to automatically recognize the type of elements in the image added by the user, and then prompts the user for the recognition result. In step S1004, the user learns according to the recognition result that the type of the preview image belongs to the type of the material image in the material atlas selected by the user, and can be used as a material image, and then the preview image can be photographed, and the preview image can be taken as a newly added material image . In step S1005, according to the type of the newly-added material image, add the newly-added material image into the corresponding material atlas, and re-execute steps S103, S104 and S701 according to the newly-added material image to update the mosaic effect map and collage information.
在应用中,系统可以通过语音提示、灯光提示、声音提示和弹窗提示中的至少一种来发出提示。In the application, the system may issue prompts through at least one of voice prompts, light prompts, sound prompts and pop-up window prompts.
如图8所示,示例性的示出拼图界面3中显示有拉起拍照按钮34。As shown in FIG. 8 , it exemplarily shows that a pull-up
如图11所述,在一个实施例中,步骤S104之后,包括:As shown in Figure 11, in one embodiment, after step S104, includes:
步骤S1101、在检测到用户的预览操作时,显示所述拼接效果图的预览图;Step S1101, when a user's preview operation is detected, displaying a preview image of the mosaic effect image;
步骤S1102、在检测到用户对所述预览图中子图像区域的局部放大操作时,通过图像局部解析技术放大并显示位于所述子图像区域的选定素材图像。Step S1102 , when detecting the user's partial zoom-in operation on the sub-image area in the preview image, zoom in and display the selected material image located in the sub-image area by image partial analysis technology.
在应用中,在步骤S1101中,可以在拼图界面显示预览区域,预览区域可以是预览按钮或图标,预览操作可以是用户对预览区域的触发操作。在步骤S1102中,系统可以通过图像局部解析技术放大并显示用户想要放大的子图像区域中的选定素材图像。In the application, in step S1101, a preview area may be displayed on the collage interface, the preview area may be a preview button or icon, and the preview operation may be a user's trigger operation on the preview area. In step S1102, the system can enlarge and display the selected material image in the sub-image area that the user wants to enlarge by means of image local analysis technology.
如图8所示,示例性的示出拼图界面3中显示有预览按钮35。As shown in FIG. 8 , a
在一个实施例中,步骤S1102之后,包括:In one embodiment, after step S1102, include:
在检测到用户对位于所述子图像区域的选定素材图像的编辑操作时,对所述选定素材图像进行编辑。When an editing operation of the user on the selected material image located in the sub-image area is detected, the selected material image is edited.
在应用中,用户还可以对位于所述子图像区域的选定素材图像进行删除、替换、添加标识(例如,涂鸦)等编辑操作。In the application, the user can also perform editing operations such as deleting, replacing, and adding a logo (for example, graffiti) to the selected material image located in the sub-image area.
在一个实施例中,步骤S104之后,包括:In one embodiment, after step S104, including:
在所述目标图像中显示拼图启动区域;displaying a puzzle activation area in the target image;
在检测到用户对所述拼图启动区域的触发操作时,进入所述拼图界面;Entering the puzzle interface when a trigger operation of the puzzle activation area by the user is detected;
对用户选择的至少一个素材图集和用户未选择的素材图集进行区分显示;Differentiate and display at least one material atlas selected by the user and material atlases not selected by the user;
对选定素材图像和非选定素材图像进行区分显示。Display selected material images and non-selected material images separately.
在应用中,在拼接形成目标图像的拼接效果图之后,可以在目标图像中显示拼图启动区域,拼图启动区域可以是拼图启动按钮或图标,该拼图启动区域可以用于标识目标图像具有对应的拼接效果图,用户可以通过触发该拼图启动区域使系统显示拼图界面,从而可以在拼图界面中查看拼图信息。还可以对用户选择和未选择的素材图像进行区分显示,对选定素材图像和除选定素材图像之外的其他素材图像(即非选定素材图像)进行区分显示,以使用户获知哪个素材图集和素材图像被用于拼接形成拼接效果图,当用户需要对其他目标图像启动拼图操作,得到对应的拼接效果图时,可以不再选择已经用于形成拼接效果图的素材图集或素材图像。可以通过在不同素材图集或不同素材图像中设置区分标志来进行区分显示,区分标志可以包括不同图形、不同颜色和不同文字中的至少一种。In the application, after splicing to form the mosaic effect image of the target image, a mosaic activation area can be displayed in the target image, the mosaic activation area can be a mosaic activation button or an icon, and the mosaic activation area can be used to identify that the target image has a corresponding mosaic Effect picture, the user can trigger the collage start area to make the system display the collage interface, so that the collage information can be viewed in the collage interface. It is also possible to distinguish between the material images selected and unselected by the user, and to distinguish between the selected material images and other material images except the selected material images (that is, non-selected material images), so that the user can know which material The atlas and material images are used to stitch together to form a mosaic effect image. When the user needs to start the mosaic operation on other target images to obtain the corresponding mosaic effect image, he can no longer select the material atlas or material that has been used to form the mosaic effect image. image. Distinguished display can be performed by setting distinguishing marks in different material atlases or different material images, and the distinguishing marks can include at least one of different graphics, different colors and different texts.
本申请实施例通过获取至少一个素材图集中所有素材图像的图像特征信息,将目标图像分割为与预设色域范围的宽度对应的预设数量个子图像区域,生成目标图像的拼图特征信息,然后根据拼图特征信息和图像特征信息,从至少一个素材图集中筛选出图像特征信息与拼图特征信息相匹配的素材图像,作为选定素材图像,将选定素材图像拼接形成目标图像的拼接效果图,可以从至少一个素材图集中筛选出图像特征信息与拼图特征信息相匹配的素材图像,作为选定素材图像,并拼接形成目标图像的拼接效果图,灵活性好。In the embodiment of the present application, by acquiring the image feature information of all material images in at least one material atlas, the target image is divided into a preset number of sub-image regions corresponding to the width of the preset color gamut range, and the mosaic feature information of the target image is generated, and then According to the mosaic feature information and the image feature information, filter out the material image whose image feature information matches the mosaic feature information from at least one material atlas, as the selected material image, and stitch the selected material image to form a mosaic effect diagram of the target image, The material image whose image feature information matches the collage feature information can be selected from at least one material atlas, used as the selected material image, and spliced to form a splicing effect map of the target image, which has good flexibility.
应理解,上述实施例中各步骤的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。It should be understood that the sequence numbers of the steps in the above embodiments do not mean the order of execution, and the execution order of each process should be determined by its function and internal logic, and should not constitute any limitation to the implementation process of the embodiment of the present application.
如图12所示,本申请实施例提供一种拼图装置12,用于执行上述实施例中的拼图方法。拼图装置12可以是终端设备,也可以是终端设备的处理器中的虚拟装置(virtualappliance)。拼图装置12,包括:As shown in FIG. 12 , the embodiment of the present application provides a
获取模块121,用于获取至少一个素材图集中所有素材图像的图像特征信息;An
生成模块122,用于将目标图像分割为与预设色域范围的宽度对应的预设数量个子图像区域,生成所述目标图像的拼图特征信息;A
筛选模块123,用于根据所述拼图特征信息和所述图像特征信息,从所述至少一个素材图集中筛选出图像特征信息与所述拼图特征信息相匹配的素材图像,作为选定素材图像;A
拼图模块124,用于将所述选定素材图像拼接形成所述目标图像的拼接效果图。The
在一个实施例中,所述拼图装置还包括:In one embodiment, the puzzle device also includes:
显示模块,用于在检测到用户对目标图像的拼图启动操作时,进入所述目标图像的拼图界面。The display module is configured to enter the collage interface of the target image when it is detected that the user starts the collage operation on the target image.
在一个实施例中,所述拼图装置还包括:In one embodiment, the puzzle device also includes:
分类模块,用于对待分类的素材图像进行图像识别,将包含相同元素的素材图像划分为同一类型;The classification module is used to perform image recognition on the material images to be classified, and divide the material images containing the same elements into the same type;
图集生成模块,用于生成至少一个素材图集,将同一类型的素材图像加入同一素材图集。The atlas generating module is configured to generate at least one material atlas, and add material images of the same type into the same material atlas.
在一个实施例中,所述显示模块还用于在拼图界面显示所述目标图像的拼图信息;其中,所述拼图信息包括形成所述拼接效果图的至少一个素材图集以及各素材图集中的选定素材图像在所述拼接效果图中的占比。In one embodiment, the display module is further configured to display collage information of the target image on the collage interface; wherein, the collage information includes at least one material atlas forming the mosaic effect diagram and each material atlas The proportion of the selected material image in the mosaic effect image.
在一个实施例中,所述拼图装置还包括:In one embodiment, the puzzle device also includes:
提示模块,用于当各素材图集中的选定素材图像在所述拼接效果图中的占比之和小于1时,提示用户更改所述预设色域范围或增加素材图像;A prompt module, configured to prompt the user to change the preset color gamut range or add a material image when the sum of the proportions of the selected material images in each material atlas in the mosaic effect map is less than 1;
所述生成模块还用于当检测到用户的色域范围更改操作时,将所述目标图像分割为与更改后的预设色域范围的宽度对应的预设数量个子图像区域,重新生成所述目标图像的拼图特征信息;The generation module is also used to divide the target image into a preset number of sub-image regions corresponding to the width of the changed preset color gamut range when detecting the user's color gamut change operation, and regenerate the The puzzle feature information of the target image;
所述提示模块还用于当检测到用户的素材图像增加操作时,识别用户增加的图像的类型是否属于用户选择的至少一个素材图集中素材图像的类型,并提示识别结果;其中,所述素材图像增加操作包括图像拍摄操作或图像导入操作;The prompt module is also used to identify whether the type of image added by the user belongs to the type of material image in at least one material atlas selected by the user when the user's material image addition operation is detected, and prompt the recognition result; wherein, the material The image adding operation includes image capturing operation or image importing operation;
所述提示模块还用于当用户增加的图像的类型属于用户选择的至少一个素材图集中素材图像的类型时,提示用户是否将所述增加的图像作为新增的素材图像;The prompt module is also used to prompt the user whether to use the added image as a newly added material image when the type of the image added by the user belongs to the type of material image in at least one material atlas selected by the user;
更新模块,用于当检测到用户将所述增加的图像作为新增的素材图像的触发操作时,根据所述新增的素材图像更新所述拼接效果图和所述拼图信息。The update module is configured to update the mosaic effect diagram and the collage information according to the newly added material image when it is detected that the user uses the added image as a trigger operation of the newly added material image.
在一个实施例中,所述显示模块还用于:In one embodiment, the display module is also used for:
当各素材图集中的选定素材图像的在所述拼接效果图中的占比之和小于1时,在所述拼图界面显示拉起拍照区域;When the sum of the proportions of the selected material images in each material atlas in the mosaic effect diagram is less than 1, the picture-taking area is displayed on the mosaic interface;
在检测到用户对所述拉起拍照区域的触发操作时,启动相机应用并进入相机预览界面;When detecting the user's trigger operation on pulling up the camera area, start the camera application and enter the camera preview interface;
所述提示模块还用于识别所述相机预览界面中显示的预览图像的类型是否属于用户选择的至少一个素材图集中素材图像的类型,并提示识别结果;The prompting module is also used to identify whether the type of the preview image displayed in the camera preview interface belongs to the type of the material image in at least one material atlas selected by the user, and prompt the identification result;
所述拼图装置还包括:The jigsaw puzzle also includes:
拍摄模块,用于在检测到用户对所述预览图像的拍摄操作时,拍摄所述预览图像作为新增的素材图像;A photographing module, configured to photograph the preview image as a newly added material image when a user's photographing operation on the preview image is detected;
所述更新模块还用于根据所述新增的素材图像更新所述拼接效果图和所述拼图信息。The update module is further configured to update the mosaic effect image and the mosaic information according to the newly added material image.
在一个实施例中,所述拼图装置还包括:In one embodiment, the puzzle device also includes:
预览模块,用于在检测到用户的预览操作时,显示所述拼接效果图的预览图;A preview module, configured to display a preview image of the mosaic effect image when a user preview operation is detected;
放大模块,用于在检测到用户对所述预览图中子图像区域的局部放大操作时,通过图像局部解析技术放大并显示位于所述子图像区域的选定素材图像。The zoom-in module is configured to zoom in and display the selected material image located in the sub-image area by means of image local analysis technology when detecting the user's local zoom-in operation on the sub-image area in the preview image.
在一个实施例中,所述拼图装置还包括:In one embodiment, the puzzle device also includes:
编辑模块,用于在检测到用户对位于所述子图像区域的选定素材图像的编辑操作时,对所述选定素材图像进行编辑。The editing module is configured to edit the selected material image when detecting the user's editing operation on the selected material image located in the sub-image area.
在一个实施例中,所述显示模块还用于:In one embodiment, the display module is also used for:
在所述目标图像中显示拼图启动区域;displaying a puzzle activation area in the target image;
在检测到用户对所述拼图启动区域的触发操作时,进入所述拼图界面;Entering the puzzle interface when a trigger operation of the puzzle activation area by the user is detected;
对用户选择的素材图集和用户未选择的素材图集进行区分显示;Differentiate and display the material atlas selected by the user and the material atlas not selected by the user;
对符合拼图特征信息要求的素材图像和不符合拼图特性信息要求的素材图像进行区分显示。Distinguishing and displaying material images that meet the requirements of the collage characteristic information and material images that do not meet the requirements of the collage characteristic information.
在应用中,拼图装置中的各模块也可以是终端设备的处理器中的软件程序模块,也可以分别通过不同的处理器来实现,还可以通过处理器中的不同逻辑电路结构来实现。In the application, each module in the jigsaw puzzle device may also be a software program module in the processor of the terminal device, or may be implemented by different processors, or may be implemented by different logic circuit structures in the processor.
本申请实施例通过获取至少一个素材图集中所有素材图像的图像特征信息,将目标图像分割为与预设色域范围的宽度对应的预设数量个子图像区域,生成目标图像的拼图特征信息,然后根据拼图特征信息和图像特征信息,从至少一个素材图集中筛选出图像特征信息与拼图特征信息相匹配的素材图像,作为选定素材图像,将选定素材图像拼接形成目标图像的拼接效果图,可以从至少一个素材图集中筛选出图像特征信息与拼图特征信息相匹配的素材图像,作为选定素材图像,并拼接形成目标图像的拼接效果图,灵活性好。In the embodiment of the present application, by acquiring the image feature information of all material images in at least one material atlas, the target image is divided into a preset number of sub-image regions corresponding to the width of the preset color gamut range, and the mosaic feature information of the target image is generated, and then According to the mosaic feature information and the image feature information, filter out the material image whose image feature information matches the mosaic feature information from at least one material atlas, as the selected material image, and stitch the selected material image to form a mosaic effect diagram of the target image, The material image whose image feature information matches the collage feature information can be selected from at least one material atlas, used as the selected material image, and spliced to form a splicing effect map of the target image, which has good flexibility.
如图13所示,本申请的一个实施例还提供一种终端设备13,包括:处理器130、存储器131以及存储在所述存储器131中并可在所述处理器130上运行的计算机程序132,例如拼图程序。所述处理器130执行所述计算机程序132时实现上述各个拼图方法实施例中的步骤,例如图1所示的步骤S101至S104。或者,所述处理器130执行所述计算机程序132时实现上述各装置实施例中各模块的功能,例如图12所示模块121至124的功能。As shown in Figure 13, an embodiment of the present application also provides a
示例性的,所述计算机程序132可以被分割成一个或多个模块,所述一个或者多个模块被存储在所述存储器131中,并由所述处理器130执行,以完成本申请。所述一个或多个模块可以是能够完成特定功能的一系列计算机程序指令段,该指令段用于描述所述计算机程序132在所述终端设备13中的执行过程。例如,所述计算机程序132可以被分割成获取模块、生成模块、筛选模块、拼图模块,各模块具体功能如下:Exemplarily, the
获取模块,用于获取至少一个素材图集中所有素材图像的图像特征信息;An acquisition module, configured to acquire image feature information of all material images in at least one material atlas;
生成模块,用于将目标图像分割为与预设色域范围的宽度对应的预设数量个子图像区域,生成所述目标图像的拼图特征信息;A generating module, configured to divide the target image into a preset number of sub-image regions corresponding to the width of the preset color gamut range, and generate mosaic feature information of the target image;
筛选模块,用于根据所述拼图特征信息和所述图像特征信息,从所述至少一个素材图集中筛选出图像特征信息与所述拼图特征信息相匹配的素材图像,作为选定素材图像;A screening module, configured to, according to the collage feature information and the image feature information, filter out material images whose image feature information matches the collage feature information from the at least one material atlas as selected material images;
拼图模块,用于将所述选定素材图像拼接形成所述目标图像的拼接效果图。A mosaic module, configured to stitch the selected material images to form a mosaic effect map of the target image.
所述终端设备13可以是桌上型计算机、笔记本、掌上电脑及云端服务器等计算设备。所述终端设备可包括,但不仅限于,处理器130、存储器131。本领域技术人员可以理解,图13仅仅是终端设备13的示例,并不构成对终端设备13的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件,例如所述终端设备还可以包括输入输出设备、网络接入设备、总线等。The
所称处理器130可以是中央处理单元(Central Processing Unit,CPU),还可以是其他通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。The so-called
所述存储器131可以是所述终端设备13的内部存储单元,例如终端设备13的硬盘或内存。所述存储器131也可以是所述终端设备13的外部存储设备,例如所述终端设备13上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(Secure Digital,SD)卡,闪存卡(Flash Card)等。进一步地,所述存储器131还可以既包括所述终端设备13的内部存储单元也包括外部存储设备。所述存储器131用于存储所述计算机程序以及所述终端设备所需的其他程序和数据。所述存储器131还可以用于暂时地存储已经输出或者将要输出的数据。The
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将所述装置的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。实施例中的各功能单元、模块可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中,上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。另外,各功能单元、模块的具体名称也只是为了便于相互区分,并不用于限制本申请的保护范围。上述系统中单元、模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that for the convenience and brevity of description, only the division of the above-mentioned functional units and modules is used for illustration. In practical applications, the above-mentioned functions can be assigned to different functional units, Completion of modules means that the internal structure of the device is divided into different functional units or modules to complete all or part of the functions described above. Each functional unit and module in the embodiment may be integrated into one processing unit, or each unit may exist separately physically, or two or more units may be integrated into one unit, and the above-mentioned integrated units may adopt hardware It can also be implemented in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the protection scope of the present application. For the specific working processes of the units and modules in the above system, reference may be made to the corresponding processes in the aforementioned method embodiments, and details will not be repeated here.
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参见其它实施例的相关描述。In the above-mentioned embodiments, the descriptions of each embodiment have their own emphases, and for parts that are not detailed or recorded in a certain embodiment, refer to the relevant descriptions of other embodiments.
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。Those skilled in the art can appreciate that the units and algorithm steps of the examples described in conjunction with the embodiments disclosed herein can be implemented by electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are executed by hardware or software depends on the specific application and design constraints of the technical solution. Skilled artisans may use different methods to implement the described functions for each specific application, but such implementation should not be regarded as exceeding the scope of the present application.
在本申请所提供的实施例中,应该理解到,所揭露的装置/终端设备和方法,可以通过其它的方式实现。例如,以上所描述的装置/终端设备实施例仅仅是示意性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通讯连接可以是通过一些接口,装置或单元的间接耦合或通讯连接,可以是电性,机械或其它的形式。In the embodiments provided in this application, it should be understood that the disclosed apparatus/terminal device and method may be implemented in other ways. For example, the device/terminal device embodiments described above are only illustrative. For example, the division of the modules or units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units Or components may be combined or may be integrated into another system, or some features may be omitted, or not implemented. In another point, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of devices or units may be in electrical, mechanical or other forms.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, each unit may exist separately physically, or two or more units may be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.
所述集成的模块如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请实现上述实施例方法中的全部或部分流程,也可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一计算机可读存储介质中,该计算机程序在被处理器执行时,可实现上述各个方法实施例的步骤。其中,所述计算机程序包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读介质可以包括:能够携带所述计算机程序代码的任何实体或装置、记录介质、U盘、移动硬盘、磁碟、光盘、计算机存储器、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,RandomAccess Memory)、电载波信号、电信信号以及软件分发介质等。需要说明的是,所述计算机可读介质包含的内容可以根据司法管辖区内立法和专利实践的要求进行适当的增减,例如在某些司法管辖区,根据立法和专利实践,计算机可读介质不包括电载波信号和电信信号。If the integrated modules are realized in the form of software function units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments in the present application can also be completed by instructing related hardware through computer programs. The computer programs can be stored in a computer-readable storage medium, and the computer When the program is executed by the processor, the steps in the above-mentioned various method embodiments can be realized. Wherein, the computer program includes computer program code, and the computer program code may be in the form of source code, object code, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a U disk, a removable hard disk, a magnetic disk, an optical disk, a computer memory, and a read-only memory (ROM, Read-Only Memory) , random access memory (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software distribution medium, etc. It should be noted that the content contained in the computer-readable medium may be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, computer-readable media Excludes electrical carrier signals and telecommunication signals.
以上所述实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围,均应包含在本申请的保护范围之内。The above-described embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: it can still implement the foregoing embodiments Modifications to the technical solutions described in the examples, or equivalent replacements for some of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the various embodiments of the application, and should be included in the Within the protection scope of this application.
Claims (11)
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201911120026.9A CN111223045B (en) | 2019-11-15 | 2019-11-15 | Puzzle method, device and terminal equipment |
PCT/CN2020/125800 WO2021093623A1 (en) | 2019-11-15 | 2020-11-02 | Image splicing method and apparatus, and terminal device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201911120026.9A CN111223045B (en) | 2019-11-15 | 2019-11-15 | Puzzle method, device and terminal equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111223045A CN111223045A (en) | 2020-06-02 |
CN111223045B true CN111223045B (en) | 2023-06-30 |
Family
ID=70828991
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201911120026.9A Active CN111223045B (en) | 2019-11-15 | 2019-11-15 | Puzzle method, device and terminal equipment |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN111223045B (en) |
WO (1) | WO2021093623A1 (en) |
Families Citing this family (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111223045B (en) * | 2019-11-15 | 2023-06-30 | Oppo广东移动通信有限公司 | Puzzle method, device and terminal equipment |
CN111915744B (en) * | 2020-08-31 | 2024-09-27 | 深圳传音控股股份有限公司 | Interaction method, terminal and storage medium for augmented reality image |
CN114797084A (en) * | 2021-01-22 | 2022-07-29 | 北京字跳网络技术有限公司 | Graphic display method, apparatus, device and medium |
CN113599800B (en) * | 2021-08-17 | 2025-04-04 | 京东方科技集团股份有限公司 | Data interaction method, device, system and terminal operation equipment |
CN115098053A (en) * | 2022-06-24 | 2022-09-23 | 西安诺瓦星云科技股份有限公司 | Method, device, terminal device and storage medium for generating display screen configuration scheme |
CN115344933B (en) * | 2022-09-02 | 2025-10-03 | 北京搜房科技发展有限公司 | Floor map generation method and device, storage medium and electronic device |
CN119356634A (en) * | 2024-10-12 | 2025-01-24 | 维沃移动通信有限公司 | Wallpaper display method and device |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105578145A (en) * | 2015-12-30 | 2016-05-11 | 天津德勤和创科技发展有限公司 | Method for real-time intelligent fusion of three-dimensional virtual scene and video monitoring |
Family Cites Families (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2009129160A (en) * | 2007-11-22 | 2009-06-11 | Nikon Corp | Image processing device |
US9251763B2 (en) * | 2012-05-25 | 2016-02-02 | Picmonkey, Llc | System and method for image collage editing |
CN103634650B (en) * | 2013-11-06 | 2017-12-22 | 康佳集团股份有限公司 | A kind of image processing method and system based on intelligent television platform |
CN104637040B (en) * | 2013-11-12 | 2017-11-21 | 上海携程商务有限公司 | The method and device of picture splicing is realized using Photoshop |
CN103606159B (en) * | 2013-11-28 | 2017-06-13 | 广东威创视讯科技股份有限公司 | A kind of combination analysis method and system |
CN106780325B (en) * | 2016-11-29 | 2018-11-30 | 维沃移动通信有限公司 | A kind of picture joining method and mobile terminal |
CN107330858B (en) * | 2017-06-30 | 2020-12-04 | 北京乐蜜科技有限责任公司 | Picture processing method and device, electronic equipment and storage medium |
CN109064526A (en) * | 2018-06-07 | 2018-12-21 | 珠海格力电器股份有限公司 | Method and device for generating jigsaw puzzle |
CN111223045B (en) * | 2019-11-15 | 2023-06-30 | Oppo广东移动通信有限公司 | Puzzle method, device and terminal equipment |
-
2019
- 2019-11-15 CN CN201911120026.9A patent/CN111223045B/en active Active
-
2020
- 2020-11-02 WO PCT/CN2020/125800 patent/WO2021093623A1/en active Application Filing
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105578145A (en) * | 2015-12-30 | 2016-05-11 | 天津德勤和创科技发展有限公司 | Method for real-time intelligent fusion of three-dimensional virtual scene and video monitoring |
Also Published As
Publication number | Publication date |
---|---|
WO2021093623A1 (en) | 2021-05-20 |
CN111223045A (en) | 2020-06-02 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111223045B (en) | Puzzle method, device and terminal equipment | |
US8711228B2 (en) | Collaborative image capture | |
JP4752897B2 (en) | Image processing apparatus, image display method, and image display program | |
CN112954196B (en) | Shooting method, shooting device, electronic equipment and readable storage medium | |
US20110243397A1 (en) | Searching digital image collections using face recognition | |
US20110022982A1 (en) | Display processing device, display processing method, and display processing program | |
JP4940345B2 (en) | Electronic apparatus and image processing method | |
CN108924440B (en) | Sticker display method, device, terminal and computer-readable storage medium | |
JP2008165424A (en) | Image retrieval device and method, imaging device and program | |
US9405500B1 (en) | Photo album device and system | |
JP2016521418A (en) | Method and apparatus for generating and editing an image with an object inserted | |
US20110305437A1 (en) | Electronic apparatus and indexing control method | |
WO2022088823A1 (en) | Image processing method and apparatus | |
CN105163041A (en) | Method, device and mobile terminal for realizing partial double exposure | |
JP2014052915A (en) | Electronic apparatus, display control method, and program | |
US20110304644A1 (en) | Electronic apparatus and image display method | |
CN110704377B (en) | Multimedia file processing method and device, processor and electronic device | |
CN105376480A (en) | Image extracting apparatus and image extracting method | |
CN116628244A (en) | Image display method and device | |
CN114025237B (en) | Video generation method, device and electronic device | |
JP7566502B2 (en) | Imaging device, image capture processing method, program, and storage medium | |
CN108447035A (en) | Image optimization method, electronic device and computer-readable storage medium | |
US20140153836A1 (en) | Electronic device and image processing method | |
CN104618651A (en) | Photographing method and device | |
KR20140147461A (en) | Apparatas and method for inserting of a own contens in an electronic device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |