Target image display method, video player, electronic equipment and storage medium

Automatically create and display the target image in the floating window through the video player, solving the complex problems of user operations in the existing technology and improving user experience and operation efficiency.

CN118921525APending Publication Date: 2024-11-08SHANGHAI ZHISHAN NETWORK TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310506184.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-05-06
Publication Date
2024-11-08

AI Technical Summary

Technical Problem

In the prior art, when a user displays an image at a certain moment in the video in a floating window when viewing a video, he or she needs to perform complex operation steps to affect the user experience.

Method used

Provide a method of displaying target images, creating a floating window through a video player and obtaining target image data. Users only need to perform preset operations to automatically create and display the target image in the floating window, reducing user operation steps.

Benefits of technology

Improve the user experience and simplify the operation process. Users only need to perform preset operations and move operations to achieve display of target images and position adjustment of floating windows.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118921525A_ABST
    Figure CN118921525A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a target image display method, a video player, electronic equipment and a storage medium, the display method performs display based on the video player, and the display method comprises the following steps: in response to a preset operation on a target image, creating a floating window, and obtaining data of the target image; and displaying the target image in the floating window based on the acquired data of the target image. By adopting the scheme, the user operation can be reduced, and the user experience is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present invention relate to the field of computer technology, and in particular to a method for displaying a target image, a video player, an electronic device, and a storage medium. Background Art

[0002] When users watch videos, they will display and compare the images displayed at a certain moment in the video through a floating window based on reference assistance needs. One existing display solution is that the user first downloads the video to the local terminal device and stores it as a local file, and then the user starts a specific program to import the local file into the floating window and select the target image for display. Another existing display solution is that the user first selects the target image to generate a screenshot and stores it as a local file, and then the user starts a specific program to import the stored local file into the floating window and open it for display.

[0003] For the first display scheme, the user needs to perform multiple operation steps including selecting to save the video locally, specifying the save path, using a specific program to open the local file, and selecting the target image. For the second display scheme, the user needs to perform multiple operation steps including selecting the target object in a specific area, selecting to save the image locally, specifying the save path, and using a specific program to open the local file. The above two display schemes require users to perform complex operation steps, which affects the user experience.

[0004] The contents of the background technology section are merely the technologies known to the public and do not necessarily represent the existing technologies in the field. Summary of the invention

[0005] In view of this, an embodiment of the present invention provides a method for displaying a target image, a video player, an electronic device and a storage medium, which can reduce user operations and improve user experience.

[0006] First, an embodiment of the present invention provides a method for displaying a target image based on a video player. The method includes:

[0007] In response to a preset operation on the target image, a floating window is created to obtain data of the target image;

[0008] Based on the acquired data of the target image, the target image is displayed in the floating window.

[0009] Optionally, it also includes:

[0010] In response to a preset operation on the target image, controlling the created floating window to be in a selected state;

[0011] In response to a move operation on the floating window, the floating window is moved to a target position.

[0012] Optionally, the preset operation includes: a first sub-operation and a second sub-operation that are consecutive, and the creating of a floating window in response to the preset operation on the target image and requesting data of the target image includes at least one of the following:

[0013] In response to the first sub-operation, the floating window is created; in response to the second sub-operation, a request is made to obtain data of the target image;

[0014] In response to the first sub-operation, creating the floating window, and in response to the consecutive first sub-operation and the second sub-operation, requesting to obtain data of the target image;

[0015] In response to the first sub-operation, requesting to obtain data of the target image, and in response to the consecutive first sub-operation and the second sub-operation, creating a floating window;

[0016] In response to the first sub-operation, requesting to obtain data of the target image; and in response to the second sub-operation, creating the floating window;

[0017] In response to the second sub-operation, creating the floating window, and in response to the consecutive first sub-operation and the second sub-operation, requesting to obtain data of the target image;

[0018] In response to the second sub-operation, requesting to obtain data of the target image, and in response to the consecutive first sub-operation and the second sub-operation, creating a floating window;

[0019] In response to the consecutive first sub-operation and the second sub-operation, the floating window is created, and a request is made to obtain data of the target image.

[0020] Optionally, the first sub-operation includes:

[0021] Select the video player;

[0022] The second sub-operation may include at least one of the following:

[0023] Continuously selecting the video player exceeds a second preset time period;

[0024] After pressing the middle button of the mouse, the mouse moves a preset distance within a third preset time.

[0025] Optionally, acquiring the data of the target image includes:

[0026] Acquire the data of the target image parsed by the video player;

[0027] And / or, parsing the video containing the target image to obtain data of the target image.

[0028] Optionally, in response to the preset operation, the video player is in a video playing state or a pause state.

[0029] Optionally, the creating a floating window includes at least one of the following:

[0030] Creating the floating window with the current operation position of the preset operation as the center point of the floating window;

[0031] The floating window is created on top of the display screen.

[0032] The embodiment of the present invention further provides a video player, including:

[0033] A playback unit, adapted to play images to form a video stream;

[0034] A processing unit, adapted to create a floating window in response to a preset operation on a target image, and obtain data of the target image;

[0035] A display unit displays the target image in the floating window based on the acquired data of the target image.

[0036] Optionally, the processing unit is adapted to control the created floating window to be in a selected state in response to a preset operation on the target image; and is adapted to move the floating window to a target position in response to a move operation on the floating window.

[0037] An embodiment of the present invention further provides an electronic device, including a memory, a processor, and a display, wherein:

[0038] The memory is adapted to store the video player, the image and / or video file, and the data of the target image acquired by the video player in response to a preset operation;

[0039] The processor is adapted to run a video player stored in the memory, and execute the steps of the display method described in any of the above examples by running the video player to display the target image;

[0040] The display is used to provide a display interface.

[0041] An embodiment of the present invention further provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed, the steps of the display method described in any of the above examples are executed.

[0042] By adopting the display method in the embodiment of the present invention, in response to a preset operation on a target image, the video player can directly create a floating window, obtain data of the target image, and display the target image in the floating window based on the acquired data of the target image. During the whole process, the user only needs to execute the preset operation to automatically create a floating window and display the target image in the floating window, thereby reducing user operations and improving user experience.

[0043] Furthermore, in response to a preset operation on the target image, the video player can control the floating window to be in a selected state. At this time, in response to a move operation on the floating window, the floating window can be moved to the target position. During the entire process, the user only needs to perform the preset operation and the move operation to move the floating window to the target position, thereby reducing user operations and improving user experience.

[0044] Furthermore, the preset operation includes a continuous first sub-operation and a second sub-operation. By flexibly setting the response relationship between the two continuous sub-operations and the video player creating the floating window and requesting to obtain the data of the target image, it can adapt to different user habits and performance parameters of electronic devices, thereby increasing the universality of the display method.

[0045] Furthermore, by flexibly setting the creation position when creating the floating window, the subsequent movement operations that the user may perform on the floating window can be reduced, thereby reducing user operations and improving user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] In order to more clearly illustrate the technical solutions of the embodiments of this specification, the drawings required for use in the embodiments of this specification or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0047] Figure 1 A schematic diagram showing a flow chart of a method for displaying a target image in an embodiment of the present invention is shown;

[0048] Figure 2 A schematic flow chart showing another method for displaying a target image in an embodiment of the present invention is shown;

[0049] Figure 3 A schematic diagram of the structure of a video player in an embodiment of the present invention is shown;

[0050] Figure 4 A schematic structural diagram of an electronic device in an embodiment of the present invention is shown. DETAILED DESCRIPTION

[0051] As described in the background art, currently when a user sets an image displayed at a certain moment in a video to be displayed in a floating window, the following two solutions are usually adopted:

[0052] A) The user first downloads the video to the local terminal device and stores it as a local file. The user then starts a specific program to import the local file into the floating window and selects the target image for display;

[0053] B) The user first selects the target image to generate a screenshot and stores it as a local file, and then the user starts a specific program to import the local file into the floating window and open it for display.

[0054] For solution A), the user needs to perform multiple operation steps including manually selecting to save the video locally, specifying the save path, searching for local files, using a specific program to open the local file, and selecting the target image.

[0055] For solution B), the user needs to perform multiple operation steps including manually selecting the target image, determining to save the image, specifying the save path, searching for local files, and using a specific program to open the local file.

[0056] The above two display solutions require users to perform complex operation steps, resulting in poor user experience.

[0057] In order to solve the above problems, the embodiments of the present invention provide a method for displaying a target image, a video player, an electronic device and a storage medium, which improve the efficiency of human-computer interaction, reduce user operations and enhance user experience.

[0058] In order to enable those skilled in the art to better understand and implement the embodiments of the present invention, the concepts, schemes, principles and advantages of the embodiments of the present invention are described in detail below through specific application examples in conjunction with the accompanying drawings.

[0059] Firstly, an embodiment of the present invention provides a method for displaying a target image, which is displayed based on a video player. The video player is suitable for playing images to form a video stream.

[0060] Reference Figure 1 , the following steps can be used to display the target image.

[0061] Step S01, in response to a preset operation on the target image, creating a floating window and acquiring data of the target image.

[0062] Specifically, the video player can directly create a floating window and obtain data of the target image in response to a user's preset operation on the target image.

[0063] In a specific implementation, the video player can create the floating window in multiple locations.

[0064] For example, the creation position of the floating window can be the top, bottom, left edge, right edge or any other position specified by the user when the electronic device display interface is created. For another example, the center position when the floating window is created is the operation position of the preset operation (such as the position of the mouse cursor).

[0065] In a specific implementation, the video player may set the floating window size in a variety of ways.

[0066] For example, the ratio of the floating window size to the display interface size of the video player can be set to 1:1, or the ratio of the floating window size to the display interface size of the electronic device can be set to 1:4. For another example, specific values ​​can be set for the length and width of the floating window.

[0067] By flexibly setting the creation position and size of the floating window according to user habits and electronic device parameters, the subsequent movement and adjustment operations that users may perform on the floating window can be reduced, thereby reducing user operations and improving user experience.

[0068] It is understandable that the creation position of the floating window and the setting method of the floating window size are not limited to the implementation methods shown in the above examples, and other implementation methods may also be used. The above examples do not impose any restrictions on the creation position of the floating window and the setting method of the floating window size.

[0069] When the video player plays a video, it needs to first parse the video into corresponding data sets, and then process the data sets according to the corresponding time sequence, and finally form a video stream on the display interface.

[0070] In a specific implementation, acquiring the data of the target object may include acquiring an original image frame corresponding to the target object existing in the data set.

[0071] At the same time, the video player has an advance parsing mechanism, which can parse the data corresponding to the target image in advance before displaying the target object.

[0072] Therefore, the acquiring of the data of the target object may include multiple acquiring methods.

[0073] For example, the data of the target image parsed by the video player may be obtained. For another example, the video containing the target image may be parsed to obtain the data of the target image.

[0074] In a specific implementation, the acquired data of the target image may include multiple storage modes. Specifically, the acquired data of the target image may be stored in a memory.

[0075] In some optional examples, the data of the target image may be stored in an internal memory, such as a random access memory (RAM), a video memory, a cache, or other storage devices for a central processing unit (CPU) to directly exchange data with external devices.

[0076] Correspondingly, the target image data stored in the internal memory may include: the target image data obtained by the video player. Specifically, the target image data may be stored in the internal memory in the form of image frames.

[0077] In some other optional examples, the data of the target image is stored in an external memory, such as a hard disk, a floppy disk, a flash memory (Flash Memory, flash) or other storage devices that can store data for a long time.

[0078] Correspondingly, the target image data stored in the external memory may include: the target image data obtained by re-encoding the target image data obtained after parsing by the video player.

[0079] Specifically, the data of the target image can be stored in the external memory in the form of an image file, such as GIF (Graphics Interchange Font), BMP (Bitmap), etc.

[0080] Taking user habits into consideration and further improving the user experience, in a specific implementation, when responding to the preset operation, there is no restriction on the state of the video player, and the video player can be in different states.

[0081] For example, the video player is in a video playing state. For another example, the video player is in a paused state.

[0082] Step S02: displaying the target image in the floating window based on the acquired data of the target image.

[0083] Specifically, the video player transmits the data of the target image stored in the memory to the floating window so that the target image is displayed.

[0084] The data of the target image transmitted to the floating window may include: a corresponding original image frame and / or an image file formed by re-encoding the original image frame.

[0085] Compared with the manual screenshot display method, which has problems such as inaccurate capture area, incomplete picture, and low picture quality, the data of the target image transmitted to the floating window has higher accuracy. When displayed in the floating window, it can be displayed on the display interface of the electronic device with the highest accuracy, thereby improving the display quality and user experience.

[0086] By adopting the above embodiment, through the response of the video player to the preset operation, the user only needs to perform the preset operation on the target image to realize the display of the target image in the floating window, and the related operation steps such as the user manually creating a floating window, obtaining the target image and displaying it in the floating window can be omitted, thereby reducing user operations and improving user experience.

[0087] In some embodiments of the present invention, reference Figure 2 , step S01 may further include:

[0088] In response to a preset operation on the target image, the created floating window is controlled to be in a selected state.

[0089] Accordingly, the display method may further include:

[0090] Step S03, in response to the movement operation of the floating window, moving the floating window to a target position.

[0091] The target location may include any location specified by a user.

[0092] Specifically, in response to a preset operation on the target image, the video player can control the floating window to be in a selected state. At this time, in response to a move operation on the floating window, the floating window can be moved to the target position. During the whole process, the user only needs to execute the preset operation and the move operation to move the floating window to the target position, and the operation step of the user selecting the floating window can be omitted, thereby reducing user operations and improving user experience.

[0093] In a specific implementation, the display method can be applied to a variety of electronic devices with human-computer interaction functions. For example, it can be applied to electronic devices that perform user interaction through a mouse. For another example, it can be applied to electronic devices that perform user interaction through a touch screen.

[0094] The preset operation may be different according to different human-computer interaction modes of the electronic device.

[0095] As some optional examples, for an electronic device that performs user interaction via a mouse, the preset operations may include: the user clicking one or more of the left, right, middle or other buttons of the mouse; or continuously pressing one or more of the left, right, middle or other buttons of the mouse for more than a second preset duration.

[0096] The second preset duration may be specified by the video player or the user.

[0097] As other optional examples, for an electronic device that performs user interaction through the touch screen, the preset operation may include: the user uses a finger / stylus to tap the target image in the display interface of the touch screen; or continuously presses the touch screen for more than a second preset time period.

[0098] It is understandable that the implementation of human-computer interaction and corresponding preset operations is not limited to the above-mentioned methods, but may also be other methods, and the above examples do not constitute any limitation thereto.

[0099] It should be noted that the preset operation on the target image should not be understood as a direct operation of the target image by the user. In actual operation, it can be an operation performed directly on the target image, or it can be an operation performed in an area other than the target image on the display interface. The video player can respond when it detects the preset operation.

[0100] In a specific implementation, the preset operation may include a plurality of consecutive sub-operations, and there may be various adaptation relationships between the creation of the floating window by the video player and the request for obtaining the data of the target image.

[0101] Specifically, the creation of the floating window and the request for obtaining the data of the target image by the video player may respectively respond to one or more different continuous sub-operations, or may respond to the same one or more continuous sub-operations.

[0102] The multiple continuous sub-operations refer to multiple sub-operations occurring within a first preset duration, and the first preset duration is greater than or equal to the maximum time difference between the initial execution times of the sub-operations detected by the video player.

[0103] By flexibly setting the response relationship between the multiple consecutive sub-operations and the video player creating the floating window and requesting to obtain the data of the target image, it is possible to adapt to different user habits and performance parameters of electronic devices, thereby increasing the universality of the display method.

[0104] In a specific implementation, the preset operation may include: a continuous first sub-operation and a second sub-operation.

[0105] The response relationship between the video player and the consecutive first sub-operation and the second sub-operation is explained in detail below in conjunction with a specific implementation.

[0106] In an optional example, in response to the first sub-operation, the floating window is created, and in response to the second sub-operation, a request is made to obtain data of the target image.

[0107] The first sub-operation may include clicking the middle button of a mouse, and the second sub-operation may include clicking the pause button of the video player with the left button of a mouse.

[0108] When the video player detects that the user clicks the middle button of the mouse, in response to the first sub-operation, a floating window with a size equal to the current video screen size can be directly created on the top of the display interface of the electronic device.

[0109] When the video player detects that the user pauses the video using the left mouse button, in response to the second sub-operation, it can directly request to obtain the data corresponding to the target image displayed on the current display interface of the video player, and re-encode it into an image file (for example, GIF format) and store it in an external storage device (for example, a local hard disk) with a specified path.

[0110] When the video player completes the creation of the floating window and the request for obtaining the data corresponding to the image, the video player can control the floating window to read the image content from the corresponding image file stored in the external storage device, and draw the image content as the background on the floating window to display the target image.

[0111] In the above example, the video player creates the floating window and requests the acquisition of data of the target image only in response to the corresponding sub-operations.

[0112] In another optional example, in response to the first sub-operation, the floating window is created, and in response to the consecutive first sub-operation and the second sub-operation, a request is made to obtain data of the target image.

[0113] The first sub-operation may include continuously pressing the middle mouse button for more than the second preset time length (eg, 200 milliseconds), and the second sub-operation may include clicking the pause button of the video player with the left mouse button.

[0114] When the video player detects that the user continues to press the middle mouse button for more than the second preset time, in response to the first sub-operation, it can directly create a floating window with a size equal to the current video screen size on the right edge of the display interface of the electronic device, and control the floating window to always be in a selected state before detecting that the user stops pressing the middle mouse button.

[0115] When the floating window is in a selected state, if the video player detects a user's movement operation on the floating window, in response to the movement operation, the floating window can be moved to a position specified by the user for display.

[0116] If the video player detects the first sub-operation and the second sub-operation within a period of time, and the duration from the current time node when it detects that the user continuously presses the middle mouse button for more than the second preset time length to the current time node when it detects that the user uses the left mouse button to pause the video is less than or equal to the first preset time length (for example, 30 seconds), then in response to the subsequent sub-operation, the video player can directly request to obtain the data corresponding to the target image in image frame format, and store it in an internal storage device (for example, RAM).

[0117] When the video player completes the creation of the floating window and the request for obtaining the data corresponding to the image, the video player can control the floating window to read the image content from the corresponding image frame stored in the internal storage device, and draw the image content as the background on the floating window to display the target image.

[0118] In the above example, the video player can execute the two actions of creating the floating window and controlling the floating window to be in a selected state in response to the first sub-operation; and for other actions except the above actions, the video player must respond to the consecutive first sub-operation and the second sub-operation to execute.

[0119] In another optional example, in response to the first sub-operation, a request is made to obtain data of the target image, and in response to the consecutive first sub-operation and the second sub-operation, a floating window is created.

[0120] The first sub-operation may include continuously pressing the middle button of the mouse for more than the second preset time period (eg, 100 milliseconds), and the second sub-operation may include pressing the left button of the mouse.

[0121] It should be noted that, in this example, the second preset durations corresponding to the first sub-operation and the second sub-operation may be the same or different.

[0122] When the video player detects that the user continues to press the middle mouse button for more than the second preset time, in response to the first sub-operation, it can directly request to obtain the data corresponding to the target image, and re-encode it into an image file (for example, BMP format) and store it in an external storage device (for example, flash memory) with a specified path.

[0123] The target picture obtained is the image displayed on the display interface of the video player at the moment when the second preset duration is reached.

[0124] If the video player detects the first sub-operation and the second sub-operation within a period of time, and the duration from the current time node when it is detected that the user continues to press the middle mouse button for more than the second preset time length to the current time node when it is detected that the user stops pressing the left mouse button is less than or equal to the first preset time length (for example, 20 seconds), then in response to the subsequent sub-operation, a floating window with a ratio of 1:4 to the size of the display interface can be directly created at the left edge of the display interface of the electronic device, and before the first sub-operation and the second sub-operation are completed, the floating window is controlled to always be in a selected state.

[0125] When the floating window is in a selected state, if the video player detects a user's movement operation on the floating window, in response to the movement operation, the floating window can be moved to a position specified by the user for display.

[0126] When the video player completes the creation of the floating window and the request for obtaining the data corresponding to the image, the video player can control the floating window to read the image content from the corresponding image file stored in the external storage device, and draw the image content as the background on the floating window to display the target image.

[0127] In the above example, the video player can execute two actions, namely, requesting to obtain data of the target image and storing data, in response to the first sub-operation; and for other actions except the above actions, the video player must respond to the consecutive first sub-operation and the second sub-operation before they can be executed.

[0128] In another optional example, in response to the second sub-operation, the floating window is created, and in response to the first sub-operation, a request is made to obtain data of the target image.

[0129] The first sub-operation may include clicking the pause button of the video player with the left button of the mouse, and the second sub-operation may include clicking the middle button of the mouse.

[0130] When the video player detects that the user pauses the video using the left mouse button, in response to the first sub-operation, it can directly request to obtain the data corresponding to the target image displayed on the current display interface of the video player, and re-encode it into an image file (for example, GIF format) and store it in an external storage device (for example, a local hard disk) with a specified path.

[0131] When the video player detects that the user clicks the middle button of the mouse, in response to the second sub-operation, a floating window with a size equal to the current video screen size can be directly created on the top of the display interface of the electronic device.

[0132] When the video player completes the creation of the floating window and the request for obtaining the data corresponding to the image, the video player can control the floating window to read the image content from the corresponding image file stored in the external storage device, and draw the image content as the background on the floating window to display the target image.

[0133] In the above example, the video player creates the floating window and requests the acquisition of data of the target image only in response to the corresponding sub-operations.

[0134] In another optional example, in response to the second sub-operation, the floating window is created, and in response to the consecutive first sub-operation and the second sub-operation, a request is made to obtain data of the target image.

[0135] The first sub-operation may include clicking the pause button of the video player with the left button of the mouse, and the second sub-operation may include continuously pressing the middle button of the mouse for more than the second preset time length (eg, 200 milliseconds).

[0136] When the video player does not detect the user continuously pressing the middle mouse button for more than the second preset time period within the first preset time period starting from the current time node when the user clicks the pause button of the video player with the left mouse button, the video player does not respond to the first sub-operation.

[0137] When the video player detects that the user continues to press the middle mouse button for more than the second preset time, in response to the second sub-operation, a floating window with a size equal to the current video screen size can be directly created on the right edge of the display interface of the electronic device, and the floating window is controlled to always be in a selected state before detecting that the user stops pressing the middle mouse button.

[0138] When the floating window is in a selected state, if the video player detects a user's movement operation on the floating window, in response to the movement operation, the floating window can be moved to a position specified by the user for display.

[0139] If the video player detects the first sub-operation and the second sub-operation within a period of time, and the duration from the current time node when it detects that the user continuously presses the middle mouse button for more than the second preset time length to the current time node when it detects that the user uses the left mouse button to pause the video is less than or equal to the first preset time length (for example, 30 seconds), then in response to the subsequent sub-operation, the video player can directly request to obtain the data corresponding to the target image in image frame format, and store it in an internal storage device (for example, RAM).

[0140] When the video player completes the creation of the floating window and the request for obtaining the data corresponding to the image, the video player can control the floating window to read the image content from the corresponding image frame stored in the internal storage device, and draw the image content as the background on the floating window to display the target image.

[0141] In the above example, the video player can execute the two actions of creating the floating window and controlling the floating window to be in a selected state in response to the second sub-operation; and for other actions except the above actions, the video player must respond to the consecutive first sub-operation and the second sub-operation to execute.

[0142] In another optional example, in response to the second sub-operation, a request is made to obtain data of the target image, and in response to the consecutive first sub-operation and the second sub-operation, a floating window is created.

[0143] The first sub-operation may include pressing the left mouse button for more than the second preset time (eg, 100 milliseconds), and the second sub-operation may include continuously pressing the middle mouse button for more than the second preset time (eg, 100 milliseconds).

[0144] It should be noted that, in this example, the second preset durations corresponding to the first sub-operation and the second sub-operation may be the same or different.

[0145] When the video player detects that the user has continuously pressed the left mouse button for longer than the second preset time period and does not detect that the user has continuously pressed the middle mouse button for longer than the second preset time period within the first preset time period starting from the current time node, the video player does not respond to the first sub-operation.

[0146] When the video player detects that the user continues to press the middle mouse button for more than the second preset time, in response to the second sub-operation, it can directly request to obtain the data corresponding to the target image, and re-encode it into an image file (for example, BMP format) and store it in an external storage device (for example, flash memory) with a specified path.

[0147] The target picture obtained is the image displayed on the display interface of the video player at the moment when the user presses the middle button of the mouse for more than a second preset time.

[0148] If the video player detects the first sub-operation and the second sub-operation within a period of time, and the duration from the current time node when it is detected that the user has continuously pressed the left mouse button for more than the second preset time period to the current time node when it is detected that the user has continuously pressed the middle mouse button for more than the second preset time period is less than or equal to the first preset time period (for example, 20 seconds), then in response to the subsequent sub-operation, a floating window with a ratio of 1:4 to the size of the display interface can be directly created at the left edge of the display interface of the electronic device, and before the first sub-operation and the second sub-operation are completed, the floating window is controlled to always be in a selected state.

[0149] When the floating window is in a selected state, if the video player detects a user's movement operation on the floating window, in response to the movement operation, the floating window can be moved to a position specified by the user for display.

[0150] When the video player completes the creation of the floating window and the request for obtaining the data corresponding to the image, the video player can control the floating window to read the image content from the corresponding image file stored in the external storage device, and draw the image content as the background on the floating window to display the target image.

[0151] In the above example, the video player can execute the two actions of requesting to obtain the data of the target image and storing the data in response to the second sub-operation; and for other actions except the above actions, the video player must respond to the consecutive first sub-operation and the second sub-operation before they can be executed.

[0152] In another optional example, in response to the consecutive first sub-operation and the second sub-operation, the floating window is created, and a request is made to obtain data of the target image.

[0153] The first sub-operation may include clicking the pause button of the video player with the left button of the mouse, and the second sub-operation may include clicking the middle button of the mouse.

[0154] If the video player detects the left mouse button clicking the video player pause button and the middle mouse button clicking within a period of time, and the duration from the current time node when the user releases the left mouse button to the current time node when the user releases the middle mouse button is detected is less than or equal to a first preset duration (for example, 15 seconds), then in response to the subsequent sub-operation, a floating window with a size equal to the current video screen size can be created directly with the current position of the mouse cursor as the center, and a direct request can be made to obtain the data corresponding to the target image, and the data is re-encoded into an image file (for example, BMP format) and stored in an external storage device (for example, flash memory) with a specified path.

[0155] The target screen obtained is the image displayed on the display interface of the video player at the moment when all sub-operations are completed.

[0156] When the video player completes the creation of the floating window and the request for obtaining the data corresponding to the image, the video player can control the floating window to read the image content from the corresponding image file stored in the external storage device, and draw the image content as the background on the floating window to display the target image.

[0157] In the above example, all actions of the video player can be executed only after responding to the consecutive first sub-operation and the second sub-operation.

[0158] In a specific implementation, each sub-operation is not limited to a single operation, but may also include a combination of operations.

[0159] In an optional example, in response to the first sub-operation, a request is made to obtain data of the target image, and in response to the consecutive first sub-operation and the second sub-operation, the floating window is created.

[0160] Among them, the first sub-operation may include selecting the video player, for example, selecting the video player by clicking the left button of the mouse; the second sub-operation may include continuously selecting the video player for more than a second preset time length; and / or, moving a preset distance within a third preset time length after pressing the middle button of the mouse.

[0161] When the video player detects that the user selects the video player by clicking the left mouse button, in response to the first sub-operation, it can directly request to obtain the data corresponding to the target image, and re-encode it into an image file (such as GIF format) and store it in an external storage device (such as flash memory) with a specified path.

[0162] If the video player detects within a period of time that the video player is selected by the left mouse button and moves a preset distance within a third preset time length after the middle mouse button is pressed, and the time length from the current time node when the user releases the left mouse button to the current time node when the user completes pressing the middle mouse button and moves a preset distance (for example, 10 pixels) within a third preset time length (for example, 200 milliseconds) is less than or equal to the first preset time length (for example, 15 seconds), then in response to the subsequent sub-operation, a floating window with a size equal to the current video screen size can be directly created with the current position of the mouse cursor as the center.

[0163] When the video player completes the creation of the floating window and the request for obtaining the data corresponding to the image, the video player can control the floating window to read the image content from the corresponding image file stored in the external storage device, and draw the image content as the background on the floating window to display the target image.

[0164] During the time period from the creation of the floating window to the detection that the user stops pressing the middle mouse button, the preset operation has not ended, and the video player controls the floating window to be in a selected state. At this time, the video player can respond to the user's movement operation on the floating window and move the floating window to the user-specified position for display.

[0165] It can be understood that the specific values ​​of the first preset time length, the second preset time length, the third preset time length and the preset distance are not limited to the values ​​listed above, but can also be other values. The above examples do not constitute any limitation on the actual values ​​of the first preset time length, the second preset time length, the third preset time length and the preset distance.

[0166] In order to display the target image, the embodiment of the present invention further provides a video player suitable for displaying the target object, such as Figure 3 As shown, the video player 10 may include: a processing unit 11 and a display unit 12, wherein:

[0167] The processing unit 11 is adapted to create a floating window in response to a preset operation on a target image and obtain data of the target image;

[0168] The display unit 12 displays the target image in the floating window based on the acquired data of the target image.

[0169] Using the above embodiment, the playback unit plays the image to form a video stream. In response to the user's preset operation on the target image, the processing unit can directly create a floating window and obtain the data of the target image. Based on the obtained data of the target image, the display unit can display the target image in the floating window. The user only needs to perform the preset operation on the target image to display the target image in the floating window. The related operation steps of manually creating a floating window, obtaining the target image and displaying it in the floating window can be omitted, thereby reducing user operations and improving user experience.

[0170] In a specific implementation, the processing unit is further adapted to control the created floating window to be in a selected state in response to a preset operation on the target image; and to move the floating window to a target position in response to a move operation on the floating window.

[0171] Specifically, the processing unit responds to a preset operation on the target image, and the video player can control the floating window to be in a selected state. At this time, in response to a move operation on the floating window, the floating window can be moved to the target position. During the whole process, the user only needs to execute the preset operation and the move operation to move the floating window to the target position, and the operation step of the user selecting the floating window can be omitted, thereby reducing user operations and improving user experience.

[0172] In the specific implementation, continue to refer to Figure 3 The processing unit 11 may include a creation module 111, an acquisition module 112, a parsing module 113 and a control module 114, wherein:

[0173] The creation module 111 is adapted to create a floating window in response to the preset operation;

[0174] The acquisition module 112 is adapted to request acquisition of the target image data in response to the preset operation;

[0175] The parsing module 113 is adapted to parse the multimedia file into a data set containing data corresponding to the target image;

[0176] The control module 124 is adapted to control the created floating window to be in a selected state in response to a preset operation on the target image; and to move the floating window to a target position in response to a move operation on the floating window.

[0177] In a specific implementation, the video player is suitable for playing images to form a video stream.

[0178] In a specific implementation, the parsing module may include a FFmpeg decoder.

[0179] In a specific implementation, the video player may use the display method in any of the aforementioned embodiments to display the target image. For details, please refer to the aforementioned embodiments, which will not be described in detail here.

[0180] In order to display the target image, an embodiment of the present invention further provides an electronic device that can be used for human-computer interaction. Figure 4 , the electronic device 20 may include: a memory 21, a processor 22 and a display 23, wherein:

[0181] The memory 21 is adapted to store the video player 211, the multimedia file 212, and the data of the target image acquired by the video player 211 in response to a preset operation;

[0182] The processor 22 is adapted to run the video player 211 stored in the memory 21, and execute the method for displaying a target image in any of the above-mentioned embodiments by running the video player 211 to display the target image;

[0183] The display 23 is used to provide a display interface.

[0184] Specifically, the multimedia file can be played as an image through the video player.

[0185] It is understandable that the embodiment of the present invention does not limit the format of the multimedia file, such as one or more of a video file, an image file, or other file formats that can output continuously changing images through the video player.

[0186] In a specific implementation, the memory includes at least one type of readable storage medium.

[0187] In some optional examples, the memory may be an internal storage unit of the electronic device, such as a random access memory (RAM), video memory, cache, or other storage device for directly exchanging data between a central processing unit (CPU) and an external device.

[0188] In some other optional examples, the memory may also be an external storage device of the electronic device, such as a hard disk, a floppy disk, a flash memory (Flash Memory, flash) or other storage devices that can store data for a long time.

[0189] In a specific implementation, the processor may be any one or more of a central processing unit (CPU), a controller, a microcontroller, a microprocessor, etc.

[0190] In a specific implementation, the display may be used only to provide a display interface; or, in addition to providing a display interface, the display may also provide human-computer interaction. For example, the display is a touch screen, and human-computer interaction may be provided by pressing or touching.

[0191] In a specific implementation, the electronic device can be a computer PC, a mobile phone, a tablet device, or any other computer device with a display interface and on which a resource manager-type program can be installed, in which the processor, the memory, and the display are integrated into one, or a cloud platform in which the processor, the memory, and the display are distributed.

[0192] In a specific implementation, the electronic device may support the use of a mouse, a finger, a stylus, or any other interactive operation method.

[0193] In addition, an embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is running, the steps of any one of the target image display methods in the aforementioned embodiments can be executed. For details, please refer to the aforementioned embodiments, which will not be repeated here.

[0194] Although the embodiments of this specification are disclosed as above, the present invention is not limited thereto. Any person skilled in the art can make various changes and modifications without departing from the spirit and scope of the present invention, so the protection scope of the present invention shall be subject to the scope defined by the claims.

Claims

1. A method for displaying a target image, characterized in that: The display is performed based on a video player, and the display method includes: In response to a preset operation on the target image, a floating window is created to obtain data of the target image; Based on the acquired data of the target image, the target image is displayed in the floating window.

2. The display method according to claim 1, characterized in that: Also includes: In response to a preset operation on the target image, controlling the created floating window to be in a selected state; In response to a movement operation on the floating window, the floating window is moved to a target position.

3. The display method according to claim 1, characterized in that: The preset operation includes: a first sub-operation and a second sub-operation that are continuous, and the creating of a floating window in response to the preset operation on the target image and requesting data of the target image includes at least one of the following: In response to the first sub-operation, the floating window is created; in response to the second sub-operation, a request is made to obtain data of the target image; In response to the first sub-operation, creating the floating window, and in response to the consecutive first sub-operation and the second sub-operation, requesting to obtain data of the target image; In response to the first sub-operation, requesting to obtain data of the target image, and in response to the consecutive first sub-operation and the second sub-operation, creating a floating window; In response to the first sub-operation, requesting to obtain data of the target image; and in response to the second sub-operation, creating the floating window; In response to the second sub-operation, creating the floating window, and in response to the consecutive first sub-operation and the second sub-operation, requesting to obtain data of the target image; In response to the second sub-operation, requesting to obtain data of the target image, and in response to the consecutive first sub-operation and the second sub-operation, creating a floating window; In response to the consecutive first sub-operation and the second sub-operation, the floating window is created, and a request is made to obtain data of the target image.

4. The display method according to claim 3, characterized in that: The first sub-operation includes: Select the video player; The second sub-operation includes at least one of the following: Continuously selecting the video player exceeds a second preset time period; After pressing the middle button of the mouse, the mouse moves a preset distance within a third preset time.

5. The display method according to claim 1, characterized in that: The step of acquiring the target image data comprises: Acquire the data of the target image parsed by the video player; and / or, The video containing the target image is parsed to obtain data of the target image.

6. The display method according to claim 1, characterized in that: In response to the preset operation, the video player is in a video playing state or a pause state.

7. The display method according to claim 1, characterized in that: The creating of the floating window includes at least one of the following: Creating the floating window with the current operation position of the preset operation as the center point of the floating window; The floating window is created on top of the display screen.

8. A video player, characterized in that: include: A processing unit, adapted to create a floating window in response to a preset operation on a target image, and obtain data of the target image; A display unit displays the target image in the floating window based on the acquired data of the target image.

9. The video player according to claim 8, characterized in that: The processing unit is adapted to control the created floating window to be in a selected state in response to a preset operation on the target image; and The method is adapted to move the floating window to a target position in response to a movement operation on the floating window.

10. An electronic device, characterized in that: The device comprises a memory, a processor and a display, wherein: The memory is adapted to store the video player, the image and / or video file, and the data of the target image acquired by the video player in response to a preset operation; The processor is adapted to run a video player stored in the memory, and execute the steps of the display method according to any one of claims 1 to 7 by running the video player to display the target image; The display is used to provide a display interface.

11. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed, the steps of the display method according to any one of claims 1 to 7 are executed.