CN112367399A - Filter effect generation method and device, electronic device and storage medium - Google Patents

Filter effect generation method and device, electronic device and storage medium Download PDF

Info

Publication number
CN112367399A
CN112367399A CN202011248171.8A CN202011248171A CN112367399A CN 112367399 A CN112367399 A CN 112367399A CN 202011248171 A CN202011248171 A CN 202011248171A CN 112367399 A CN112367399 A CN 112367399A
Authority
CN
China
Prior art keywords
filter effect
target
filter
parameter
effect
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.)
Granted
Application number
CN202011248171.8A
Other languages
Chinese (zh)
Other versions
CN112367399B (en
Inventor
惠琳超
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Netease Hangzhou Network Co Ltd
Original Assignee
Netease Hangzhou Network Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Netease Hangzhou Network Co Ltd filed Critical Netease Hangzhou Network Co Ltd
Priority to CN202011248171.8A priority Critical patent/CN112367399B/en
Publication of CN112367399A publication Critical patent/CN112367399A/en
Application granted granted Critical
Publication of CN112367399B publication Critical patent/CN112367399B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • H04L67/025Protocols based on web technology, e.g. hypertext transfer protocol [HTTP] for remote control or remote monitoring of applications
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/2866Architectures; Arrangements
    • H04L67/30Profiles

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Image Processing (AREA)

Abstract

The disclosure provides a filter effect generation method and device, electronic equipment and a storage medium, and relates to the technical field of computers. The filter effect generation method comprises the following steps: responding to the selection operation of a target filter effect, and determining a target configuration file corresponding to the target filter effect; determining original filter parameters corresponding to the target filter effect according to the target configuration file; acquiring a pre-configured filter parameter table, and converting the original filter parameters into target filter parameters according to the filter parameter table; and generating the target filter effect according to the target configuration file and the target filter parameters. The technical scheme of the embodiment of the disclosure can improve the diversity of the filter effect of the client and improve the user experience.

Description

Filter effect generation method and device, electronic device and storage medium
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a filter effect generation method and apparatus, an electronic device, and a storage medium.
Background
With the development of internet technology, people increasingly like to communicate daily through videos or facial expression packages, rather than just meeting the requirements of text expression. Furthermore, various mobile application products which take the camera as a core and are rich in various novel filter effects are continuously emerged, and even a set of complete ecological industry is formed.
At present, in a related filter effect generation scheme, or based on a filter algorithm provided by a mobile terminal, a user can select a desired filter effect to perform basic filter processing on a shot picture; or the picture is copied to professional image processing software to carry out filter processing on the picture. However, the two methods both need to design a complex filter algorithm, so that the development cost of the filter effect is high, and the development period is long; in addition, because the filter effect is different in filter parameters corresponding to different platforms, there are limitations in terms of hardware and programs in the display of the filter effect, so that the client cannot restore the filter effect designed by the design end.
It is to be noted that the information disclosed in the above background section is only for enhancement of understanding of the background of the present disclosure, and thus may include information that does not constitute prior art known to those of ordinary skill in the art.
Disclosure of Invention
An object of the embodiments of the present disclosure is to provide a filter effect generation method, a filter effect generation apparatus, an electronic device, and a computer-readable storage medium, so as to overcome, at least to a certain extent, the problems that the filter effect development cost is high and the development period is long in the related technical solutions, and a user cannot accurately restore the filter effect designed at a design end.
Additional features and advantages of the disclosure will be set forth in the detailed description which follows, or in part will be obvious from the description, or may be learned by practice of the disclosure.
According to a first aspect of the embodiments of the present disclosure, there is provided a filter effect generation method applied to a mobile terminal device, including:
responding to the selection operation of a target filter effect, and determining a target configuration file corresponding to the target filter effect;
determining original filter parameters corresponding to the target filter effect according to the target configuration file;
acquiring a pre-configured filter parameter table, and converting the original filter parameters into target filter parameters according to the filter parameter table;
and generating the target filter effect according to the target configuration file and the target filter parameters.
In some example embodiments of the present disclosure, based on the foregoing solution, the generating the target filter effect according to the target configuration file and the target filter parameter includes:
in response to detecting that the target filter effect is a complex filter effect, determining a plurality of basic filter effects corresponding to the complex filter effect and a superposition sequence corresponding to the plurality of basic filter effects according to the target configuration file;
and overlapping the plurality of basic filter effects according to the overlapping sequence to obtain a basic filter set, wherein the basic filter set is the target filter effect.
In some example embodiments of the present disclosure, based on the foregoing solution, determining the original filter parameters corresponding to the target filter effect according to the target configuration file includes:
acquiring configuration files corresponding to the multiple basic filter effects; the configuration file comprises original filter parameters corresponding to a plurality of basic filter effects;
and obtaining the original filter parameters corresponding to the complex filter effect according to the original filter parameters corresponding to the basic filter effects.
In some example embodiments of the present disclosure, based on the foregoing, after generating the target filter effect, the method further comprises:
determining target filter parameters corresponding to the target filter effect, and generating parameter adjustable controls corresponding to the target filter effect;
and responding to the adjustment operation on the parameter adjustable control, determining the updated target filter parameter, and updating the target filter effect according to the updated target filter parameter.
In some example embodiments of the present disclosure, based on the foregoing solution, the filter effect generating method is that the method further includes:
responding to the intensity parameter adjusting operation on the parameter adjustable control, and adjusting the original intensity information of a plurality of basic filter effects corresponding to the complex filter effect to obtain target intensity information;
and generating the complex filter effect after the intensity is adjusted according to the target intensity information.
In some example embodiments of the present disclosure, based on the foregoing, the target filter effect comprises a base hybrid filter effect that does not support intensity parameter adjustment, the method further comprising:
responding to the intensity parameter adjustment operation on the parameter adjustable control for the basic mixed filter effect, and acquiring a configuration file corresponding to the basic mixed filter effect; wherein the configuration file comprises shader programs;
and rendering the basic mixed filter effect through the shader program to obtain the basic mixed filter effect after intensity adjustment, and further realizing intensity adjustment of the target filter effect.
In some example embodiments of the present disclosure, based on the foregoing scheme, the filter effect generating method further includes:
loading a target image;
and responding to the selection operation of selecting the target filter effect corresponding to the target image, and adding the target filter effect on the target image.
According to a second aspect of the embodiments of the present disclosure, there is provided a filter effect generating apparatus including:
the target configuration file determining module is used for responding to the selection operation of the target filter effect and determining a target configuration file corresponding to the target filter effect;
the original filter parameter determining module is used for determining original filter parameters corresponding to the target filter effect according to the target configuration file;
the filter parameter conversion module is used for acquiring a pre-configured filter parameter table and converting the original filter parameters into target filter parameters according to the filter parameter table;
and the target filter effect generation module is used for generating the target filter effect according to the target configuration file and the target filter parameters.
In an exemplary embodiment of the present disclosure, based on the foregoing solution, the target filter effect generation module further includes:
a stacking sequence determining unit, configured to determine, in response to detecting that the target filter effect is a complex filter effect, a plurality of basic filter effects corresponding to the complex filter effect and a stacking sequence corresponding to the plurality of basic filter effects according to the target configuration file;
and the target filter effect generation unit is used for performing superposition processing on the plurality of basic filter effects according to the superposition sequence to obtain a basic filter set, wherein the basic filter set is the target filter effect.
In an exemplary embodiment of the present disclosure, based on the foregoing, the original filter parameter determining module further includes an original filter parameter determining unit configured to:
acquiring configuration files corresponding to the multiple basic filter effects; the configuration file comprises original filter parameters corresponding to a plurality of basic filter effects;
and obtaining the original filter parameters corresponding to the complex filter effect according to the original filter parameters corresponding to the basic filter effects.
In an exemplary embodiment of the present disclosure, the filter effect generating apparatus further includes a target filter effect updating unit configured to:
determining target filter parameters corresponding to the target filter effect, and generating parameter adjustable controls corresponding to the target filter effect;
and responding to the adjustment operation on the parameter adjustable control, determining the updated target filter parameter, and updating the target filter effect according to the updated target filter parameter.
In an exemplary embodiment of the present disclosure, the filter effect generation apparatus further includes a filter display intensity adjustment unit configured to:
responding to the intensity parameter adjusting operation on the parameter adjustable control, and adjusting the original intensity information of a plurality of basic filter effects corresponding to the complex filter effect to obtain target intensity information;
and generating the complex filter effect after the intensity is adjusted according to the target intensity information.
In an exemplary embodiment of the present disclosure, the filter display intensity adjusting unit is further configured to:
responding to the intensity parameter adjustment operation on the parameter adjustable control for the basic mixed filter effect, and acquiring a configuration file corresponding to the basic mixed filter effect; wherein the configuration file comprises shader programs;
and rendering the basic mixed filter effect through the shader program to obtain the target filter effect after the intensity is adjusted.
In an exemplary embodiment of the present disclosure, the filter effect generating apparatus further includes a filter effect adding unit configured to:
loading a target image;
and responding to the selection operation of a target filter effect corresponding to the target image, and adding the target filter effect on the target image.
The technical scheme provided by the embodiment of the disclosure can have the following beneficial effects:
in the filter effect generation method in the example embodiment of the present disclosure, a target configuration file corresponding to a target filter effect is determined in response to a selection operation of the target filter effect; determining original filter parameters corresponding to the target filter effect according to the target configuration file; acquiring a pre-configured filter parameter table, and converting the original filter parameters into target filter parameters according to the filter parameter table; and generating the target filter effect according to the target configuration file and the target filter parameters. On one hand, the original filter parameters corresponding to the target filter effect selected by the user at the design end are determined based on the target configuration file, then the original filter parameters are automatically converted through the filter parameter table to obtain the target filter parameters corresponding to the client, and the target filter parameters do not need to be manually converted by designers, so that the development cost is reduced, the development period is shortened, and the generation efficiency of the filter effect is obviously improved; on the other hand, through the filter parameter table, various filter effects designed by the design end can be directly used at the client, the diversity of the filter effects of the client is realized, the accuracy of the display of the filter effects at the client is improved, and the user experience is improved. It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and together with the description, serve to explain the principles of the disclosure. It is to be understood that the drawings in the following description are merely exemplary of the disclosure, and that other drawings may be derived from those drawings by one of ordinary skill in the art without the exercise of inventive faculty. In the drawings:
fig. 1 schematically shows a flow diagram of a filter effect generation method according to an embodiment of the present disclosure;
FIG. 2 schematically shows a flow diagram for generating a target filter effect according to an embodiment of the disclosure;
FIG. 3 schematically shows a flow diagram for target filter effect update according to an embodiment of the present disclosure;
FIG. 4 schematically illustrates a flow diagram for intensity adjustment of a target filter effect including a supporting base filter effect according to an embodiment of the disclosure;
FIG. 5 schematically illustrates a flow diagram for intensity adjustment including a target filter effect that does not support a base mix filter effect, according to an embodiment of the disclosure;
fig. 6 schematically shows an application diagram of a target filter effect generation process according to an embodiment of the present disclosure;
fig. 7 schematically illustrates a structural schematic of a target filter effect arrangement according to an embodiment of the present disclosure;
FIG. 8 schematically illustrates a structural diagram of a computer system of an electronic device, according to an embodiment of the disclosure;
fig. 9 schematically shows a schematic diagram of a computer-readable storage medium according to an embodiment of the present disclosure.
In the drawings, the same or corresponding reference numerals indicate the same or corresponding parts.
Detailed Description
Example embodiments will now be described more fully with reference to the accompanying drawings. Example embodiments may, however, be embodied in many different forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the concept of example embodiments to those skilled in the art.
Furthermore, the described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to give a thorough understanding of embodiments of the disclosure. One skilled in the relevant art will recognize, however, that the subject matter of the present disclosure can be practiced without one or more of the specific details, or with other methods, components, devices, steps, and so forth. In other instances, well-known methods, devices, implementations, or operations have not been shown or described in detail to avoid obscuring aspects of the disclosure.
Furthermore, the drawings are merely schematic illustrations and are not necessarily drawn to scale. The block diagrams shown in the figures are functional entities only and do not necessarily correspond to physically separate entities. I.e. these functional entities may be implemented in the form of software, or in one or more hardware modules or integrated circuits, or in different networks and/or processor means and/or microcontroller means.
The filter effect generation method in one embodiment of the present disclosure may be executed in a terminal device or a server. The terminal device may be a user terminal device, such as a mobile phone or a computer. When the filter effect generation method is executed on a server, the filter effect generation method can be implemented and executed based on a cloud interaction system, wherein the cloud interaction system comprises the server and a client device.
In an optional implementation manner, taking a cloud interaction system as an example, various cloud applications may be run under the cloud interaction system, for example: in an operation mode of filter effect generation based on a cloud interaction system, a generation main body of a filter effect and a display main body of the filter effect are separated, filter effect storage and generation of an image in a filter effect generation method are completed on a cloud server, and a client device is used for receiving and sending data and receiving and sending the image, for example, the client device can be a display device with a data transmission function close to a user side, such as a mobile terminal, a television, a computer, a palm computer and the like; but the process of performing filter effect generation is at the server. When filter effect processing is carried out, a user operates a client device to send an operation instruction for selecting a target filter effect to a cloud server, the cloud server acquires an image according to the operation instruction, a target configuration file is called in response to the selection operation of the target filter of the user, a target filter effect is generated, data such as the target filter effect are coded and compressed, the data are returned to the client device through a network, and finally, decoding is carried out through the client device and a target filter effect picture is output.
In an optional implementation manner, taking the terminal device as an example, the local terminal device stores a parameter adjustable control for responding to a filter parameter adjusting operation of a user. The local terminal device is used for interacting with a user through a graphical user interface, namely, a filter effect related program is downloaded and operated through the electronic device conventionally. The manner in which the local terminal device provides the graphical user interface to the user may include a variety of ways, for example, it may be rendered for display on a display screen of the terminal or provided to the user by holographic projection. For example, the local terminal device may include a display screen for presenting a graphical user interface including a parameter-adjustable control and a filter effect screen, and a processor for running the filter effect-related program, generating a graphical user interface, and controlling display of the graphical user interface on the display screen.
The inventor finds that in the related filter effect generation method, pixel data and vertex data need to be subjected to various processing, for example, vertex data is processed in an evaluator to generate normal vectors, texture coordinates, spatial coordinates of points and the like, corresponding pixel information is generated through vertex operation and primitive assembly, the pixel information is subjected to rasterization processing to generate fragments used by a fragment shader, and a final color corresponding to each pixel is determined through the fragment shader, but when the vertex and the fragments are rendered, colors are overlapped, so that a target filter effect is different from a finally displayed filter effect; in addition, the principle of the related filter effect generation device is to write shader files and load the shader files into a rendering pipeline, so that the filter effect is achieved, however, the writing of shader files has a high professional requirement, and people who are not image processing professionals cannot perform related adjustment on the filter algorithm of an image, so that the filter effect development cost is high, and the development period is long.
In addition, the filter effect provided by the mobile terminal is more basic, and a user cannot adjust the filter algorithm to obtain various basic filter effects; meanwhile, based on the filter effect of professional image processing software, the filter effect is realized by writing shader files and loading the shader files into a rendering pipeline according to the principle, and the algorithm for writing the shader files is complex, so that the development cost of the filter effect is high, and the development period is long.
In view of one or more of the above problems, in the present exemplary embodiment, first, a filter effect generating method is provided, which may be applied to a terminal device having an interactive function or a server, and this is not particularly limited in this exemplary embodiment, and the following description will be made in detail by taking an example in which the terminal device executes the method.
Fig. 1 shows a flow diagram of a filter effect generation method according to an embodiment of the present disclosure; referring to fig. 1, the filter effect generating method may include the steps of:
step S110, responding to the selection operation of the target filter effect, and determining a target configuration file corresponding to the target filter effect;
step S120, determining original filter parameters corresponding to the target filter effect according to the target configuration file;
step S130, obtaining a pre-configured filter parameter table, and converting the original filter parameters into target filter parameters according to the filter parameter table;
step S140, generating the target filter effect according to the target configuration file and the target filter parameters.
According to the filter effect generation method in the present exemplary embodiment, on one hand, according to a target filter effect selected by a user, a target configuration file corresponding to the target filter effect is determined, an original filter parameter corresponding to the target filter effect is determined through the target configuration file, the target filter parameter corresponding to the target filter effect can be automatically matched based on a filter parameter table, a filter developer is not required to manually fill in the target filter parameter corresponding to the target filter effect, and the generation efficiency of the filter effect is improved; on the other hand, the filter parameter table can carry out parameter conversion on various filter parameters, so that the diversity of filter effects is improved.
Next, the filter effect generation method in the present exemplary embodiment will be further described.
In step S110, in response to a selection operation on a target filter effect, a target profile corresponding to the target filter effect is determined.
In one example embodiment of the present disclosure, the filter effect refers to implementing various special effects of an image, and the target filter effect may refer to a filter effect based on a user selection. The target filter effect may be a basic filter effect, for example, the basic filter effect may include a brightness filter effect, a contrast filter effect, a white balance filter effect, a LUT (Look-up-table) filter effect, a saturation filter effect, an exposure filter effect, a Gaussian blur filter effect, a dark angle filter effect, a white balance filter effect, a tone curve filter effect, a shadow highlight filter effect, a mixed mode soft light filter effect, a mixed mode hard light filter effect, a mixed mode deepening filter effect, a mixed mode dimming filter effect, a mixed mode color deepening filter effect, a mixed mode color dimming filter effect, a mixed mode linear filter effect, a mixed mode color filter effect, a mixed mode superimposing filter effect, a mixed mode difference filter effect, a mixed mode multiplicative filter effect, A mixed mode rejection filter effect, a mixed mode subtraction filter effect, a mixed mode division filter effect, a mixed mode color filter effect, and the like; the target filter effect may also be a complex filter effect obtained by combining at least 2 basic filter effects, for example, the complex filter effect may include a filter effect obtained by combining a luminance filter effect, a contrast filter effect, and a white balance filter effect, and of course, may also refer to a filter effect selected by another user, which is not particularly limited in this embodiment.
The target configuration file may refer to a file including configuration resources corresponding to a target filter effect, for example, the target configuration file may include filter parameter values for realizing the target filter effect, may also include material resources for realizing the target filter effect, may also include version information of the target filter effect, and of course, may also refer to a file including configuration resources corresponding to other target filter effects, which is not particularly limited in this embodiment.
Based on the operation of the target filter effect selected by the user, downloading a filter resource package through a wireless network or a limited network, analyzing the resource package, and searching a target configuration file corresponding to the target filter effect according to a directory of the configuration files.
For example, the target filter effect selected by the user is a shadow highlight filter effect, a configuration file set of all filter effects is read by downloading filter resource packages corresponding to all filter effects, and a configuration file corresponding to the shadow highlight filter effect is selected from the configuration file set as a target configuration file according to a directory of the configuration file set.
In step S120, an original filter parameter corresponding to the target filter effect is determined according to the target configuration file.
In an example embodiment of the present disclosure, the original filter parameter may refer to a filter parameter value corresponding to a target filter effect designed by a design end, for example, when the target filter effect is initially designed, the original filter parameter value corresponding to the design end is 50, and when the target filter effect needs to be displayed on a client, if the same effect as the design end is to be presented, the filter parameter value corresponding to the client may be 30 instead of 50, so that when the client uses the target filter effect, the original filter parameter value recorded by the design end needs to be converted.
In step S130, a pre-configured filter parameter table is obtained, and the original filter parameters are converted into target filter parameters according to the filter parameter table.
In an example embodiment of the present disclosure, the filter parameter table may be a mapping table that converts original filter parameters corresponding to a luminance filter effect and a basic mixed filter effect at a design end into filter parameters corresponding to a client; for example, if the target filter effect is a brightness filter effect, the filter parameter table may be a mapping table for converting the original intensity parameter into the target intensity parameter; if the target filter effect is a mixed-mode soft filter effect, the filter parameter table may also be a mapping table for converting the original soft filter parameters into target soft filter parameters; of course, the filter parameter mapping table may also be used to convert other original filter parameters into target filter parameters, which is not particularly limited in this embodiment.
The target filter parameter may be a filter parameter obtained by converting an original filter parameter through a filter parameter table, and the filter parameter may be displayed at the client, for example, at the design end, an original filter parameter value corresponding to the target filter effect is 50, and if a filter effect identical to the design end is to be presented, since standards for realizing the filter effect of different platforms are different, a filter parameter value corresponding to the client may be 30, and the original filter parameter value needs to be converted into the target filter parameter capable of forming the target filter effect at the client through the preset filter parameter table.
In particular, the basic filter effect may further include a basic mixed filter effect, for example, the basic mixed filter effect may include a soft light filter effect of a mixed mode, a bright light filter effect of the mixed mode, a deepening filter effect of the mixed mode, a dimming filter effect of the mixed mode, a color deepening filter effect of the mixed mode, a color dimming filter effect of the mixed mode, a linear filter effect of the mixed mode, a color filter effect of the mixed mode, a superimposed filter effect of the mixed mode, a differential filter effect of the mixed mode, a multiplicative filter effect of the mixed mode, a rejection filter effect of the mixed mode, a subtraction filter effect of the mixed mode, a division filter effect of the mixed mode, a filter effect of the mixed mode, and the like.
Since the filter parameter values of the basic mixed filter effect are generally expressed by percentages, the original filter parameters corresponding to the basic mixed filter effect at the design end are the target filter parameters corresponding to the basic mixed filter effect at the client end, for example, at the design end, the original filter parameters corresponding to the basic mixed filter effect are 25% (assuming that the filter parameter value range of the basic mixed filter effect at the design end is 0-100, and the original filter parameters are 25 at this time), then, at the client end, the target filter parameters corresponding to the basic mixed filter effect are still 25%, and conversion is not required through a filter parameter table (assuming that the filter parameter value range of the basic mixed filter effect at the client end is 0-80, and the original filter parameters are 20 at this time). It can be seen that although the original filter parameters of the basic hybrid filter effect are the target filter parameters and are not converted through the filter parameter table, the conversion of the filter parameters is substantially completed because the filter parameter values are expressed in percentage.
The target configuration file corresponding to the target filter effect is determined, the original filter parameters corresponding to the target filter effect are obtained from the target configuration file, and the target filter parameters corresponding to the target filter effect can be determined according to the filter parameter table, so that developers do not need to manually write the target filter parameters corresponding to the target filter effect, and the generation rate of the target filter effect is improved; in addition, the filter parameter table accurately maps the relationship between the original filter parameters and the target filter parameters, so that the problem of difference of filter effects realized by different platforms is solved, and the high restoration of the filter effects is realized.
In step S140, a target filter effect is generated according to the target configuration file and the target filter parameters.
In an example embodiment of the present disclosure, a target configuration file is determined according to a target filter effect, an original filter parameter corresponding to the target filter effect is determined in the target configuration file, a target filter parameter corresponding to the target filter effect can be determined through a filter parameter table, and the target filter effect can be generated based on the target configuration file and the target filter effect parameter.
For example, the target filter effect is a combined filter effect of a brightness filter effect and a vignetting filter effect, the target configuration file is a configuration file of the brightness filter effect and the vignetting filter effect, the original brightness filter parameter of the brightness filter effect is 30 according to the target configuration file, the original vignetting filter parameter of the vignetting filter effect is 25, the target filter parameter corresponding to the original brightness filter parameter of 30 in the filter parameter table is 20, the target filter parameter corresponding to the original vignetting filter parameter of 25 is 15, the target filter effect can be generated based on the target configuration file and the target filter parameter of the target filter effect, and the effect obtained by selecting when the user image is processed is achieved.
In this example embodiment, after responding to the selected target filter effect, the base set of filters for the target filter effect may be determined by the steps in fig. 2:
in step S210, in response to detecting that the target filter effect is a complex filter effect, determining a plurality of basic filter effects corresponding to the complex filter effect and a stacking order corresponding to the plurality of basic filter effects according to the target configuration file;
and S220, overlapping the multiple basic filter effects according to the overlapping sequence to obtain a basic filter group, wherein the basic filter group is a target filter effect.
In this embodiment, the complex filter effect may refer to a filter effect of a combination of at least 2 basic filter effects, which may be a combined filter effect of a luminance filter effect and a contrast filter effect, a combined filter effect of a shadow highlight filter effect, a sharpening filter effect, and a mixed-mode color deepening filter effect, a combined filter effect of a mixed-mode soft light filter effect and a mixed-mode color filter, and of course, a filter effect of a combination of other basic filter effects, which is not particularly limited in this embodiment.
The stacking sequence may refer to a combination sequence of a plurality of basic filter effects, for example, may refer to stacking a shadow highlight filter effect on a saturation filter effect, or may refer to stacking a saturation filter effect on a shadow highlight filter effect, or may refer to a combination sequence of other multiple basic filters; wherein, the combination sequence is different, and the final achieved target filter effect is also different.
The basic filter group (target filter effect) may refer to a filter group composed of at least 2 basic filter effects in a stacking order, for example, if the detected target filter effect is a combined filter effect of a shadow highlight filter effect and a saturation filter effect, the basic filter group is composed of the shadow highlight filter effect and the saturation filter effect, of course, the basic filter group may also be composed of other basic filter effects, and this embodiment is not particularly limited to this.
For example, the target filter effect is a filter effect obtained by superimposing a saturation filter effect on a shadow highlight filter effect, and then the basic filter group is composed of the shadow highlight filter effect and the saturation filter effect, so that the superposition sequence of the basic filter group corresponding to the target filter effect can be determined according to the target configuration file, and the filter effect obtained by superimposing the saturation filter effect on the shadow highlight filter effect is superimposed on the shadow highlight filter effect, and the shadow highlight filter effect and the saturation filter effect are superimposed, so that the corresponding target filter effect can be obtained, and the generation efficiency of the target filter effect is improved.
In this example embodiment, after responding to the selected target filter effect, the update of the target filter effect may be achieved by the steps in fig. 3:
step S310, generating a parameter adjustable control corresponding to a target filter effect according to the target filter parameter corresponding to the target filter effect;
step S320, responding to the adjustment operation on the parameter adjustable control, and determining the updated target filter parameter;
and step S330, updating the target filter effect according to the updated target filter parameter.
In this embodiment, the parameter-adjustable control may be a control capable of adjusting a target filter parameter, for example, the parameter-adjustable control may be an adjustable control for dragging the slider left and right to adjust the target filter parameter, or an adjustable control for adjusting the target filter parameter through a "+" - "button, and of course, the parameter-adjustable control may also be a control for adjusting the target filter parameter through a voice instruction or a gravity sensing manner, which is not limited in this example. The multiple filter parameters corresponding to the target filter effect may be adjusted by the parameter-adjustable control, for example, the parameter-adjustable control may be a parameter-adjustable control for adjusting a saturation parameter of the target filter effect, a parameter-adjustable control for adjusting a brightness parameter of the target filter effect, a parameter-adjustable control for adjusting a sharpening parameter of the target filter effect, or a parameter-adjustable control for adjusting other filter parameters, which is not particularly limited in this embodiment.
For example, the target filter effect is a combined filter effect of a brightness filter effect and a dark corner filter effect, an original brightness filter parameter of the brightness filter effect and an original dark corner filter parameter of the dark corner filter effect can be known through a target configuration file, a target filter parameter corresponding to the original brightness filter parameter matched in a filter parameter table is 20, a target filter parameter corresponding to the original dark corner filter parameter is 15, however, the generated target filter effect does not meet the user requirement, a user can increase the brightness filter parameter to 22 and the dark corner filter parameter to 20 by clicking or dragging a parameter adjustable control, obtain an updated target filter parameter in response to the operation of the user adjusting parameter adjustable control, and update the target filter effect according to the updated target filter parameter.
In this embodiment, the target filter effect may include a basic filter effect supporting intensity adjustment, and the intensity adjustment of the target filter effect may be realized through the steps in fig. 4:
step S410, responding to the intensity parameter adjusting operation on the parameter adjustable control, and adjusting the original intensity information of a plurality of basic filter effects corresponding to the complex filter effect;
step S420, obtaining target intensity information of the complex filter effect according to the original intensity information of the multiple basic filter effects to generate the complex filter effect with adjusted intensity.
In this embodiment, the original intensity information may refer to a display degree corresponding to the target filter effect before the intensity parameter adjustment operation, for example, the original intensity information may refer to a display degree of an original brightness parameter of the target filter effect, a display degree of a saturation parameter of the target filter effect, a display degree of an original contrast parameter of the target filter effect, or a display degree of other filter parameters of the basic filter effect, which is not particularly limited in this embodiment.
The target intensity information may refer to a display degree of the target filter effect generated after the intensity adjustment is performed on the target filter effect, for example, the target intensity information may refer to a display degree of a target brightness parameter of the target filter effect, a display degree of a target saturation parameter of the target filter effect, a display degree of a target contrast parameter of the target filter effect, and certainly, a display degree of other filter parameters of the target filter effect, which is not particularly limited in this embodiment.
For example, the target filter effect may be a combined filter effect of a brightness filter effect and a dark corner filter effect, and the user may adjust intensity information of a brightness parameter on the parameter-adjustable control, and obtain a display degree of the brightness filter effect and an original brightness parameter corresponding to the dark corner filter effect in response to an operation of the user on the brightness parameter-adjustable control, where if the original intensity information of the brightness parameter corresponding to the brightness filter effect is 30, the original intensity information of the brightness parameter corresponding to the dark corner filter effect is 20, the target brightness parameter corresponding to the brightness filter effect corresponding to the brightness parameter is 30 according to the original intensity information of the brightness parameter, and the original intensity information of the brightness parameter is the target brightness parameter corresponding to the dark corner filter effect corresponding to 20, and obtain target intensity information corresponding to the brightness parameter of the target filter effect; further, a target filter effect is generated based on target intensity information corresponding to the luminance parameter of the target filter effect.
In this embodiment, the target filter effect includes a basic hybrid filter effect that does not support intensity parameter adjustment, and the intensity adjustment of the target filter effect can be realized through the steps in fig. 5:
step S510, responding to the intensity parameter adjustment operation of the basic mixing filter effect on the parameter adjustable control, and acquiring a configuration file corresponding to the basic mixing filter effect; wherein the configuration file comprises shader programs;
step S520, rendering the basic hybrid filter effect through the shader program to obtain the basic hybrid filter effect after the intensity adjustment, thereby achieving the intensity adjustment of the target filter effect.
In this embodiment, the basic mixed filter effect may refer to a basic filter effect in a mixed mode, may refer to a soft light filter effect in the mixed mode, may refer to a color deepening filter effect in the mixed mode, may refer to a color filtering filter effect in the mixed mode, and may also refer to a filter effect in other mixed modes, which is not particularly limited in this embodiment.
The shader program refers to a program that can render a target filter effect, and may refer to a vertex shader program, a fragment shader program, or other shader programs that render a target filter effect, which is not limited in this embodiment.
Preferably, in the target filter effect including the basic mixed filter effect, the intensity adjustment of the target filter effect is realized by determining the basic mixed filter effect in the target filter effect, acquiring a configuration file corresponding to the basic mixed filter effect, and loading a shader program through the configuration file.
For example, according to an operation of a user on a parameter-adjustable control, it is determined that a basic filter effect corresponding to a target filter effect is a mixed-mode soft light filter effect, a configuration file corresponding to the mixed-mode soft light filter effect is obtained, a shader program corresponding to the mixed-mode soft light filter effect is called in the configuration file, so that intensity adjustment of the target filter effect can be achieved, and intensity adjustment of a filter effect which does not support intensity adjustment originally is achieved by loading the shader program corresponding to the mixed-mode filter effect.
In this example embodiment, fig. 6 schematically shows a flow chart of a target filter effect generation process according to an embodiment of the present disclosure;
referring to fig. 6, in step S601, in response to a target filter effect operation selected by a user, a target configuration file corresponding to the target filter effect is determined;
step S602, based on the target configuration file, determining the original filter parameters corresponding to the target configuration file;
step S603, determining target filter parameters corresponding to the original filter parameters in the target configuration file according to a preset filter parameter table;
step S604, generating a target filter effect and a parameter adjustable control corresponding to the target filter effect according to the target filter parameter;
step S605, judging whether intensity adjustment is needed to be carried out on the target filter effect, executing step S606 if intensity adjustment is needed to be carried out on the target filter effect, and executing step S614 if intensity adjustment is not needed to be carried out on the target filter effect;
step S606, determining whether the target filter effect includes a basic mixed filter effect, the target filter effect including the basic mixed filter effect executing step S607, the target filter effect not including the basic mixed filter effect executing step S611;
step S607, loading a shader program based on a configuration file corresponding to the basic mixed filter effect;
step S608, responding to the intensity adjusting operation of the user on the parameter adjustable control, and acquiring the original intensity information of the basic filter effect;
step S609, obtaining target intensity information of the complex filter effect based on the original intensity information of the basic filter effect;
step S610, rendering the target filter effect through a shader program based on the target intensity information of the complex filter effect to obtain the target filter effect after intensity adjustment;
step S611, responding to the intensity parameter adjusting operation on the parameter adjustable control, and adjusting the original intensity information of a plurality of basic filter effects corresponding to the target filter effect;
step S612, acquiring updated target intensity information of the basic filter effect based on the original intensity information of the basic filter effect;
step S613, updating the target filter effect based on the target intensity information of the basic filter effect;
step S614, in response to the adjustment operation on the parameter adjustable control, determining the original filter parameters corresponding to the adjusted target filter effect;
step S615, based on the original filter parameters and the filter parameter table, determining updated target filter parameters;
and step S616, updating the target filter effect according to the updated target filter parameters and the target configuration file.
In this embodiment, a user may select a basic filter effect as a target filter effect, or may select a combined filter effect of multiple filter effects as the target filter effect, determine a target configuration file corresponding to the target filter effect in response to a selection operation of the user target filter effect, determine an original filter parameter for generating the target filter effect according to the target configuration file, and generate the target filter effect based on the target filter parameter; and if the target filter effect is the combined filter effect of the multiple basic filter effects, acquiring target filter parameters of the target filter effect according to a preset filter parameter table.
For example, the target filter effect selected by the user is a saturation filter effect, a configuration file corresponding to the saturation filter effect is obtained as a target configuration file in response to a target filter effect operation selected by the user, an original saturation parameter corresponding to the saturation filter effect is determined based on the target configuration file, and if the original saturation parameter is 43, the target filter effect is generated according to the target filter parameter by matching the original saturation parameter to be 28 corresponding to the original saturation parameter to be 43 based on a preset filter parameter table.
Similarly, if the target filter effect selected by the user is a combined filter effect of at least 2 basic filter effects, a configuration file corresponding to each basic filter effect is obtained in response to the selection operation of the target filter effect of the user, the configuration files corresponding to all the basic filter effects in the target filter effect are used as target configuration files, the superposition sequence of the basic filter effects and the original filter parameters of a plurality of basic effects are determined according to the target configuration files, the target filter parameters corresponding to each basic filter effect are obtained based on the filter parameter table, and the target filter effect is generated according to the target filter parameters corresponding to each basic filter effect and the target configuration files.
Preferably, the parameter adjustable control is generated based on the target filter parameter; when the adjustment operation of a user on the parameter adjustable control is detected, acquiring the original filter parameters of the adjusted target filter effect, and determining the target filter parameters corresponding to the original filter parameters of the target filter effect; and updating the target filter effect based on the updated target filter parameters.
For example, the target filter effect selected by the user is a saturation filter effect, if the original saturation parameter of the target filter effect is 43, the target saturation parameter corresponding to the original saturation parameter 43 is 28 obtained based on a preset filter parameter table, and the target filter effect is generated according to the target filter parameter; however, the saturation of the generated target filter effect does not meet the requirement of the user, the user can respond to the adjustment operation of the saturation parameter adjustable control of the user by clicking or dragging the adjustable control for adjusting the saturation parameter to obtain the original saturation parameter corresponding to the saturation filter effect, if the original filter parameter is 60, the target saturation parameter corresponding to the saturation filter effect is determined to be 43 based on the filter parameter table, and the target filter effect is updated according to the target saturation parameter and the target configuration file.
Optionally, the target filter effect may be a complex filter effect composed of a plurality of basic filter effects, if an adjustment operation of a user on an intensity parameter adjustable control of the target filter effect is detected, original intensity information of the target filter effect is obtained, target filter information corresponding to the target filter effect (the complex filter effect) is obtained according to the original filter information of the basic filter effect, and the target filter effect is updated according to the updated target intensity information and the target configuration file; particularly, when the target filter effect is the filter effect superposed by the basic mixing filter, in response to the operation of the intensity parameter adjustable control by the user, a configuration file corresponding to the basic mixing filter effect is obtained, the original intensity information of the basic mixing filter effect is determined, a shader program is loaded through the configuration file of the basic mixing filter effect according to the target intensity information of the basic mixing filter effect, and the target filter effect is updated according to the target intensity information of the basic mixing filter effect.
For example, the target filter effect selected by the user is to superimpose a dark angle filter effect on the brightness filter effect, the user can adjust the intensity information of the contrast parameter on the parameter-adjustable control, and it can be known through the target configuration file that the original intensity information of the contrast parameter of the brightness filter effect is 35 and the original intensity information of the contrast parameter of the dark angle filter effect is 67; and then, obtaining target intensity information of the target filter effect according to the original intensity information of the contrast parameter of the brightness filter effect and the original intensity information of the contrast parameter of the dark angle filter effect, and generating the target filter effect based on the target intensity information of the target filter effect. However, the brightness of the target filter effect does not meet the requirements of the user, the user can obtain the updated brightness filter effect and the original intensity information corresponding to the dark corner filter effect by clicking or dragging the brightness parameter adjustable control in response to the operation of adjusting the brightness parameter adjustable control by the user, the original brightness intensity information of the brightness filter effect after adjusting the brightness parameter adjustable control is 50, the original brightness intensity information of the dark corner filter effect is 73, and the target intensity information of the brightness parameter of the target filter effect is obtained according to the original intensity information of the brightness parameter of the brightness filter effect and the original intensity information of the brightness parameter of the dark corner filter effect; and finally, updating the target filter effect according to the target intensity information of the brightness parameter of the target filter effect and the configuration file corresponding to the target filter effect.
Particularly, if the target filter effect selected by the user is a filter effect including a basic mixed filter effect, when the user needs to adjust the brightness of the target filter effect, a configuration file corresponding to the basic mixed filter effect needs to be acquired, and a shader program is loaded through the configuration file.
In summary, on one hand, the user can select the basic filter effect as the target filter effect, and also can select the filter effect superposed by multiple basic filter effects as the target filter effect, so that the richness of the filter effect is increased; on the other hand, a target filter parameter corresponding to an original filter parameter of a target filter effect can be determined through a pre-configured filter parameter table, and a parameter adjustable control corresponding to the target filter parameter is generated; on the other hand, when the complex filter effect contains the basic mixed filter effect, the shader program can be loaded through the configuration file corresponding to the basic mixed filter, the intensity of the complex filter effect is adjusted through executing the shader program, shader language does not need to be written, optimization of the target filter effect is achieved, intensity adjustment of the mixed filter effect which does not support intensity adjustment in the past is achieved, and development cost and development period of the filter effect are reduced.
It should be noted that although the various steps of the methods of the present disclosure are depicted in the drawings in a particular order, this does not require or imply that these steps must be performed in this particular order, or that all of the depicted steps must be performed, to achieve desirable results. Additionally or alternatively, certain steps may be omitted, multiple steps combined into one step execution, and/or one step broken down into multiple step executions, etc.
Further, in the present exemplary embodiment, a filter effect generating apparatus is also provided. Referring to fig. 7, the filter effect generating apparatus 700 includes: a target configuration file determining module 710, an original parameter determining module 720, a filter parameter converting module 730, and a target filter effect generating module 740, wherein:
the target configuration file determining module 710 is configured to determine a target configuration file corresponding to a target filter effect in response to a selection operation on the target filter effect;
the original filter parameter determining module 720 is configured to determine, according to the target configuration file, an original filter parameter corresponding to the target filter effect;
the filter parameter conversion module 730 is used for acquiring a pre-configured filter parameter table and converting the original filter parameters into target filter parameters according to the filter parameter table;
the target filter effect generating module 740 is configured to generate the target filter effect according to the target configuration file and the target filter parameter.
In an exemplary embodiment of the disclosure, based on the foregoing solution, the target filter effect generating module 740 further includes:
a stacking sequence determining unit, configured to determine, in response to detecting that the target filter effect is a complex filter effect, a plurality of basic filter effects corresponding to the complex filter effect and a stacking sequence corresponding to the plurality of basic filter effects according to the target configuration file;
and the target filter effect generation unit is used for performing superposition processing on the plurality of basic filter effects according to the superposition sequence to obtain a basic filter set, wherein the basic filter set is the target filter effect.
In an exemplary embodiment of the present disclosure, based on the foregoing scheme, the original filter parameter determining module 720 further includes an original filter parameter determining unit configured to:
acquiring configuration files corresponding to the multiple basic filter effects; the configuration file comprises original filter parameters corresponding to a plurality of basic filter effects;
and obtaining the original filter parameters corresponding to the complex filter effect according to the original filter parameters corresponding to the basic filter effects.
In an exemplary embodiment of the present disclosure, the filter effect generating apparatus 700 further includes a target filter effect updating unit configured to:
determining target filter parameters corresponding to the target filter effect, and generating parameter adjustable controls corresponding to the target filter effect;
and responding to the adjustment operation on the parameter adjustable control, determining the updated target filter parameter, and updating the target filter effect according to the updated target filter parameter.
In an exemplary embodiment of the present disclosure, the filter effect generating apparatus 700 further includes a filter display intensity adjusting unit configured to:
and responding to the intensity parameter adjusting operation on the parameter adjustable control, and adjusting the original intensity information of a plurality of basic filter effects corresponding to the complex filter effect to obtain target intensity information and generating the complex filter effect after intensity adjustment according to the target intensity information.
In an exemplary embodiment of the present disclosure, the filter display intensity adjusting unit is further configured to:
responding to the intensity parameter adjustment operation on the parameter adjustable control for the basic mixed filter effect, and acquiring a configuration file corresponding to the basic mixed filter effect; wherein the configuration file comprises shader programs;
and rendering the basic mixed filter effect through the shader program to obtain the target filter effect after the intensity is adjusted.
In an exemplary embodiment of the present disclosure, the filter effect generating apparatus 700 further includes a filter effect adding unit configured to:
loading a target image;
and responding to the selection operation of a target filter effect corresponding to the target image, and adding the target filter effect on the target image.
The specific details of each module of the filter effect generating device have been described in detail in the corresponding filter effect generating method, and therefore are not described herein again.
Further, in an exemplary embodiment of the present disclosure, there is also provided an electronic device capable of implementing the above-described filter effect generation method.
As will be appreciated by one skilled in the art, aspects of the present disclosure may be embodied as a system, method or program product. Accordingly, various aspects of the present disclosure may be embodied in the form of: an entirely hardware embodiment, an entirely software embodiment (including firmware, microcode, etc.) or an embodiment combining hardware and software aspects that may all generally be referred to herein as a "circuit," module "or" system.
An electronic device 800 according to such an embodiment of the disclosure is described below with reference to fig. 8. The electronic device 800 shown in fig. 8 is only an example and should not bring any limitations to the functionality and scope of use of the embodiments of the present disclosure.
As shown in fig. 8, electronic device 800 is in the form of a general purpose computing device. The components of the electronic device 800 may include, but are not limited to: the at least one processing unit 810, the at least one memory unit 820, a bus 830 connecting different system components (including the memory unit 820 and the processing unit 810), and a display unit 840.
Wherein the storage unit stores program code that is executable by the processing unit 810 to cause the processing unit 810 to perform steps according to various exemplary embodiments of the present disclosure as described in the "exemplary methods" section above in this specification. For example, the processing unit 810 may execute step S110 shown in fig. 1, in response to a selection operation of a target filter effect, determining a target profile corresponding to the target filter effect; step S120, determining original filter parameters corresponding to the target filter effect according to the target configuration file; step S130, acquiring a pre-configured filter parameter table, and converting the original filter parameters into target filter parameters according to the filter parameter table; step S140, generating the target filter effect according to the target configuration file and the target filter parameters.
The storage unit 820 may include readable media in the form of volatile storage units, such as a random access storage unit (RAM)821 and/or a cache storage unit 822, and may further include a read only storage unit (ROM) 823.
Storage unit 820 may also include a program/utility 824 having a set (at least one) of program modules 825, such program modules 825 including, but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which, or some combination thereof, may comprise an implementation of a network environment.
Bus 830 may be any of several types of bus structures including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.
The electronic device 800 may also communicate with one or more external devices 870 (e.g., keyboard, pointing device, bluetooth device, etc.), with one or more devices that enable a user to interact with the electronic device 800, and/or with any devices (e.g., router, modem, etc.) that enable the electronic device 800 to communicate with one or more other computing devices. Such communication may occur via input/output (I/O) interfaces 850. Also, the electronic device 800 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network, such as the internet) via the network adapter 860. As shown, the network adapter 860 communicates with the other modules of the electronic device 800 via the bus 830. It should be appreciated that although not shown, other hardware and/or software modules may be used in conjunction with the electronic device 800, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.
Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein may be implemented by software, or by software in combination with necessary hardware. Therefore, the technical solution according to the embodiments of the present disclosure may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (which may be a CD-ROM, a usb disk, a removable hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which may be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the embodiments of the present disclosure.
In an exemplary embodiment of the present disclosure, there is also provided a computer-readable storage medium having stored thereon a program product capable of implementing the above-described method of the present specification. In some possible embodiments, aspects of the present disclosure may also be implemented in the form of a program product comprising program code for causing a terminal device to perform the steps according to various exemplary embodiments of the present disclosure described in the "exemplary methods" section above of this specification, when the program product is run on the terminal device.
Referring to fig. 9, a program product 900 for implementing the above-described filter effect generation method according to an embodiment of the present disclosure is described, which may employ a portable compact disc read only memory (CD-ROM) and include program code, and may be run on a terminal device, such as a personal computer. However, the program product of the present disclosure is not limited thereto, and in this document, a readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable disk, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
A computer readable signal medium may include a propagated data signal with readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A readable signal medium may also be any readable medium that is not a readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Program code for carrying out operations for the present disclosure may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., through the internet using an internet service provider).
It should be noted that although in the above detailed description several modules or units of the filter effect generating means are mentioned, this division is not mandatory. Indeed, the features and functionality of two or more modules or units described above may be embodied in one module or unit, according to embodiments of the present disclosure. Conversely, the features and functions of one module or unit described above may be further divided into embodiments by a plurality of modules or units.
Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein may be implemented by software, or by software in combination with necessary hardware. Therefore, the technical solution according to the embodiments of the present disclosure may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (which may be a CD-ROM, a usb disk, a removable hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which may be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the embodiments of the present disclosure.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (10)

1. A filter effect generation method, comprising:
responding to the selection operation of a target filter effect, and determining a target configuration file corresponding to the target filter effect;
determining original filter parameters corresponding to the target filter effect according to the target configuration file;
acquiring a pre-configured filter parameter table, and converting the original filter parameters into target filter parameters according to the filter parameter table;
and generating the target filter effect according to the target configuration file and the target filter parameters.
2. The filter effect generation method according to claim 1, wherein the target filter effect includes a basic filter effect and a complex filter effect, and the generating the target filter effect according to the target profile and the target filter parameter includes:
in response to detecting that the target filter effect is a complex filter effect, determining a plurality of basic filter effects corresponding to the complex filter effect and a superposition sequence corresponding to the plurality of basic filter effects according to the target configuration file;
and overlapping the plurality of basic filter effects according to the overlapping sequence to obtain a basic filter set, wherein the basic filter set is the target filter effect.
3. The method for generating a filter effect according to claim 2, wherein determining the original filter parameters corresponding to the target filter effect according to the target configuration file comprises:
acquiring configuration files corresponding to the multiple basic filter effects; the configuration file comprises original filter parameters corresponding to a plurality of basic filter effects;
and obtaining the original filter parameters corresponding to the complex filter effect according to the original filter parameters corresponding to the basic filter effects.
4. The filter effect generation method according to claim 1, wherein after generating the target filter effect, the method further comprises:
determining target filter parameters corresponding to the target filter effect, and generating parameter adjustable controls corresponding to the target filter effect;
and responding to the adjustment operation on the parameter adjustable control, determining the updated target filter parameter, and updating the target filter effect according to the updated target filter parameter.
5. The filter effect generation method according to any one of claims 2 or 4, characterized by further comprising:
responding to the intensity parameter adjusting operation on the parameter adjustable control, and adjusting the original intensity information of a plurality of basic filter effects corresponding to the complex filter effect to obtain target intensity information;
and generating the complex filter effect after the intensity is adjusted according to the target intensity information.
6. The filter effect generation method of claim 5, wherein the target filter effect comprises a base hybrid filter effect that does not support intensity parameter adjustment, the method further comprising:
responding to the intensity parameter adjustment operation on the parameter adjustable control for the basic mixed filter effect, and acquiring a configuration file corresponding to the basic mixed filter effect; wherein the configuration file comprises shader programs;
and rendering the basic mixed filter effect through the shader program to obtain the target filter effect after the intensity is adjusted.
7. The filter effect generation method according to claim 1, further comprising:
loading a target image;
and responding to the selection operation of a target filter effect corresponding to the target image, and adding the target filter effect on the target image.
8. A filter effect generation apparatus, comprising:
the target configuration file determining module is used for determining configuration resources capable of realizing the target filter effect according to the target filter effect;
the original filter parameter determining module is used for determining original filter parameters corresponding to the target filter effect through the target configuration file;
the filter parameter conversion module is used for converting the original filter parameters of the target filter effect into target filter parameters of the target filter effect through the filter parameter table;
and the target filter effect generating module is used for generating a target filter effect and responding to the adjustment operation on the parameter adjustable control and updating the target filter effect according to the updated target filter parameter.
9. An electronic device, comprising:
a processor; and
a memory having computer readable instructions stored thereon which, when executed by the processor, implement the filter effect generation method of any of claims 1 to 7.
10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, implements the filter effect generation method according to any one of claims 1 to 7.
CN202011248171.8A 2020-11-10 2020-11-10 Filter effect generation method and device, electronic device and storage medium Active CN112367399B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011248171.8A CN112367399B (en) 2020-11-10 2020-11-10 Filter effect generation method and device, electronic device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011248171.8A CN112367399B (en) 2020-11-10 2020-11-10 Filter effect generation method and device, electronic device and storage medium

Publications (2)

Publication Number Publication Date
CN112367399A true CN112367399A (en) 2021-02-12
CN112367399B CN112367399B (en) 2022-06-14

Family

ID=74509219

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011248171.8A Active CN112367399B (en) 2020-11-10 2020-11-10 Filter effect generation method and device, electronic device and storage medium

Country Status (1)

Country Link
CN (1) CN112367399B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114092608A (en) * 2021-11-17 2022-02-25 广州博冠信息科技有限公司 Expression processing method and device, computer readable storage medium and electronic equipment

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005216043A (en) * 2004-01-30 2005-08-11 Noritsu Koki Co Ltd Softening effect filter and processing program therefor
CN103595898A (en) * 2013-11-12 2014-02-19 厦门美图网科技有限公司 Intelligent filter processing method based on image information
CN105068822A (en) * 2015-07-09 2015-11-18 厦门美图网科技有限公司 Real time filter online configuration method, system and shooting terminal
CN106791756A (en) * 2017-01-17 2017-05-31 维沃移动通信有限公司 A kind of multimedia data processing method and mobile terminal
CN107368603A (en) * 2017-07-28 2017-11-21 上海鋆创信息技术有限公司 A kind of method and device, storage medium and the terminal of the processing of picture filter
CN110115841A (en) * 2019-05-10 2019-08-13 网易(杭州)网络有限公司 The rendering method and device of vegetation object in a kind of scene of game
CN111899192A (en) * 2020-07-23 2020-11-06 北京字节跳动网络技术有限公司 Interaction method, interaction device, electronic equipment and computer-readable storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005216043A (en) * 2004-01-30 2005-08-11 Noritsu Koki Co Ltd Softening effect filter and processing program therefor
CN103595898A (en) * 2013-11-12 2014-02-19 厦门美图网科技有限公司 Intelligent filter processing method based on image information
CN105068822A (en) * 2015-07-09 2015-11-18 厦门美图网科技有限公司 Real time filter online configuration method, system and shooting terminal
CN106791756A (en) * 2017-01-17 2017-05-31 维沃移动通信有限公司 A kind of multimedia data processing method and mobile terminal
CN107368603A (en) * 2017-07-28 2017-11-21 上海鋆创信息技术有限公司 A kind of method and device, storage medium and the terminal of the processing of picture filter
CN110115841A (en) * 2019-05-10 2019-08-13 网易(杭州)网络有限公司 The rendering method and device of vegetation object in a kind of scene of game
CN111899192A (en) * 2020-07-23 2020-11-06 北京字节跳动网络技术有限公司 Interaction method, interaction device, electronic equipment and computer-readable storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
姚海根: "照相机原始数据图像的参数调整", 《出版与印刷》 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114092608A (en) * 2021-11-17 2022-02-25 广州博冠信息科技有限公司 Expression processing method and device, computer readable storage medium and electronic equipment
CN114092608B (en) * 2021-11-17 2023-06-13 广州博冠信息科技有限公司 Expression processing method and device, computer readable storage medium and electronic equipment

Also Published As

Publication number Publication date
CN112367399B (en) 2022-06-14

Similar Documents

Publication Publication Date Title
CN110196746B (en) Interactive interface rendering method and device, electronic equipment and storage medium
CN109460233B (en) Method, device, terminal equipment and medium for updating native interface display of page
US20140143305A1 (en) Apparatus and system for providing software service using software virtualization and method thereof
CN111932664A (en) Image rendering method and device, electronic equipment and storage medium
CN110555900B (en) Rendering instruction processing method and device, storage medium and electronic equipment
WO2016181804A1 (en) Image processing device and method
CN112651475B (en) Two-dimensional code display method, device, equipment and medium
CN111813472A (en) Application interface conversion method and device
CN112891946B (en) Game scene generation method and device, readable storage medium and electronic equipment
CN110134300A (en) A kind of picture editing method and device
CN111583379A (en) Rendering method and device of virtual model, storage medium and electronic equipment
CN109472852A (en) Display methods and device, the equipment and storage medium of point cloud chart picture
CN111540032B (en) Model control method and device based on audio frequency, medium and electronic equipment
US10186185B2 (en) Dynamically adjusting color characteristics of electronic content
JP7261732B2 (en) Method and apparatus for determining character color
CN112367399B (en) Filter effect generation method and device, electronic device and storage medium
CN110782387A (en) Image processing method and device, image processor and electronic equipment
CN111008934B (en) Scene construction method, device, equipment and storage medium
KR102623148B1 (en) Electronic apparatus and controlling method thereof
CN105051788A (en) Graphics processing using multiple primitives
CN116821080A (en) Online picture compression method and device, electronic equipment and storage medium
CN116962813A (en) YUV data rendering system and method, electronic equipment and storage medium
CN110555799A (en) Method and apparatus for processing video
CN107680038B (en) Picture processing method, medium and related device
CN114307143A (en) Image processing method and device, storage medium and computer equipment

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