WO2022227978A1 - 显示方法及相关装置 - Google Patents

显示方法及相关装置 Download PDF

Info

Publication number
WO2022227978A1
WO2022227978A1 PCT/CN2022/083338 CN2022083338W WO2022227978A1 WO 2022227978 A1 WO2022227978 A1 WO 2022227978A1 CN 2022083338 W CN2022083338 W CN 2022083338W WO 2022227978 A1 WO2022227978 A1 WO 2022227978A1
Authority
WO
WIPO (PCT)
Prior art keywords
electronic device
content
instruction stream
map
application
Prior art date
Application number
PCT/CN2022/083338
Other languages
English (en)
French (fr)
Inventor
安文吉
朱欢欢
Original Assignee
华为技术有限公司
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 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP22794451.9A priority Critical patent/EP4316619A1/en
Publication of WO2022227978A1 publication Critical patent/WO2022227978A1/zh

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/50Controlling the output signals based on the game progress
    • A63F13/52Controlling the output signals based on the game progress involving aspects of the displayed game scene
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/25Output arrangements for video game devices
    • A63F13/26Output arrangements for video game devices having at least one additional display device, e.g. on the game controller or outside a game booth
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/50Controlling the output signals based on the game progress
    • A63F13/53Controlling the output signals based on the game progress involving additional visual information provided to the game scene, e.g. by overlay to simulate a head-up display [HUD] or displaying a laser sight in a shooting game
    • A63F13/533Controlling the output signals based on the game progress involving additional visual information provided to the game scene, e.g. by overlay to simulate a head-up display [HUD] or displaying a laser sight in a shooting game for prompting the player, e.g. by displaying a game menu
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/50Controlling the output signals based on the game progress
    • A63F13/53Controlling the output signals based on the game progress involving additional visual information provided to the game scene, e.g. by overlay to simulate a head-up display [HUD] or displaying a laser sight in a shooting game
    • A63F13/537Controlling the output signals based on the game progress involving additional visual information provided to the game scene, e.g. by overlay to simulate a head-up display [HUD] or displaying a laser sight in a shooting game using indicators, e.g. showing the condition of a game character on screen
    • A63F13/5378Controlling the output signals based on the game progress involving additional visual information provided to the game scene, e.g. by overlay to simulate a head-up display [HUD] or displaying a laser sight in a shooting game using indicators, e.g. showing the condition of a game character on screen for displaying an additional top view, e.g. radar screens or maps
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/14Digital output to display device ; Cooperation and interconnection of the display device with other functional units
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/14Digital output to display device ; Cooperation and interconnection of the display device with other functional units
    • G06F3/1454Digital output to display device ; Cooperation and interconnection of the display device with other functional units involving copying of the display data of a local workstation or window to a remote workstation or window so that an actual copy of the data is displayed simultaneously on two or more displays, e.g. teledisplay

Definitions

  • the present application relates to the field of terminal technologies, and in particular, to a display method and a related device.
  • a map can be displayed in some areas of the game interface of many video games for users to view the overall situation of the game.
  • the above-mentioned area where the map is displayed will cover part of the area where the game scene is displayed, so that the user's view of the game scene is blocked and the user's game experience is affected.
  • the present application provides a display method and a related device.
  • the method can display the first content and the second content of a user interface in one application on two electronic devices respectively, realize screen projection in the application, and prevent the second content in one user interface from blocking the first content.
  • the present application provides a display method, which can be applied to a first electronic device.
  • the first electronic device can run the first application and display the first user interface.
  • the first user interface may include first content and second content. Wherein, the second content is overlaid and displayed on a part of the first content.
  • the first user interface is associated with the first application.
  • the first electronic device may display the second user interface in response to the first operation.
  • the second user interface may include the first content, and a portion of the first content covered by the second content is presented on the second user interface.
  • the first electronic device may transmit the first data to the second electronic device.
  • the first data causes the second electronic device to display a third user interface.
  • the third user interface may include the second content. Wherein, the first electronic device and the second electronic device are connected in communication.
  • the second user interface may not include the second content.
  • the above-mentioned first content may include content in the first user interface that is not displayed due to being blocked by the first content.
  • the first electronic device can hand over the first content to the second electronic device for display. Then, in the second user interface, the part of the first content that is blocked by the second content can be displayed.
  • the above-mentioned first content may not be included in the above-mentioned third user interface.
  • the above-mentioned first user interface being related to the first application may mean that the first content and the second content in the first user interface may be obtained by running the first application.
  • the second electronic device displays the second content according to the above-mentioned first data.
  • the first application is not running in the second electronic device. That is, the data used by the second electronic device to draw the above-mentioned second content is provided by the first electronic device (ie, the first data).
  • the first electronic device can hand over part of the display content of a user interface in an application to the second electronic device for display, so as to realize screen projection in the application.
  • the above method can reduce the situation that the second content blocks the first content in a user interface. Users can get a better experience when using the above applications.
  • the above-mentioned second user interface may further include third content, and the third content may be displayed overlying part of the first content.
  • the third content may have transparency.
  • the size and position of the display area of the third content may be the same as the size and position of the display area of the second content, respectively.
  • the third content can be used to identify its own display area as the display area before the second content is projected.
  • the third content has transparency and will not completely block the part of the first content that was originally blocked by the second content.
  • the second user interface may include the first content described above but not the second content described above.
  • the specific method for displaying the second user interface by the first electronic device in response to the first operation may be: the first electronic device generates the second instruction stream and the third instruction stream according to the first instruction stream in response to the first operation.
  • the first instruction stream is associated with the first application.
  • the first electronic device may display the above-mentioned second user interface according to the second instruction stream.
  • the first electronic device may determine the above-mentioned first data according to the third instruction stream.
  • a target instruction library may be stored in the first electronic device.
  • the target instruction library may include the above-mentioned third instruction stream.
  • the method for the first electronic device to generate the second instruction stream and the third instruction stream according to the first instruction stream may be as follows: the first electronic device determines an instruction from the first instruction stream that matches the instruction in the target instruction library, and intercepts the instruction operate. After the above-mentioned interception operation, the first electronic device can distinguish the second instruction stream for drawing the first content and the third instruction stream for drawing the second content from the above-mentioned first instruction stream.
  • the above-mentioned target instruction library may be pre-stored by the first electronic device, or acquired from a cloud server.
  • the above-mentioned display method does not require the developer of the first application not to make adaptive modifications to the application.
  • the first electronic device may project a portion of the display content on a user interface in the first application to another device. This is beneficial for the display method provided by the present application to be suitable for various types of applications such as game applications, live broadcast applications, and video call applications.
  • the second user interface may further include third content.
  • the third content is displayed overlaid on a portion of the first content.
  • the third content may have transparency.
  • the specific method for displaying the second user interface by the first electronic device in response to the first operation may be: the first electronic device generates the second instruction stream and the third instruction stream according to the first instruction stream in response to the first operation.
  • the above-mentioned first instruction stream is related to the first application.
  • the first electronic device may generate a fourth instruction stream according to the third instruction stream, and generate a fifth instruction stream according to the second instruction stream and the fourth instruction stream.
  • the first electronic device may display the user interface including the first content and the third content according to the fifth instruction stream.
  • the first electronic device may determine the first data according to the third instruction stream.
  • the above-mentioned fourth instruction stream may include a target instruction library.
  • the fourth instruction stream may be used to draw the third content described above.
  • the first electronic device may acquire the above-mentioned fourth instruction stream from the target instruction library. Further, the first electronic device may generate the above-mentioned fifth instruction stream according to the second instruction stream and the fourth instruction stream.
  • the above-mentioned first data may be the above-mentioned third instruction stream.
  • the above-mentioned first data may be a first video stream.
  • the first video stream may be derived from image data containing the second content.
  • the above-mentioned image data including the second content may be obtained according to the third instruction stream.
  • the first electronic device may further receive a second operation acting on the first area of the second user interface, and execute an instruction in response to the second operation.
  • the above-mentioned first area may be an area in which the part of the first content covered by the second content is presented on the second user interface.
  • the above-mentioned first area may be a display area of the third content
  • the original display area of the second content is the above-mentioned first area.
  • the present application provides an electronic device, which is a first electronic device.
  • the first electronic device may include a first application, a screen-casting service calling module, a screen-casting module, an instruction interception module, a graphics processor GPU driver, a GPU, a display screen, and a storage module.
  • the first application is executable in the first electronic device.
  • the first electronic device runs the first application and invokes the three-dimensional graphics processing library to obtain the first instruction stream for drawing the first user interface.
  • the first user interface may include first content and second content.
  • the second content is displayed overlaid on a portion of the first content.
  • the above-mentioned first content may include content in the first user interface that is not displayed due to being blocked by the first content.
  • the above-mentioned first instruction may be passed from the first application to the instruction interception module.
  • the screen-casting service calling module may be configured to respond to the first operation, send an instruction to intercept the instruction stream to the instruction interception module, and send an instruction to enable the screen-casting function to the screen-casting module.
  • the instruction interception module can use the target instruction library to perform an interception operation on the first instruction stream to obtain the second instruction stream and the third instruction stream.
  • the above-mentioned target instruction library may include the above-mentioned third instruction stream.
  • the second instruction stream may be passed from the instruction interception module to the GPU driver.
  • the GPU driver can convert the second instruction stream into a program executable by the GPU, and drive the GPU to execute the executable program converted from the second instruction stream.
  • the GPU may obtain the image data of the above-mentioned first content.
  • the image data of the first content may be communicated to the display screen.
  • the display screen may display a second user interface.
  • the second user interface may include the first display content. The portion of the first content covered by the second content is presented on the second user interface.
  • the screen projection module can be used to send the first data to the second electronic device.
  • the first data may cause the second electronic device to display the third user interface.
  • the third user interface includes the second content.
  • the third user interface may not include the first content.
  • the above-mentioned first data may be determined according to the above-mentioned third instruction stream.
  • the above-mentioned storage module can be used to store the program installation package, the three-dimensional graphics processing library and the target instruction library of the first application.
  • the first electronic device can hand over part of the display content of a user interface in an application to the second electronic device for display, so as to realize screen projection in the application.
  • the above method can reduce the situation that the second content blocks the first content in a user interface. Users can get a better experience when using the above applications.
  • the instruction interception module may be further configured to generate a fourth instruction stream according to the third instruction stream, and generate a fifth instruction stream according to the second instruction stream and the fourth instruction stream.
  • the fourth instruction stream described above can be used to draw the third content.
  • the above-mentioned fifth instruction stream may be transmitted from the instruction interception module to the GPU driver.
  • the GPU driver can convert the fifth instruction stream into a program executable by the GPU, and drive the GPU to execute the executable program converted from the fifth instruction stream.
  • the GPU may obtain image data including the first content and the third content.
  • the image data of the first content and the third content may be transferred to the display screen.
  • the display screen may display a second user interface including the first content and the third content.
  • the third content is displayed overlaid on a portion of the first content.
  • the third content has transparency.
  • the size and position of the display area of the third content are respectively the same as the size and position of the display area of the second content.
  • the third content can be used to identify its own display area as the display area before the second content is projected.
  • the third content has transparency and will not completely block the part of the first content that was originally blocked by the second content.
  • the above-mentioned first data may be a third instruction stream. That is, when the command interception module obtains the third command stream, the screen projection module can send the third command stream to the second electronic device.
  • the second electronic device may display the second content on the display screen according to the third instruction stream.
  • the above-mentioned first data may be a first video stream.
  • the first electronic device may further include an image conversion module and a first storage module.
  • the above-mentioned first storage module may be a storage area in the above-mentioned storage module.
  • the instruction interception module obtains the above-mentioned third instruction stream
  • the third instruction stream can be transmitted from the instruction interception module to the image conversion module.
  • the image conversion module may pass the third instruction stream to the GPU driver.
  • the image conversion module may also transmit the storage path of the first storage module to the GPU driver.
  • the GPU driver can convert the third instruction stream into a program executable by the GPU, and drive the GPU to execute the executable program converted from the third instruction stream.
  • the GPU may obtain image data of the second content, and store the image data of the second content in the first storage module.
  • the image conversion module can be configured to convert the image data of the second content into a first video stream, and deliver the first video stream to the screen projection module.
  • the screen projection module can send the first video stream to the second electronic device.
  • the second electronic device may display the second content on the display screen according to the first video stream.
  • the present application provides a display system.
  • the display system may include a first electronic device and a second electronic device.
  • the first electronic device and the second electronic device are communicatively connected.
  • the first electronic device can be used to run a first application and display a first user interface, where the first user interface includes first content and second content, wherein the second content is displayed overlying part of the first content, and the first user interface is connected to the first user interface. related to an application.
  • the first electronic device is further configured to display a second user interface in response to the first operation, the second user interface includes the first content, and the part of the first content covered by the second content is presented on the second user interface.
  • the first electronic device can also be used to send the first data to the second electronic device.
  • the second electronic device may be configured to display a third user interface according to the first data, the third user interface including the second content.
  • the second user interface further includes third content, the third content is displayed overlying part of the first content, and the third content has transparency.
  • the size and position of the display area of the third content are respectively the same as the size and position of the display area of the second content.
  • the second user interface may include the first content but not the second content.
  • the first electronic device may be configured to, in response to the first operation, generate a second instruction stream and a third instruction stream according to the first instruction stream, where the first instruction stream is related to the first application; and display a second user interface according to the second instruction stream; According to the third instruction stream, the first data is determined.
  • the second user interface may include the first content and the third content.
  • the first electronic device may be configured to, in response to the first operation, generate a second instruction stream and a third instruction stream according to the first instruction stream, where the first instruction stream is related to the first application; and generate a fourth instruction stream according to the third instruction stream; According to the second instruction stream and the fourth instruction stream, a fifth instruction stream is generated; according to the fifth instruction stream, a second user interface is displayed, and the second user interface includes the first content and the third content; a data.
  • the first data may be a third instruction stream.
  • the first data may be a first video stream, the first video stream is obtained according to the image data including the second content, and the image data including the second content is obtained according to the third instruction stream.
  • the first electronic device may be configured to receive a second operation acting on a first area of the second user interface, where the first area is the part of the first content covered by the second content that is presented in the first area. Two areas of the user interface; executing instructions responsive to the second operation.
  • the present application also provides an electronic device.
  • the electronic device may include a display screen, a communication module, a memory, and a processor, wherein the memory may be used to store a computer program, and the processor may be used to invoke the computer program, so that the electronic device performs any possible implementation manner of the first aspect.
  • the present application provides a chip, the chip is applied to a device, the chip includes one or more processors, and the processor is used for invoking computer instructions to cause the device to execute any of the possible implementations in the first aspect Way.
  • the present application provides a computer program product containing instructions, characterized in that, when the computer program product is executed on a device, the device causes the device to execute any of the possible implementations in the first aspect.
  • the present application provides a computer-readable storage medium, comprising instructions, characterized in that, when the above-mentioned instructions are executed on a device, the above-mentioned device is caused to execute any possible implementation manner of the first aspect.
  • the display system provided in the third aspect, the electronic device provided in the fourth aspect, the chip provided in the fifth aspect, the computer program product provided in the sixth aspect, and the computer-readable storage medium provided in the seventh aspect are all used for Execute the methods provided in the embodiments of the present application. Therefore, for the beneficial effects that can be achieved, reference may be made to the beneficial effects in the corresponding method, which will not be repeated here.
  • FIG. 1 is a schematic diagram of a game interface provided by an embodiment of the present application.
  • FIG. 2 is a schematic structural diagram of an electronic device 100 provided by an embodiment of the present application.
  • FIG. 3 is a schematic structural diagram of another electronic device 100 provided by an embodiment of the present application.
  • FIG. 4 is a schematic diagram of a screen projection system provided by an embodiment of the present application.
  • 5A to 5D are schematic diagrams of scenarios in which a game application is associated with application A according to an embodiment of the present application;
  • 6A to 6F are schematic diagrams of screen projection scenarios of some electronic devices 100 provided by embodiments of the present application.
  • FIGS. 7A and 7B are schematic diagrams of screen projection scenarios of other electronic devices 100 provided by embodiments of the present application.
  • 8A and 8B are schematic diagrams of scenarios in which some electronic devices 100 end screen projection provided by embodiments of the present application.
  • FIG. 9 is a schematic structural diagram of a screen projection system provided by an embodiment of the present application.
  • FIG. 10 is a schematic structural diagram of another screen projection system provided by an embodiment of the present application.
  • FIG. 11 is a flowchart of a display method provided by an embodiment of the present application.
  • first and second are only used for descriptive purposes, and should not be construed as implying or implying relative importance or implying the number of indicated technical features. Therefore, the features defined as “first” and “second” may explicitly or implicitly include one or more of the features. In the description of the embodiments of the present application, unless otherwise specified, the “multiple” The meaning is two or more.
  • FIG. 1 exemplarily shows a schematic diagram of a game interface of an electronic game.
  • the electronic device 100 can run a game application and display a game interface 210 .
  • the game interface 210 may include a game scene area 210A and a map area 210B. in:
  • the content displayed in the game scene area 210A may occupy the game interface 210 .
  • the game scene area 210A may be used to display in-game environment, buildings, player characters, non-player characters, operational controls for controlling the player characters, and the like.
  • the map area 210B may be used to display the in-game map.
  • the map area 210B may include location markers for the player character, location markers for some special locations, and the like.
  • the embodiment of the present application does not limit the content displayed in the game scene area 210A and the map area 210B.
  • the map area 210B may cover the game scene area 210A. That is, the map area 210B will block a part of the content presented in the game scene area 210A. The shaded portion of the game scene area 210A cannot be seen by the user. The user's view of the game scene is obstructed. If the content presented in the game scene area 210A is not blocked by the above-mentioned map area 210B, the user's game experience will be better.
  • the embodiment of the present application provides a display method.
  • the method can project a part of the display content in the user interface of the electronic device 100 to the electronic device 200 .
  • the electronic device 200 may display a part of the above-mentioned projected display content.
  • the electronic device 100 may run the application A and display the user interface A of the application A.
  • the user interface A may include a first display content and a second display content.
  • the electronic device 100 may intercept the graphic instruction stream of the first display content from the graphic instruction stream of the above-mentioned user interface A according to the target instruction library. According to the graphic instruction stream of the above-mentioned first display content, the electronic device 200 may display the above-mentioned first display content.
  • the electronic device 100 can display other parts of the graphic instruction stream (such as the graphic instruction stream of the second display content) in the graphic instruction stream of the above-mentioned user interface A, and display the contents other than the first display content of A in the user interface. content.
  • the above-mentioned first display content and the above-mentioned second display content can be independently displayed.
  • the rendering thread for rendering the first display content by the electronic device 100 in the user interface A and the rendering thread for rendering the second display content are different.
  • the electronic device 100 may execute a rendering thread for rendering the first display content and a rendering thread for rendering the second display content in parallel, so as to simultaneously display the first display content and the second display content in the user interface.
  • a thread can represent a single sequential flow of control in a process.
  • the process is a program already running in the electronic device.
  • a process can have multiple threads in parallel, and each thread executes different tasks in parallel.
  • the above-mentioned different rendering threads may perform tasks of rendering different contents (eg, rendering the first display content and rendering the second display content).
  • the above-mentioned first display content may be overlaid on the second display content, and partially block the second display content.
  • the graphic instruction stream of the user interface A may include a graphic instruction stream for drawing the content that is blocked by the first display content in the second display content. If the electronic device 100 removes the first display content in the user interface A, the user interface A may display the content that is blocked by the first display content in the second display content.
  • the above-mentioned target instruction library may include drawing instructions for drawing the first display content (eg, a function for drawing graphics and parameters in the function).
  • the target instruction library may be pre-stored by the electronic device 100 or acquired from a cloud server. This embodiment of the present application does not limit the method for the electronic device 100 to acquire the target instruction library.
  • the above-mentioned first display content may be the content drawn according to the drawing instructions in the above-mentioned target instruction library.
  • the electronic device 100 intercepts the graphic instruction stream of the first display content from the graphic instruction stream of the user interface A according to the target instruction library.
  • the instruction matches the instruction, and the interception operation is performed to obtain the graphic instruction stream of the first display content.
  • the graphic instruction stream of the above-mentioned user interface may include one or more instructions for drawing the above-mentioned user interface.
  • the electronic device 100 can hand over part of the display content of a user interface in an application to the electronic device 200 for display, so as to realize screen projection in the application.
  • the above display method can reduce the situation that the first display content blocks the second display content in a user interface. Users can get a better experience when using the above applications.
  • the above-mentioned applications may be game applications, live broadcast applications, video call applications, and the like.
  • the embodiments of the present application do not limit the types of applications in the above screen projection process.
  • a game application is used as an example to introduce the display method provided by the embodiment of the present application.
  • the content displayed in the game scene area 210A shown in FIG. 1 is the above-mentioned second display content.
  • the content displayed in the map area 210B shown in FIG. 1 is the above-mentioned first display content.
  • the graphics instruction stream of the game interface 210 may include a map instruction stream and a game scene instruction stream.
  • the graphics instruction stream used to draw the game interface 210 may be obtained from a game engine.
  • the map instruction stream includes instructions for drawing the content displayed in the map area 210B.
  • the game scene instruction stream includes instructions for drawing the content displayed in the game scene area 210A.
  • the image drawn according to the game scene instruction stream may include content in the game scene area 210A that is occluded by the map area 210B.
  • the electronic device 100 may intercept the map instruction stream from the graphics instruction stream of the game interface 210 according to the target instruction library. When the map instruction stream is intercepted, the electronic device 100 may perform rendering according to the map instruction stream to obtain an image of the map area 210B. Further, the electronic device 100 may encode the image of the above-mentioned map area 210B into a video stream, and send the video stream to the electronic device 200. The electronic device 200 can display the video stream. That is, the content presented in the map area 210B may be displayed on the electronic device 200 . In addition, the electronic device 100 can locally display the content in the game scene area 210A according to the instruction stream remaining after the interception operation, such as the game scene instruction stream.
  • the electronic device 100 can display the content in the game scene area 210A.
  • the electronic device 200 may display the content in the map area 210B.
  • the map area 210B no longer blocks the content in the game scene area 210A. Users can get a larger field of view during the game.
  • the electronic device 100 may intercept the map instruction stream from the graphics instruction stream of the game interface 210 according to the target instruction library, and send the map instruction stream to the electronic device 200 .
  • the electronic device 200 may execute the instructions included in the map instruction stream to display the content in the map area 210B.
  • the electronic device 100 can locally display the content in the game scene area 210A according to the instruction stream remaining after the interception operation, such as the game scene instruction stream. In this way, the electronic device 100 can display the content in the game scene area 210A.
  • the electronic device 200 may display the content in the map area 210B.
  • the map area 210B no longer blocks the content in the game scene area 210A. Users can get a larger field of view during the game.
  • application A may be installed in the electronic device 100 .
  • the application A may be, for example, an application assistant application, a game assistant application, or the like.
  • the auxiliary services that application A can use to provide applications associated with it include but are not limited to: message do not disturb, screen capture, screen recording, and game acceleration.
  • the electronic device 100 may associate application A with the above-mentioned game application. Through the above application A, the electronic device 100 can acquire the above target instruction library. In response to a user operation of projecting the content of the map area 210B to the electronic device 200, the electronic device 100 can use the display method provided by the embodiment of the present application to display the content of the map area 210B by the electronic device 200 according to the target instruction library.
  • the process of associating the application A with the game application by the electronic device 100 will be introduced in subsequent embodiments, and will not be described here.
  • the electronic device 100 can implement the above-mentioned display method by means of the application A. That is, applications that need to be screened do not need to be modified. Then, if the developer of the third-party application does not make adaptive modifications to the application, the electronic device 100 can project part of the display content on one user interface of these third-party applications to other devices. This is beneficial for the display method provided by the present application to be suitable for various types of applications such as game applications, live broadcast applications, and video call applications.
  • the electronic device 100 may be a mobile phone, a tablet computer, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), or the like, which has a display screen.
  • UMPC ultra-mobile personal computer
  • PDA personal digital assistant
  • FIG. 2 exemplarily shows a schematic structural diagram of an electronic device 100 provided by an embodiment of the present application.
  • the electronic device 100 may include a processor 110 , an external memory interface 120 , an internal memory 121 , a universal serial bus (USB) interface 130 , a charge management module 140 , a power management module 141 , and a battery 142 , Antenna 1, Antenna 2, Mobile Communication Module 150, Wireless Communication Module 160, Audio Module 170, Speaker 170A, Receiver 170B, Microphone 170C, Headphone Interface 170D, Sensor Module 180, Key 190, Motor 191, Indicator 192, Camera 193 , a display screen 194, and a subscriber identification module (subscriber identification module, SIM) card interface 195 and the like.
  • a processor 110 an external memory interface 120 , an internal memory 121 , a universal serial bus (USB) interface 130 , a charge management module 140 , a power management module 141 , and a battery 142 , Antenna 1, Antenna 2, Mobile Communication Module 150, Wireless Communication Module 160, Audio Module 170, Speaker 170A, Receive
  • the sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, and ambient light. Sensor 180L, bone conduction sensor 180M, etc.
  • the structures illustrated in the embodiments of the present application do not constitute a specific limitation on the electronic device 100 .
  • the electronic device 100 may include more or less components than shown, or combine some components, or separate some components, or arrange different components.
  • the illustrated components may be implemented in hardware, software, or a combination of software and hardware.
  • the processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), controller, memory, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural-network processing unit (NPU) Wait. Wherein, different processing units may be independent devices, or may be integrated in one or more processors.
  • application processor application processor, AP
  • modem processor graphics processor
  • graphics processor graphics processor
  • ISP image signal processor
  • controller memory
  • video codec digital signal processor
  • DSP digital signal processor
  • NPU neural-network processing unit
  • a memory may also be provided in the processor 110 for storing instructions and data.
  • the memory in processor 110 is cache memory. This memory may hold instructions or data that have just been used or recycled by the processor 110 . If the processor 110 needs to use the instruction or data again, it can be called directly from the memory. Repeated accesses are avoided and the latency of the processor 110 is reduced, thereby increasing the efficiency of the system.
  • the USB interface 130 is an interface that conforms to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, and the like.
  • the USB interface 130 can be used to connect a charger to charge the electronic device 100, and can also be used to transmit data between the electronic device 100 and peripheral devices. It can also be used to connect headphones to play audio through the headphones.
  • the interface can also be used to connect other electronic devices, such as AR devices.
  • the charging management module 140 is used to receive charging input from the charger.
  • the charger may be a wireless charger or a wired charger. While the charging management module 140 charges the battery 142 , it can also supply power to the electronic device through the power management module 141 .
  • the power management module 141 is used for connecting the battery 142 , the charging management module 140 and the processor 110 .
  • the power management module 141 receives input from the battery 142 and/or the charging management module 140, and supplies power to the processor 110, the internal memory 121, the external memory, the display screen 194, the camera 193, and the wireless communication module 160.
  • the wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modulation and demodulation processor, the baseband processor, and the like.
  • Antenna 1 and Antenna 2 are used to transmit and receive electromagnetic wave signals.
  • Each antenna in electronic device 100 may be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve antenna utilization.
  • the mobile communication module 150 may provide wireless communication solutions including 2G/3G/4G/5G etc. applied on the electronic device 100 .
  • the mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA) and the like.
  • the mobile communication module 150 can receive electromagnetic waves from the antenna 1, filter and amplify the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation.
  • the mobile communication module 150 can also amplify the signal modulated by the modulation and demodulation processor, and then turn it into an electromagnetic wave for radiation through the antenna 1 .
  • at least part of the functional modules of the mobile communication module 150 may be provided in the processor 110 .
  • at least part of the functional modules of the mobile communication module 150 may be provided in the same device as at least part of the modules of the processor 110 .
  • the modem processor may include a modulator and a demodulator.
  • the modulator is used to modulate the low frequency baseband signal to be sent into a medium and high frequency signal.
  • the demodulator is used to demodulate the received electromagnetic wave signal into a low frequency baseband signal. Then the demodulator transmits the demodulated low-frequency baseband signal to the baseband processor for processing.
  • the low frequency baseband signal is processed by the baseband processor and passed to the application processor.
  • the application processor outputs sound signals through audio devices (not limited to the speaker 170A, the receiver 170B, etc.), or displays images or videos through the display screen 194 .
  • the modem processor may be a stand-alone device.
  • the modem processor may be independent of the processor 110, and may be provided in the same device as the mobile communication module 150 or other functional modules.
  • the wireless communication module 160 can provide applications on the electronic device 100 including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellites Wireless communication solutions such as global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared technology (IR).
  • WLAN wireless local area networks
  • BT Bluetooth
  • GNSS global navigation satellite system
  • FM frequency modulation
  • NFC near field communication
  • IR infrared technology
  • the wireless communication module 160 may be one or more devices integrating at least one communication processing module.
  • the wireless communication module 160 receives electromagnetic waves via the antenna 2 , frequency modulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 110 .
  • the wireless communication module 160 can also receive the signal to be sent from the processor 110 , perform frequency modulation on it, amplify it, and convert it into electromagnetic waves for radiation through the antenna 2 .
  • the electronic device 100 implements a display function through a GPU, a display screen 194, an application processor, and the like.
  • the GPU is a microprocessor for image processing, and is connected to the display screen 194 and the application processor.
  • the GPU is used to perform mathematical and geometric calculations for graphics rendering.
  • Processor 110 may include one or more GPUs that execute program instructions to generate or alter display information.
  • Display screen 194 is used to display images, videos, and the like.
  • Display screen 194 includes a display panel.
  • the display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (active-matrix organic light).
  • LED diode AMOLED
  • flexible light-emitting diode flexible light-emitting diode (flex light-emitting diode, FLED), Miniled, MicroLed, Micro-oLed, quantum dot light-emitting diode (quantum dot light emitting diodes, QLED) and so on.
  • the electronic device 100 may include one or N display screens 194 , where N is a positive integer greater than one.
  • the electronic device 100 may implement a shooting function through an ISP, a camera 193, a video codec, a GPU, a display screen 194, an application processor, and the like.
  • the ISP is used to process the data fed back by the camera 193 .
  • the shutter is opened, the light is transmitted to the camera photosensitive element through the lens, the light signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing, and converts it into an image visible to the naked eye.
  • ISP can also perform algorithm optimization on image noise, brightness, and skin tone.
  • ISP can also optimize the exposure, color temperature and other parameters of the shooting scene.
  • the ISP may be provided in the camera 193 .
  • Camera 193 is used to capture still images or video.
  • the object is projected through the lens to generate an optical image onto the photosensitive element.
  • the photosensitive element may be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor.
  • CMOS complementary metal-oxide-semiconductor
  • the photosensitive element converts the optical signal into an electrical signal, and then transmits the electrical signal to the ISP to convert it into a digital image signal.
  • the ISP outputs the digital image signal to the DSP for processing.
  • DSP converts digital image signals into standard RGB, YUV and other formats of image signals.
  • the electronic device 100 may include 1 or N cameras 193 , where N is a positive integer greater than 1.
  • a digital signal processor is used to process digital signals, in addition to processing digital image signals, it can also process other digital signals. For example, when the electronic device 100 selects a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy and so on.
  • Video codecs are used to compress or decompress digital video.
  • the electronic device 100 may support one or more video codecs.
  • the electronic device 100 can play or record videos of various encoding formats, such as: Moving Picture Experts Group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, MPEG4 and so on.
  • MPEG Moving Picture Experts Group
  • MPEG2 moving picture experts group
  • MPEG3 MPEG4
  • MPEG4 Moving Picture Experts Group
  • the NPU is a neural-network (NN) computing processor.
  • NN neural-network
  • Applications such as intelligent cognition of the electronic device 100 can be implemented through the NPU, such as image recognition, face recognition, speech recognition, text understanding, and the like.
  • the external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100 .
  • the external memory card communicates with the processor 110 through the external memory interface 120 to realize the data storage function. For example to save files like music, video etc in external memory card.
  • Internal memory 121 may be used to store computer executable program code, which includes instructions.
  • the processor 110 executes various functional applications and data processing of the electronic device 100 by executing the instructions stored in the internal memory 121 .
  • the internal memory 121 may include a storage program area and a storage data area.
  • the storage program area can store an operating system, an application program required for at least one function (such as a sound playback function, an image playback function, etc.), and the like.
  • the storage data area may store data (such as audio data, phone book, etc.) created during the use of the electronic device 100 and the like.
  • the internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, universal flash storage (UFS), and the like.
  • the electronic device 100 may implement audio functions through an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, an application processor, and the like. Such as music playback, recording, etc.
  • the audio module 170 is used for converting digital audio information into analog audio signal output, and also for converting analog audio input into digital audio signal. Audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be provided in the processor 110 , or some functional modules of the audio module 170 may be provided in the processor 110 .
  • Speaker 170A also referred to as a "speaker" is used to convert audio electrical signals into sound signals.
  • the electronic device 100 can listen to music through the speaker 170A, or listen to a hands-free call.
  • the receiver 170B also referred to as "earpiece" is used to convert audio electrical signals into sound signals.
  • the voice can be answered by placing the receiver 170B close to the human ear.
  • the microphone 170C also called “microphone” or “microphone” is used to convert sound signals into electrical signals.
  • the user can make a sound by approaching the microphone 170C through a human mouth, and input the sound signal into the microphone 170C.
  • the electronic device 100 may be provided with at least one microphone 170C. In other embodiments, the electronic device 100 may be provided with two microphones 170C, which can implement a noise reduction function in addition to collecting sound signals. In other embodiments, the electronic device 100 may further be provided with three, four or more microphones 170C to collect sound signals, reduce noise, identify sound sources, and implement directional recording functions.
  • the earphone jack 170D is used to connect wired earphones.
  • the earphone interface 170D may be the USB interface 130, or may be a 3.5mm open mobile terminal platform (OMTP) standard interface, a cellular telecommunications industry association of the USA (CTIA) standard interface.
  • OMTP open mobile terminal platform
  • CTIA cellular telecommunications industry association of the USA
  • the pressure sensor 180A is used to sense pressure signals, and can convert the pressure signals into electrical signals.
  • the pressure sensor 180A may be provided on the display screen 194 .
  • the capacitive pressure sensor may be comprised of at least two parallel plates of conductive material. When a force is applied to the pressure sensor 180A, the capacitance between the electrodes changes.
  • the electronic device 100 determines the intensity of the pressure according to the change in capacitance. When a touch operation acts on the display screen 194, the electronic device 100 detects the intensity of the touch operation according to the pressure sensor 180A.
  • the electronic device 100 may also calculate the touched position according to the detection signal of the pressure sensor 180A.
  • touch operations acting on the same touch position but with different touch operation intensities may correspond to different operation instructions. For example, when a touch operation whose intensity is less than the first pressure threshold acts on the short message application icon, the instruction for viewing the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold acts on the short message application icon, the instruction to create a new short message is executed.
  • the gyro sensor 180B may be used to determine the motion attitude of the electronic device 100 .
  • the air pressure sensor 180C is used to measure air pressure.
  • the magnetic sensor 180D includes a Hall sensor.
  • the electronic device 100 can detect the opening and closing of the flip holster using the magnetic sensor 180D.
  • the electronic device 100 can detect the opening and closing of the flip according to the magnetic sensor 180D. Further, according to the detected opening and closing state of the leather case or the opening and closing state of the flip cover, characteristics such as automatic unlocking of the flip cover are set.
  • the acceleration sensor 180E can detect the magnitude of the acceleration of the electronic device 100 in various directions (generally three axes).
  • the magnitude and direction of gravity can be detected when the electronic device 100 is stationary. It can also be used to identify the posture of electronic devices, and can be used in applications such as horizontal and vertical screen switching, pedometers, etc.
  • the electronic device 100 can measure the distance through infrared or laser. In some embodiments, when shooting a scene, the electronic device 100 can use the distance sensor 180F to measure the distance to achieve fast focusing.
  • Proximity light sensor 180G may include, for example, light emitting diodes (LEDs) and light detectors, such as photodiodes.
  • the light emitting diodes may be infrared light emitting diodes.
  • the electronic device 100 emits infrared light to the outside through the light emitting diode.
  • Electronic device 100 uses photodiodes to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 100 . When insufficient reflected light is detected, the electronic device 100 may determine that there is no object near the electronic device 100 .
  • the electronic device 100 can use the proximity light sensor 180G to detect that the user holds the electronic device 100 close to the ear to talk, so as to automatically turn off the screen to save power.
  • Proximity light sensor 180G can also be used in holster mode, pocket mode automatically unlocks and locks the screen.
  • the ambient light sensor 180L is used to sense ambient light brightness.
  • the electronic device 100 can adaptively adjust the brightness of the display screen 194 according to the perceived ambient light brightness.
  • the ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures.
  • the ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in a pocket, so as to prevent accidental touch.
  • the fingerprint sensor 180H is used to collect fingerprints.
  • the electronic device 100 can use the collected fingerprint characteristics to realize fingerprint unlocking, accessing application locks, taking pictures with fingerprints, answering incoming calls with fingerprints, and the like.
  • the temperature sensor 180J is used to detect the temperature.
  • Touch sensor 180K also called “touch panel”.
  • the touch sensor 180K may be disposed on the display screen 194 , and the touch sensor 180K and the display screen 194 form a touch screen, also called a “touch screen”.
  • the touch sensor 180K is used to detect a touch operation on or near it.
  • the touch sensor can pass the detected touch operation to the application processor to determine the type of touch event.
  • Visual output related to touch operations may be provided through display screen 194 .
  • the touch sensor 180K may also be disposed on the surface of the electronic device 100 , which is different from the location where the display screen 194 is located.
  • the bone conduction sensor 180M can acquire vibration signals.
  • the keys 190 include a power-on key, a volume key, and the like. Keys 190 may be mechanical keys. It can also be a touch key.
  • the electronic device 100 may receive key inputs and generate key signal inputs related to user settings and function control of the electronic device 100 .
  • Motor 191 can generate vibrating cues.
  • the motor 191 can be used for vibrating alerts for incoming calls, and can also be used for touch vibration feedback.
  • the indicator 192 can be an indicator light, which can be used to indicate the charging state, the change of the power, and can also be used to indicate a message, a missed call, a notification, and the like.
  • the SIM card interface 195 is used to connect a SIM card.
  • the SIM card can be contacted and separated from the electronic device 100 by inserting into the SIM card interface 195 or pulling out from the SIM card interface 195 .
  • the electronic device 100 may support 1 or N SIM card interfaces, where N is a positive integer greater than 1.
  • the SIM card interface 195 can support Nano SIM card, Micro SIM card, SIM card and so on. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the plurality of cards may be the same or different.
  • the SIM card interface 195 can also be compatible with different types of SIM cards.
  • the SIM card interface 195 is also compatible with external memory cards.
  • the electronic device 100 interacts with the network through the SIM card to implement functions such as call and data communication.
  • the electronic device 100 employs an eSIM, ie: an embedded SIM card.
  • the eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100 .
  • the electronic device 200 may be a mobile phone, a tablet computer, a notebook computer, a TV, a smart screen, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), etc., a device with a display screen .
  • UMPC ultra-mobile personal computer
  • PDA personal digital assistant
  • the embodiment of the present application does not limit the specific type of the electronic device 200 .
  • the software system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture.
  • the embodiments of the present application take an Android system with a layered architecture as an example to exemplarily describe the software structure of the electronic device 100 .
  • FIG. 3 exemplarily shows another schematic structural diagram of the electronic device 100 provided by the embodiment of the present application.
  • the electronic device 100 may have a software structure and hardware devices as shown in FIG. 3 .
  • the layered architecture divides the software into several layers, and each layer has a clear role and division of labor. Layers communicate with each other through software interfaces.
  • the Android system can be divided into four layers, which are, from top to bottom, an application layer, an application framework layer, an Android runtime (Android runtime) and system libraries, and a kernel layer.
  • the application layer can include a series of application packages.
  • the application package may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, video, game A, application A and so on.
  • the electronic device 100 can display the user interface shown in FIG. 1 when running the game A application.
  • Application A can provide corresponding auxiliary services for other applications (such as game A application). For example, during the running of an application associated with application A, the user can quickly enable services such as message do not disturb, game acceleration, and map projection through application A.
  • the application framework layer provides an application programming interface (application programming interface, API) and a programming framework for applications in the application layer.
  • the application framework layer includes some predefined functions.
  • the application framework layer may include a window manager, a content provider, a telephony manager, a resource manager, a notification manager, a view system, a game A game engine, and the like.
  • a window manager can be used to manage window programs.
  • the window manager can get the size of the display screen, determine whether there is a status bar, lock the screen, take screenshots, etc.
  • Content providers can be used to store and retrieve data, and make this data accessible to applications.
  • the data may include video, images, audio, calls made and received, browsing history and bookmarks, phone book, etc.
  • the view system may include visual controls, such as controls for displaying text, controls for displaying pictures, and the like. View systems can be used to build applications.
  • a display interface can consist of one or more views.
  • the display interface including the short message notification icon may include a view for displaying text and a view for displaying pictures.
  • the telephony manager may be used to provide communication functions of the electronic device 100 .
  • the management of call status including connecting, hanging up, etc.).
  • the resource manager can provide various resources for the application, such as localization strings, icons, pictures, layout files, video files and so on.
  • the notification manager enables applications to display notification information in the status bar, which can be used to convey notification-type messages, and can disappear automatically after a brief pause without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc.
  • the notification manager can also display notifications in the status bar at the top of the system in the form of graphs or scroll bar text, such as notifications of applications running in the background, and notifications on the screen in the form of dialog windows. For example, text information is prompted in the status bar, a prompt sound is issued, the electronic device vibrates, and the indicator light flashes.
  • the Game A game engine may be used to implement the rendering of the user interface of the Game A application.
  • the game engine of Game A can obtain parameters for drawing the user interface of the application of Game A, and call the 3D graphics processing library in the system library to realize the rendering of the user interface.
  • Game A The game engine can also be used to process the communication between the player and the electronic device 100 , such as signals from components such as a display screen, a keyboard, a mouse, and the like. That is, when the user operates the game A application program, the game A game engine can execute relevant instructions, so that the electronic device 100 can give feedback corresponding to the user's operation.
  • Android Runtime includes core libraries and a virtual machine. Android runtime is responsible for scheduling and management of the Android system.
  • the core library consists of two parts: one is the function functions that the java language needs to call, and the other is the core library of Android.
  • the application layer and the application framework layer run in virtual machines.
  • the virtual machine executes the java files of the application layer and the application framework layer as binary files.
  • the virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, safety and exception management, and garbage collection.
  • a system library can include multiple functional modules. For example: surface manager (surface manager), media library (Media Libraries), three-dimensional (3dimension, 3D) graphics processing library, two-dimensional (2dimension, 2D) graphics engine, etc.
  • the Surface Manager can be used to manage the display subsystem and provides a fusion of 2D and 3D layers for multiple applications.
  • the media library supports playback and recording of a variety of commonly used audio and video formats, as well as still image files.
  • the media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, H.265, MP3, AMR, JPG, PNG, etc.
  • the 3D graphics processing library can be used to implement 3D graphics drawing, image rendering, compositing, and layer processing.
  • 3D graphics processing libraries can include OpenGL, OpenGL ES, OpenCV, Vulkan, and more.
  • a 2D graphics engine is a drawing engine for two-dimensional drawing.
  • the 2D graphics engine may be, for example, SGL or the like.
  • the kernel layer is the layer between hardware devices and software.
  • the kernel layer contains at least display drivers, camera drivers, GPU drivers, audio drivers, and sensor drivers.
  • the electronic device 100 may implement corresponding functions by driving the hardware device at the kernel layer.
  • the above-mentioned GPU driver may include instructions executed by a central processing unit (central processing unit, CPU) to make the GPU work. That is, the CPU can execute the instructions in the GPU driver, so that the GPU can perform mathematical and geometric calculations.
  • the display screen can display images according to the calculation results of the GPU.
  • the hardware devices of the electronic device 100 may include a display screen, a camera, a sensor, and the like.
  • a display screen For specific hardware devices of the electronic device 100, reference may be made to the description of FIG. 2 above.
  • the workflow of the software and hardware device of the electronic device 100 is exemplarily described below with reference to the scenario where the game interface of the game A application is displayed on the display screen.
  • the corresponding hardware terminal is sent to the kernel layer.
  • the kernel layer processes touch operations into raw input events (including touch coordinates, timestamps of touch operations, etc.).
  • Raw input events are stored at the kernel layer.
  • the application framework layer obtains the original input event from the kernel layer, and identifies the control corresponding to the input event. Taking the touch operation as a touch click operation, and the control corresponding to the click operation is the control of the game A application icon, for example, the game A application can call the interface of the application framework layer, such as the game A game engine.
  • the game engine of Game A can obtain the parameters used to draw the game interface in the application of Game A, and call the 3D graphics processing library (such as OpenGL ES) in the system library, thereby obtaining the graphics instruction stream used to draw the game interface.
  • OpenGL ES is an application programming interface (application programming interface, API).
  • OpenGL ES includes a variety of functional functions/application programming interfaces.
  • Game A's game engine calling OpenGL ES can specifically indicate that Game A's game engine assigns the parameters in the instruction.
  • the parameters in the above instructions can be parameters used to draw the game interface. For example, the size of the map area 210B shown in FIG. 1, the size of the building, the size of the player character, and the like. The values of these parameters can be obtained by the game engine from the local game A application package or from the game server.
  • the electronic device 100 may transmit the graphics instruction stream for drawing the game interface to the GPU driver.
  • the GPU driver can convert the instructions in the above-mentioned graphics instruction stream into a low-level program, and drive the GPU to execute the above-mentioned low-level program.
  • the above-mentioned underlying program is a program (eg, machine code) executable by the GPU.
  • the GPU executes the above-mentioned underlying program, and can obtain the image data of the game interface.
  • the GPU can be connected to the display and pass the graphics data of the game interface to the display.
  • the display screen can display the game interface of the game A application.
  • FIG. 4 exemplarily shows a screen projection system provided by an embodiment of the present application.
  • the screen projection system may include an electronic device 100 and an electronic device 200 .
  • a communication connection is established between the electronic device 100 and the electronic device 200 .
  • the electronic device 100 can send the content that needs to be projected to the electronic device 200 .
  • the electronic device 100 and the electronic device 200 may be in the same local area network (eg, the same home Wi-Fi).
  • the electronic device 100 may search for electronic devices that are in the same local area network as itself.
  • the electronic device 100 may establish the above-mentioned communication connection with the electronic device 200 .
  • the electronic device 200 may display the content from the electronic device 100 that needs to be projected.
  • the embodiments of the present application do not limit the method for establishing a communication connection between the electronic device 100 and the electronic device 200 .
  • the screen-casting protocol in the prior art may be used between the electronic device 100 and the electronic device 200 .
  • the protocol used when transmitting the content that needs to be screened may also be a private protocol agreed between the electronic device 100 and the electronic device 200 .
  • This embodiment of the present application does not limit the screen projection protocol adopted for data transmission between the electronic device 100 and the electronic device 200 .
  • the following takes the game application as an example to describe the process of associating the game application with the application A.
  • 5A to 5D exemplarily show schematic diagrams of scenarios in which a game application is associated with application A. As shown in FIG.
  • the electronic device 100 may display a user interface 410 .
  • User interface 410 displays a page with application icons placed, which may include multiple application icons (eg, video call application A icon, live broadcast application A icon, WeChat application sports health application icon, game B application icon, game C application icon, game A application icon 412, application A icon 411, etc.).
  • a page indicator may also be displayed below the above-mentioned multiple application icons to indicate the positional relationship between the currently displayed page and other pages.
  • tray icons eg, camera application icon, contacts application icon, dialer application icon, message application icon. The tray icon remains displayed when switching pages. This embodiment of the present application does not limit the content displayed on the user interface 410 .
  • the electronic device 100 may launch the application A and display the user interface 420 as shown in FIG. 5B.
  • User interface 420 may include associated application display area 421 , add controls 422 , return controls 423 , and title bar 424 . in:
  • the return control 423 may be used to instruct the electronic device 100 to return to a previous user interface of the user interface 420 .
  • the electronic device 100 may exit the application A and display the user interface 410 as shown in FIG. 5A.
  • Title bar 424 may be used to indicate what the user interface 420 displays.
  • the presentation form of the title bar 424 may be text information "Application A", an icon or other forms.
  • the associated application display area 421 includes one or more application icons associated with application A.
  • application icons For example, WeChat application icon, game B application icon, game C application icon.
  • the above-mentioned applications that have been associated with application A are applications that have been installed by the electronic device 100 .
  • the icon of application A can be suspended and displayed on the user interface of this application, or displayed in the side application bar that can be called up and hidden.
  • the auxiliary service that the application A can provide can be quickly invoked.
  • the electronic device 100 can also provide the user with an entry for invoking the auxiliary services that the application A can provide in other forms.
  • auxiliary services may include but are not limited to the following services: message do not disturb, screen capture, screen recording, game acceleration, and map projection. in:
  • the message do not disturb can be used to not display message notifications of other applications (such as WeChat applications, messaging applications, dial-up applications, etc.) on the user interface of the application when the application that invokes this service is running.
  • the electronic device 100 can manage the message notification of each application through the notification manager, so that the message notification of each application is not displayed on the user interface.
  • Screenshots can be used to capture and save the user interface of the application as an image while the application calling this service is running.
  • the screen recording can be used to save the multi-frame images obtained from the start of the screen recording to the end of the screen recording as a video when the application that calls this service is running.
  • Game acceleration may be an auxiliary service provided by application A for game applications.
  • the electronic device 100 may adopt performance-biased system parameters when the game application runs. For example, allocating more computing resources and storage resources to game applications, using WLAN network and mobile data for network acceleration, etc., to improve game performance.
  • the map projection can also be an auxiliary service provided by application A for the game application.
  • the electronic device 100 installed with the application A stores a target instruction library corresponding to the game application.
  • the target instruction library may include instructions and parameters for drawing the map in the game application.
  • the electronic device 100 may acquire a target instruction library corresponding to the game application from a cloud server.
  • the electronic device 100 can use the display method provided by the embodiment of the present application to hand over the map in the game application to the electronic device 200 for display.
  • Application A can also provide in-app projection services for other types of applications (such as live broadcast applications, video call applications, etc.) by using the display method provided by the embodiments of this application .
  • the user interface may include an image display area of the own party and an image display area of the other party.
  • the own party and the other party are the two parties in the video call.
  • the above-mentioned image display area of the other party can be displayed on the user interface in the form of a small floating window, and covered on the image display area of the own party.
  • the electronic device 100 can use the display method provided by the embodiment of the present application to hand over the content of the image display area of the opposite party in the video call application to the electronic device 200 for display.
  • the content of the image display area of the other party is obtained according to the video stream collected by the camera of the video call device of the other party.
  • the electronic device 100 may also send the received video stream transmitted by the video call device of the opposite party to the electronic device 200 .
  • Add control 422 may be used to add applications associated with application A.
  • the electronic device 100 may display a user interface 430 as shown in FIG. 5C.
  • the user interface 430 may include a return control 433 , a title bar 434 , a game A application icon 431 , and an associated control 432 .
  • the return control 433 may be used to instruct the electronic device 100 to return to a previous user interface of the user interface 430 .
  • the electronic device 100 may display the user interface 420 as shown in FIG. 5B.
  • Title bar 434 may be used to indicate that the user interface is an interface for electronic device 100 to associate application A with other applications.
  • the presentation form of the title bar 434 may be textual information "Add", an icon or other forms.
  • the association control 432 can be used to associate the game A application with the application A.
  • the electronic device 100 may associate the game A application with the application A.
  • the associated application display area 421 in the user interface 420 shown in FIG. 5D includes the game A application icon. That is, the game A application has been associated with the application A.
  • the user interface 430 may also include more application icons that can be associated with application A and associated controls corresponding to these applications. For example, the icon of live broadcasting application A, the icon of video calling application A, the icon of music application, and the icon of sports health application.
  • the applications corresponding to these application icons are all applications already installed by the electronic device 100 .
  • FIG. 5A to FIG. 5D are only exemplary descriptions, and should not be construed to limit the present application.
  • the electronic device 100 may automatically associate a particular type of application with Application A.
  • the above-mentioned specific types of applications may be, for example, game applications, live broadcast applications, video call applications, and other types of applications.
  • the electronic device 100 can obtain the type of the application that it has installed.
  • an application's installation package contains an identifier for the type of application.
  • the electronic device 100 can filter out the above-mentioned specific type of application from the installed applications, and automatically associate the above-mentioned specific type of application with application A.
  • the embodiments of the present application do not limit the method for the electronic device to acquire the type of the application.
  • the electronic device 100 may automatically associate the above-mentioned installed specific type of application with application A.
  • the following describes the display method provided by the embodiment of the present application by taking the scene of the map in the screen-casting game A application as an example.
  • 6A to 6F exemplarily show schematic diagrams of scenarios in which the electronic device 100 projects the map of the game A application to the electronic device 200 .
  • the electronic device 100 may launch the game A application and display the game interface 510 as shown in FIG. 6B.
  • the game interface 510 may include a game scene area 510A and a map area 510B.
  • the game scene area 510A and the map area 510B may refer to the game scene area 210A and the map area 210B shown in FIG. 1 , respectively. I won't go into details here.
  • the electronic device 100 in response to a user operation of sliding inward on the left (or right) edge of the top of the screen of the electronic device 100 , the electronic device 100 can call up the side application bar 511 shown in FIG. 6C .
  • the side application bar 511 may include an application assistant shortcut key 511A.
  • the application assistant shortcut key 511A can be used by the user to quickly invoke the auxiliary service provided by the application A for the game A application.
  • the electronic device 100 may display the service display area 512 shown in FIG. 6D.
  • the service display area 512 may include one or more auxiliary service controls that the application A may provide for the game A application.
  • the message do not disturb control 512A, the screenshot control 512B, the screen recording control 512C, the game acceleration control 512D, the map projection control 512E, and the all service control 512F In response to user operations acting on these controls, the electronic device 100 may invoke services corresponding to these controls. For the services corresponding to these controls, reference may be made to the descriptions of the foregoing embodiments, which will not be repeated here.
  • the electronic device 100 may search for nearby electronic devices available for screen projection, and display the screen projection device option box 513 shown in FIG. 6E .
  • the above-mentioned electronic device that can be used for screen projection may be an electronic device that is in the same local area network as the electronic device 100 (eg, the same home Wi-Fi) and has a display screen. This embodiment of the present application does not limit the method for the electronic device 100 to search for nearby electronic devices that can be used for screen projection.
  • the screen projection device option box 513 may include a prompt 513A, a list of available devices 513B, and a device search control 513C. in:
  • the prompt 513A may be used to prompt the user about the role of the above-mentioned map projection service.
  • the prompt 513A can be the text message "Please select a screen projection device".
  • the embodiment of the present application does not limit the specific content of the prompt 513A.
  • the device search control 513C can be used to trigger the electronic device 100 to search for nearby electronic devices that can be used for screencasting.
  • the text prompt "Find More Devices" may be included on the device search control 513C. This embodiment of the present application does not limit the text prompt on the device search control 513 .
  • the available device list 513B can be used to display the electronic device options searched by the electronic device 100 that can be used for screencasting. For example, electronic device 200 option and electronic device 300 option.
  • the electronic device 100 may request to establish a communication connection with the electronic device 200
  • the electronic device 200 may establish a communication connection with the electronic device 100 .
  • the electronic device 100 may intercept the map instruction stream from the graphics instruction stream of the game interface 510 according to the target instruction library.
  • the electronic device 100 may locally display the game scene area 510A according to the command stream remaining after the command stream interception operation, for example, the game scene command stream.
  • the electronic device 100 may display the game scene area 510A on the game interface. It can be seen that the content of the game scene area 510A is not blocked by the above-mentioned map area 510B. Users can view content with a wider field of view during the game, and have a better game experience.
  • the electronic device 100 may send the above-mentioned map instruction stream to the electronic device 200 , or send the video stream obtained by rendering and encoding the above-mentioned map instruction stream to the electronic device 200 .
  • the electronic device 200 may display a user interface 530 as shown in FIG. 6F.
  • the map presented in the map area 510B shown in FIG. 6B may be included in the user interface 530 .
  • the electronic device 100 sends the above-mentioned map instruction stream to the electronic device 200 .
  • the electronic device 200 may scale the parameters in the above-mentioned map instruction stream according to the ratio of the screen resolution of the electronic device 100 and the screen resolution of the electronic device 200 . In this way, the size of the map in the map area 510B can be adapted to the size of the screen of the electronic device 200 .
  • the electronic device 100 renders the above-mentioned map instruction stream and sends the encoded video stream to the electronic device 200 .
  • the electronic device 200 may scale each frame image in the video stream according to the ratio of the screen resolution of the electronic device 100 to the screen resolution of the electronic device 200 . In this way, the size of the map in the map area 510B can be adapted to the size of the screen of the electronic device 200 .
  • the electronic device 100 may run application A and invoke auxiliary services (eg, map projection service) that application A may provide. That is, the user does not need to perform the user operation for invoking the map screen projection service as shown in FIG. 6B to FIG. 6D . This can simplify the user operation in the above-mentioned map projection process.
  • auxiliary services eg, map projection service
  • the content of the game scene area 510A in the game A application can be displayed on the electronic device 100 .
  • the content of the map area 510B in the game A application can be projected to the electronic device 200 and displayed by the electronic device 200 .
  • the user can perform game control on the electronic device 100 and view a map on the electronic device 200 during the process of playing the game A.
  • the visual field that the user can watch when performing game control on the electronic device 100 is no longer blocked by the map area 510B, and a better game experience can be obtained.
  • FIG. 7A and 7B exemplarily show another schematic diagram of user interfaces of the electronic device 100 and the electronic device 200 after screen projection.
  • the electronic device 100 may display the game interface 610 as shown in FIG. 7A .
  • the game interface 610 may include a game scene area 610A and a map identification area 610B.
  • the map identification area 610B can be used to identify the location where the map area 510B shown in FIG. 6A is located before the screen is projected.
  • the map identification area 610B may be overlaid on the game scene area 610A.
  • the size and location in the game interface 610 of the map identification area 610B may be the same as the size and location in the game interface 510 of the map area 510B in FIG. 6A .
  • the content in the map identification area 610B may be a solid color layer with a certain transparency as shown in FIG. 7A .
  • the above-mentioned solid color layer with certain transparency will not completely block the part of the game scene area 610A covered by the map identification area 610B.
  • the content in the map identification area 610B may be a frame of the same size as the map area 510B.
  • the above-mentioned instruction for drawing the content of the map identification area 610B may be obtained from a target instruction library. That is to say, in addition to including the map instruction stream for drawing the content of the map area 510B, the target instruction library also includes the map identification instruction stream for drawing the content of the map identification area 610B.
  • the electronic device 100 may intercept the above-mentioned map instruction stream from the graphics instruction stream used to draw the game interface 510 (ie, the game interface before the projection).
  • the electronic device 100 can locally display the game interface 610 shown in FIG. 7A according to the instruction stream remaining after the interception operation (eg, the game scene instruction stream) and the map identification instruction stream obtained from the target instruction library.
  • the instruction for drawing the content of the region identification area 610B may be generated by the electronic device 100 .
  • the electronic device 100 may generate the above-mentioned map identification instruction stream according to the map instruction stream.
  • map identification area 610B is the same size and location as map area 510B, respectively.
  • the values of the instructions and parameters in the map identification instruction stream may be determined by the values of the instructions and parameters in the map instruction stream.
  • This embodiment of the present application does not limit the specific form of the content displayed in the above-mentioned map identification area 610B.
  • the electronic device 100 may respond accordingly to a user operation acting on the map area 510B in the game interface 510 .
  • the electronic device 100 may adjust the map displayed in the map area 510B.
  • the map displayed in the map area 510B moves to the right.
  • the amount by which the map is moved to the right may be determined by the amount of right swipe in the above-mentioned user operation.
  • the map area 510B may display a map connected to the left edge of the map before the above-mentioned movement but not displayed. The portion of the map that moves right out of the map area 510B is hidden. That is, the user can slide in the map area 510B in various directions to adjust the map displayed in the map area 510B to view different areas of the map.
  • the electronic device 100 can respond correspondingly to the user operation acting on the map identification area 610B in the game interface 610 .
  • the electronic device 100 may acquire a map for drawing a map that can be displayed in the map area 510B shown in FIG. 6B after the map is moved to the right instruction flow.
  • the electronic device 200 may display the above-mentioned rightward-moved map on the user interface 610 .
  • the amount by which the map is moved to the right may be determined by the amount of right swipe in the above-mentioned user operation.
  • the map projected by the electronic device 100 to the electronic device 200 may refer to the map shown in FIG. 6F .
  • the map projected by the electronic device 100 to the electronic device 200 may refer to the map shown in FIG. 7B . Comparing FIG. 6F and FIG. 7B, it can be seen that after the above-mentioned movement, the user interface 620 can display a map connected to the left edge of the map in the user interface 530 but not displayed on the user interface 530. The map is moved to the right and the portion of the right edge of the map in the user interface 530 is hidden. Wherein, the amount of the map moving to the right may be determined by the amount of sliding to the right in the above-mentioned user operation.
  • the electronic device 100 may adjust the map that should be displayed in the map area 510B.
  • the above-mentioned map that should be displayed in the map area 510B is projected to the electronic device 200 .
  • the map displayed in the electronic device 200 is also adjusted accordingly. In this way, after invoking the above-mentioned map projection service, the user can still perform corresponding user operations in the map identification area 610B.
  • the user may swipe in various directions in the map identification area 610B to adjust the map displayed in the user interface 620 to view different areas of the map.
  • This embodiment of the present application does not limit the above-mentioned user operations acting on the map identification area 610B (or the map area 510B).
  • map identification area 610B can be a solid color layer with a certain degree of transparency (or a frame with the same size as the map area 510B), the map identification area 610B will not completely block the map identification in the game scene area 610A. The portion covered by area 610B.
  • the user can watch content with a wider field of view when performing game control on the electronic device 100, and can obtain a better game experience.
  • FIG. 8A and FIG. 8B exemplarily show schematic diagrams of scenarios in which the electronic device 100 ends the map projection service.
  • the electronic device 100 has invoked the map projection service, and displays the content in the game scene area 510A on the game interface. Using the user operations shown in FIGS. 6A and 6B , the electronic device 100 may display the service display area 512 . In response to a user operation acting on the map projection control 512E, the electronic device 100 may end the map projection service.
  • the electronic device 100 may display a service end prompt box 531 .
  • the service end prompt box 531 may include a text prompt "Are you sure to end map projection?" to ask the user whether to end the map projection service.
  • the embodiments of the present application do not limit the specific content of the above text prompts.
  • the service end prompt 531 may also include a confirmation control 531A and a cancel control 531B.
  • the confirmation control 531A can be used to trigger the electronic device 100 to end the map projection service.
  • the cancel control 531B may be used to instruct the electronic device 100 to continue projecting the map to the electronic device 200 .
  • the electronic device 100 may display the game interface 510 shown in FIG. 6B.
  • the game interface 510 may include a game scene area 510A and a map area 510B.
  • the map area 510B covers the game scene area 510A, and blocks a part of the content in the game scene area 510A.
  • the electronic device 100 may stop using the target instruction library to intercept the map instruction stream from the graphics instruction stream used to draw the game interface 510 . That is, the electronic device 100 can locally display the user interface 510 shown in FIG. 6B according to the graphics instruction flow used to draw the game interface 510 .
  • This embodiment of the present application does not limit the user operation for ending the above-mentioned map screen projection service.
  • the screen projection system 800 may include an electronic device 100 and an electronic device 200 .
  • the electronic device 100 may include a screen casting service calling module 810 , a game A application 820 , a screen casting module 830 , an instruction interception module 840 , a GPU driver 850 , a GPU 860 , a display screen 870 , an image conversion module 880 , and a first storage module 890 .
  • the electronic device 200 may include a screen projection module 8100 and a video playback module 8110 .
  • the electronic device 100 may display the game interface on the display screen 870 by using the game A application 820 , the instruction interception module 840 , the GPU driver 850 and the GPU 860 before receiving a user operation to invoke the map projection service.
  • the game A application 820 may include a game engine 821 .
  • the game engine 821 can obtain parameters for drawing the game interface in the game A application (the size of the map area 510B shown in FIG. 6B , the size of the building, the size of the player character, etc.).
  • the game engine 821 can call the 3D graphics processing library to obtain the graphics instruction stream for drawing the game interface.
  • the game engine 821 may pass the above-mentioned graphics instruction stream to the instruction interception module 840 .
  • Instruction interception module 840 may obtain an interface for receiving graphics instruction streams from game engine 821 .
  • the game engine 821 may transmit the graphics instruction stream through the above-mentioned interface for receiving the graphics instruction stream. Then the instruction interception module 840 can receive the above-mentioned graphics instruction stream.
  • the instruction interception module 840 may directly transmit the received graphics instruction stream to the GPU driver 850 .
  • the GPU driver 850 can convert the instructions in the above-mentioned graphics instruction stream into a low-level program, and drive the GPU 860 to execute the above-mentioned low-level program.
  • the above-mentioned underlying programs are programs (eg, machine codes) executable by the GPU 860 .
  • the GPU 860 executes the above-mentioned underlying program to obtain image data of the game interface, and transmits the image data of the game interface to the display screen 870 .
  • the display screen 870 may display the game interface of Game A (the game interface 510 shown in FIG. 6B ).
  • the electronic device 100 and the electronic device 200 can respectively display the content and the map area in the game scene area 510A shown in FIG. 6B according to the projection system shown in FIG. 9 . Contents of 510B.
  • the electronic device 100 may run an application program corresponding to the game A application 820 .
  • the electronic device 100 can display the game interface on the display screen 870 by using the game engine 821 , the instruction interception module 840 , the GPU driver 850 and the GPU 860 according to the methods described in the foregoing embodiments.
  • the screen projection service invocation module 810 may send an instruction to intercept the map instruction stream to the instruction interception module 840 , and send an instruction to enable the screen projection function to the screen projection module 830 .
  • the above-mentioned user operation for invoking the map screen projection service may be, for example, the aforementioned touch operation on the map screen projection control 512E shown in FIG. 6D .
  • the electronic device 100 and the electronic device 200 may establish a communication connection to transmit the data that needs to be projected.
  • the screen projection protocol such as Miracast, DLNA, AirPlay, etc.
  • the protocol used when transmitting the content that needs to be screened may also be a private protocol agreed upon between the electronic device 100 and the electronic device 200 .
  • the electronic device 100 can search for an electronic device that is in the same home Wi-Fi as itself and has the screen-casting function, and displays the above-mentioned display shown in FIG. 6E .
  • User Interface the electronic device 100 can search for an electronic device that is in the same home Wi-Fi as itself and has the screen-casting function, and displays the above-mentioned display shown in FIG. 6E .
  • the communication connection between the electronic device 100 and the electronic device 200 may be established before the electronic device 100 detects the above-mentioned user operation for invoking the map projection service.
  • the instruction interception module 840 can utilize the target instruction library to intercept the map instruction stream from the graphics instruction stream used to draw the game interface.
  • the above-mentioned graphics instruction stream for drawing the game interface is sent by the game engine 821 .
  • the graphics instruction stream may include a map instruction stream and a game scene instruction stream.
  • the method for the instruction interception module 840 to intercept the map instruction stream may be as follows: the instruction interception module 840 acquires the target instruction library corresponding to the game A application.
  • the target instruction library corresponding to the game A application includes instructions for drawing a map area (the map area 510B shown in FIG. 6B ) in the user interface of the game A.
  • the instruction interception module 840 can determine the instruction matching the target instruction library from the received graphics instruction stream, and perform an interception operation. In this way, the instruction interception module 840 can distinguish the map instruction stream and the game scene instruction stream in the graphics instruction stream.
  • the instruction interception module 840 can transmit the game scene instruction stream to the GPU driver 850 , and transmit the map instruction stream to the image conversion module 860 .
  • the GPU driver 850 can convert the instructions in the game scene instruction stream into the game scene low-level program, and drive the GPU 860 to execute the above-mentioned game scene low-level program.
  • the above-mentioned underlying program of the game scene is a program (eg, machine code) executable by the GPU 860 .
  • the GPU 860 may execute the above-mentioned game scene underlying program to obtain game scene image data, and transmit the game scene image data to the display screen 870 .
  • Display screen 870 may display content in a game scene area (such as game scene area 510A as shown in FIG. 6F ).
  • the image conversion module 880 may transmit the map instruction stream to the GPU driver 850 .
  • the image conversion module 880 may also obtain the address of the first storage module 890 and transmit the address of the first storage module 890 to the GPU driver 850 .
  • the GPU driver 850 can convert the instructions in the map instruction stream into a map low-level program, and drive the GPU 860 to execute the above-mentioned map low-level program.
  • the GPU driver 850 may instruct the GPU 860 to store the data obtained by executing the above-mentioned map underlying program into the first storage module 890 .
  • the above-mentioned map underlying program is a program (such as machine code) executable by the GPU860.
  • the GPU 860 can execute the above-mentioned map underlying program to obtain map image data. According to the address of the first storage module 890 , the GPU 860 may store the above-mentioned map image data to the first storage module 890 . The above-mentioned GPU can process the bottom-level program of the game scene and the bottom-level program of the map in parallel.
  • the image conversion module 880 may acquire the above-mentioned map image data from the first storage module 890, and convert the above-mentioned map image data into a first video stream.
  • the image conversion module 880 can encode the image by using H.264 or H.265 or other encoding methods, and convert the image into a video stream.
  • the embodiments of the present application do not limit the encoding method of the image conversion module 880 .
  • the image conversion module 880 may encode and convert each consecutive k frames of images into a video stream, and transmit the video stream including the k frames of images to the screen projection module 830 . That is, every time the electronic device 100 obtains images of k frames of maps, data including the images of the k frames of maps can be sent to the electronic device 200 .
  • the electronic device 200 may display images of the k frames of images.
  • the content in the map area 510B shown in FIG. 6B may change as the content in the game scene area 510A changes.
  • the value of the above k should not be too large, otherwise the content displayed on the electronic device 100 and the content displayed on the electronic device 200 may be out of sync.
  • the value of the above k can be set according to an empirical value.
  • the value of k is not limited in this embodiment of the present application.
  • the above method can reduce the time delay of displaying the two parts of the display content on a game interface of the game A application 820 on the electronic device 100 and the electronic device 200 respectively, and reduce the content displayed on the electronic device 100 and the content displayed on the electronic device 200 are not synchronized. Case.
  • the image conversion module 880 may pass the first video stream to the screen projection module 830 .
  • the screen projection module 830 may encode the first video stream based on the screen projection protocol adopted between the electronic device 100 and the electronic device 200 , and send the encoded first video stream to the electronic device 200 .
  • the screen projection module 8100 in the electronic device 200 may receive the above-mentioned encoded first video stream.
  • the screen projection module 8100 may decode the above-mentioned encoded first video stream based on the screen projection protocol adopted between the electronic device 100 and the electronic device 200 to obtain the first video stream.
  • the screen projection module 8100 can transmit the first video stream to the video playback module 8110 .
  • the video playing module 8110 can be used to play the images contained in the first video stream. In this way, the content of the map area 510B originally displayed in the game interface 510 of the electronic device 100 is projected to the electronic device 200 (refer to the user interface 530 shown in FIG. 6F ). After the above-mentioned screen projection process, the electronic device 100 may no longer display the content of the map area 510B shown in FIG. 6B .
  • the electronic device 200 may acquire the screen resolution of the electronic device 100 . According to the ratio between the screen resolution of the electronic device 100 and the screen resolution of the electronic device 200, the electronic device 200 may scale each frame of the image in the first video stream. In this way, the size of the map in the map area 510B can be adapted to the size of the screen of the electronic device 200 .
  • the above-mentioned screen projection service calling module 810, instruction interception module 840, and image conversion module 880 may all be modules in application A in the foregoing embodiments. That is, in the electronic device 100 with the application A installed, the above-mentioned screen projection service invocation module 810, instruction interception module 840, and image conversion module 880 can be used to implement the display method provided by the embodiment of the present application.
  • the content of the game scene area 510A in the game A application can be displayed on the electronic device 100 .
  • the content of the map area 510B in the game A application can be projected to the electronic device 200 and displayed by the electronic device 200 .
  • the user can perform game control on the electronic device 100 and view a map on the electronic device 200 during the process of playing the game A.
  • the visual field that the user can watch when performing game control on the electronic device 100 is no longer blocked by the map area 510B, and a better game experience can be obtained.
  • the electronic device 100 can implement the above-mentioned display method by means of the application A. That is, applications that need to be screened do not need to be modified. Then, if the developer of the third-party application does not make adaptive modifications to the application, the electronic device 100 can project part of the display content on one user interface of these third-party applications to other devices. This is beneficial for the display method provided by the present application to be suitable for various types of applications such as game applications, live broadcast applications, and video call applications.
  • the target instruction library corresponding to the above game A application 820 further includes a map identification instruction stream.
  • the above-described map identification instruction flow can be used to draw the content of the map identification area 610B shown in FIG. 7A.
  • the content of the map identification area 610B may be a solid color layer with a certain transparency.
  • the above-mentioned map identification instruction stream may be determined according to the map instruction stream.
  • the instruction interception module 840 may acquire the above-mentioned map identification instruction stream from the target instruction library, and combine the map identification instruction stream with the game scene instruction stream.
  • the map identification instruction stream can replace the map instruction stream in the graphics instruction stream used for drawing the game interface 510 to realize the integration with the game scene instruction stream.
  • the instruction interception module 840 may transmit the combined map identification instruction stream and game scene instruction stream to the GPU driver 850 . According to the above-mentioned game scene instruction flow and the above-mentioned map identification instruction flow, the electronic device 100 can display the game interface 610 as shown in FIG. 7A .
  • the game A application 820 When the game A application 820 receives a user operation acting on the map identification area 610B shown in FIG. 7A (that is, the map area 510B shown in FIG. 6B is displayed before the screen is projected), the map that can be displayed in the map area 510B will respond to the above-mentioned user operation. operation is adjusted.
  • the game engine 821 can obtain the above-mentioned parameters after the map adjustment (such as the characteristics of the elements in the map, etc.), and call the 3D graphics processing library to obtain the graphics instruction stream.
  • the graphics instruction stream includes an instruction stream for drawing the adjusted map.
  • the game engine 821 can assign values to parameters in the instruction when calling the 3D graphics processing library.
  • the parameters in the above-mentioned instruction may include the above-mentioned parameters after map adjustment.
  • the instruction interception module 840 can intercept the map instruction stream from the above-mentioned graphics instruction stream. This stream of map instructions may be used to draw a map that is adjusted in response to the user operations described above.
  • the electronic device 100 transmits the projected data (ie, the video stream converted from the above-mentioned map instruction stream) to the electronic device 200 .
  • the electronic device 200 may display the above-mentioned adjusted map.
  • the electronic device 100 may render on the local display screen according to the remaining instruction stream after the instruction stream interception operation, and display the content of the game scene area 510A as shown in FIG. 6F .
  • the electronic device 100 can still respond accordingly when detecting a user operation acting on the map area 510B previously displayed.
  • the results of the above responses may be presented on the user interface of the electronic device 200 .
  • the user operation acting on the map area 510B originally displayed is still valid.
  • the user may swipe in various directions in the map identification area 610B to adjust the map displayed in the user interface 620 to view different areas of the map.
  • the content displayed in the above-mentioned map identification area 610B can be a solid color layer with a certain degree of transparency (or a frame with the same size as the map area 510B)
  • the map identification area 610B will not completely block the map identification in the game scene area 610A.
  • the portion covered by area 610B Compared with the game interface 510 before screen projection, the user can watch content with a wider field of view when performing game control on the electronic device 100, and can obtain a better game experience.
  • the instructions in the target instruction library are exemplarily introduced.
  • glTexImage2D (GL_TEXTURE_2D, 0, GL_RGB, width, height, 0, GL_RGB, GL_UNSIGNED_BYTE, data).
  • the command glTexImage2D can be used to generate a two-dimensional image.
  • the first parameter in the command glTexImage2D can specify the type of image.
  • "GL_TEXTURE_2D” may indicate that the type of the image is a two-dimensional image.
  • the second parameter in the command glTexImage2D specifies the level of image loading. The second parameter being 0 may indicate the original picture level without downscaling.
  • the third parameter in the command glTexImage2D specifies the internal format of the image.
  • the above-mentioned internal format may represent the format in which the pixels of the image are stored in the graphics card.
  • "GL_RGB” can indicate that the color values of the pixels in the image are stored in RGB format.
  • the fourth and fifth parameters in the command glTexImage2D specify the width and height of the image, respectively.
  • the sixth parameter in the command glTexImage2D can specify the border width of the image.
  • the sixth parameter of 0 can indicate that the border width of the image is 0.
  • the seventh parameter in the command glTexImage2D can specify the storage format of the pixels of the image in memory.
  • the seventh parameter is "GL_RGB", which can indicate that the color value of the pixel in the image is stored in the memory in RGB format.
  • the eighth parameter in the command glTexImage2D can specify the data type of the pixels of the image in memory.
  • the ninth parameter in the instruction glTexImage2D can specify a pointer to the location in memory where the image data is stored.
  • the content in the map area 510B shown in FIG. 6B is a two-dimensional image.
  • the two-dimensional image may be generated using the above-mentioned command glTexImage2D.
  • the target instruction library may include the instruction and the parameters in the instruction corresponding to the content in the map area 510B.
  • the electronic device 100 can extract the map instruction stream from the graphics instruction stream used for drawing the game interface.
  • the instruction glDrawElements can be used to draw primitives.
  • Primitives are the base graphics for rendering. Primitives are made up of vertices. A vertex, a line segment, a triangle, or a polygon can be a primitive.
  • the first parameter in the instruction glDrawElements can specify the type of primitive. "GL_TRIANGLE" can indicate that the type of primitive is triangle.
  • the second parameter in the instruction glDrawElements is the product of the number of drawing primitives and the number of vertices of a primitive. Since the primitive is of type triangle, the number of vertices for a primitive is 3.
  • the second parameter in the instruction glDrawElements is 36 to indicate that the number of drawing primitives is 12.
  • the third parameter in the command glDrawElements can specify the data type of the primitive data.
  • the fourth parameter in the instruction glDrawElements can specify a pointer to the location in memory where the primitive data is stored
  • the content in map area 510B shown in FIG. 6B may include location markers for player characters in the map.
  • the position marker may be generated using the above-mentioned instruction glDrawElements.
  • the target instruction library may include the instruction and the parameters corresponding to the above-mentioned position marks in the instruction.
  • the specific value of the parameter may be obtained by the game engine 821 from the local game A application package or from the game server.
  • the target instruction library may also include more instructions. Different applications may correspond to different target instruction libraries.
  • the electronic device 100 may use a target instruction library corresponding to an application, for example, the target instruction library corresponding to the game A application 820, to intercept a map instruction stream for drawing the content of the map area 510B.
  • the target instruction library corresponding to an application may be obtained by acquiring a graphics instruction stream for drawing a user interface in the one application, and analyzing the graphics instruction stream.
  • the graphic instruction stream of the user interface may include an instruction stream A for drawing the first display content, and an instruction stream B for drawing the second display content.
  • the first display content is overlaid on the second display content, and partially blocks the second display content.
  • the analysis of the graphical instruction flow of the user interface described above may be manual analysis.
  • the above-mentioned instruction stream A is determined, and the instruction stream A is saved is the target instruction library.
  • the analysis of the graphic instruction flow of the user interface may be performed by a machine.
  • the machine may determine the instruction stream A from the graphic instruction stream of the user interface according to the instruction stream screening rule stored by the machine.
  • the above-mentioned instruction stream filtering rule may be determined according to the characteristics of the second display content displayed in the above-mentioned user interface.
  • the embodiments of the present application do not limit the method for acquiring the target instruction library corresponding to one application.
  • FIG. 10 exemplarily shows a schematic structural diagram of another screen projection system provided by an embodiment of the present application.
  • the screen projection system 900 may include an electronic device 100 and an electronic device 200 .
  • the electronic device 100 may include a screen-casting service calling module 910 , a game A application 920 , a screen-casting module 930 , an instruction interception module 940 , a GPU driver 950 , a GPU 960 and a display screen 970 .
  • the electronic device 200 may include a screen projection module 980 , a GPU driver 990 , a GPU 9100 and a display screen 9110 .
  • the electronic device 100 may display the game interface on the display screen 970 by using the game A application 920 , the instruction interception module 940 , the GPU driver 950 and the GPU 960 before receiving the user operation to invoke the map projection service.
  • the game A application 920 the instruction interception module 940 , the GPU driver 950 and the GPU 960 before receiving the user operation to invoke the map projection service.
  • the description of displaying the game interface on the display screen when the electronic device 100 does not receive a user operation to invoke the map screen projection service in the embodiment. I won't go into details here.
  • the electronic device 100 and the electronic device 200 can respectively display the content and the map area in the game scene area 510A shown in FIG. 6B according to the projection system shown in FIG. 10 . Contents of 510B.
  • the electronic device 100 may run an application program corresponding to the game A application 920 .
  • the electronic device 100 can display the game interface on the display screen 970 by using the game engine 921 , the instruction interception module 940 , the GPU driver 950 and the GPU 960 according to the methods described in the foregoing embodiments.
  • the screen projection service invocation module 910 may send an instruction to intercept the map instruction stream to the instruction interception module 940, and send an instruction to enable the screen projection function to the screen projection module 930.
  • the above-mentioned user operation for invoking the map screen projection service may be, for example, the aforementioned touch operation on the map screen projection control 512E shown in FIG. 6D .
  • the data that needs to be screened can be transmitted through the communication connection between the electronic device 100 and the electronic device 200 .
  • a method of establishing a communication connection between the electronic device 100 and the electronic device 200 reference may be made to the foregoing embodiments. I won't go into details here.
  • the instruction interception module 940 may utilize the target instruction library to intercept the map instruction stream from the graphics instruction stream used to draw the game interface.
  • the above-mentioned graphics instruction stream for drawing the game interface is sent by the game engine 921 .
  • the graphics instruction stream may include a map instruction stream and a game scene instruction stream.
  • the method for the instruction interception module 940 to intercept the map instruction stream may be as follows: the instruction interception module 940 acquires the target instruction library corresponding to the game A application.
  • the target instruction library corresponding to the game A application includes instructions for drawing a map area (the map area 510B shown in FIG. 6B ) in the user interface of the game A.
  • the instruction interception module 940 can determine the instruction matching the target instruction library from the received graphics instruction stream, and perform an interception operation. In this way, the instruction interception module 940 can distinguish the map instruction stream and the game scene instruction stream in the graphics instruction stream.
  • the instruction interception module 940 can transmit the game scene instruction stream to the GPU driver 950 , and transmit the map instruction stream to the screen projection module 930 .
  • the GPU driver 950 can convert the instructions in the game scene instruction stream into the game scene low-level program, and drive the GPU 960 to execute the above-mentioned game scene low-level program.
  • the above-mentioned underlying program of the game scene is a program (eg, machine code) executable by the GPU 960 .
  • the GPU 960 can execute the instructions in the above-mentioned game scene bottom layer program to obtain the game scene image data, and transmit the game scene image data to the display screen 970.
  • Display screen 970 may display content in a game scene area (eg, game scene area 510A as shown in FIG. 6F ).
  • the screen projection module 930 may encode the map instruction stream based on the protocol adopted between the electronic device 100 and the electronic device 200 , and send the encoded map instruction stream to the electronic device 200 .
  • the screen projection module 980 in the electronic device 200 can receive the above-mentioned encoded map instruction stream.
  • the screen projection module 980 can decode the encoded map instruction stream based on the protocol adopted between the electronic device 100 and the electronic device 200 to obtain the map instruction stream.
  • the screen projection module 980 can pass the map instruction stream to the GPU driver 990 .
  • the GPU driver 990 can convert the instructions in the map instruction stream into a map low-level program, and drive the GPU 9100 to execute the above-mentioned map low-level program.
  • the GPU 9100 can execute the above-mentioned map underlying program to obtain map image data.
  • GPU 9100 may pass map image data to display screen 9110 .
  • the electronic device 200 may display a map image on the display screen 9110 (refer to the user interface 530 shown in FIG. 6F ).
  • the electronic device 100 may transmit the map instruction stream for drawing the content in the map area 510B to the electronic device 200 .
  • the electronic device 200 may execute the map instruction stream to draw the content in the map area 510B on the display screen.
  • the electronic device 200 may acquire the screen resolution of the electronic device 100 . According to the ratio between the screen resolution of the electronic device 100 and the screen resolution of the electronic device 200, the electronic device 200 can scale the parameters in the received map instruction stream. In this way, the size of the map in the map area 510B can be adapted to the size of the screen of the electronic device 200 .
  • the above-mentioned screen casting service invocation module 910 and instruction interception module 940 may both be modules in application A in the foregoing embodiments. That is, in the electronic device 100 with the application A installed, the above-mentioned screen projection service invocation module 910 and the instruction interception module 940 can be used to implement the display method provided by the embodiment of the present application.
  • the content of the game scene area 510A in the game A application shown in FIG. 6B can be displayed on the electronic device 100 .
  • the content of the map area 510B in the game A application can be projected to the electronic device 200 and displayed by the electronic device 200 .
  • the user can perform game control on the electronic device 100 and view a map on the electronic device 200 during the process of playing the game A.
  • the visual field that the user can watch when performing game control on the electronic device 100 is no longer blocked by the map area 510B, and a better game experience can be obtained.
  • the electronic device 100 can implement the above-mentioned display method by means of the application A. That is, applications that need to be screened do not need to be modified. Then, if the developer of the third-party application does not make adaptive modifications to the application, the electronic device 100 can project part of the display content on one user interface of these third-party applications to other devices. This is beneficial for the display method provided by the present application to be suitable for various types of applications such as game applications, live broadcast applications, and video call applications.
  • the target instruction library corresponding to the above game A application 920 further includes a map identification instruction stream.
  • the above-described map identification instruction flow can be used to draw the content of the map identification area 610B shown in FIG. 7A.
  • the content of the map identification area 610B may be a solid color layer with a certain transparency.
  • the above-mentioned map identification instruction stream may be determined according to the map instruction stream.
  • the instruction interception module 940 may obtain the above-mentioned map identification instruction stream from the target instruction library, and combine the map identification instruction stream with the game scene instruction stream.
  • the map identification instruction stream can replace the map instruction stream in the graphics instruction stream used for drawing the game interface 510 to realize the integration with the game scene instruction stream.
  • the instruction interception module 940 may transmit the combined map identification instruction stream and game scene instruction stream to the GPU driver 950. According to the above-mentioned game scene instruction flow and the above-mentioned map identification instruction flow, the electronic device 100 can display the game interface 610 as shown in FIG. 7A .
  • the game A application 920 When the game A application 920 receives a user operation acting on the map identification area 610B shown in FIG. 7A (that is, the map area 510B shown in FIG. 6B is displayed before the screen is projected), the map that can be displayed in the map area 510B will respond to the above-mentioned user operation. operation is adjusted.
  • the game engine 921 can obtain the above-mentioned parameters after the map adjustment (such as the characteristics of the elements in the map, etc.), and call the 3D graphics processing library to obtain the graphics instruction stream.
  • the graphics instruction stream includes an instruction stream for drawing the adjusted map.
  • the game engine 921 can assign values to parameters in the instruction when calling the 3D graphics processing library.
  • the parameters in the above-mentioned instruction may include the above-mentioned parameters after map adjustment.
  • the instruction interception module 940 can intercept the map instruction stream from the above-mentioned graphics instruction stream. This stream of map instructions may be used to draw a map that is adjusted in response to the user operations described above.
  • the electronic device 100 transmits the projected data (ie, the above-mentioned map instruction stream) to the electronic device 200 .
  • the electronic device 200 may display the above-mentioned adjusted map.
  • the electronic device 100 may render on the local display screen according to the remaining instruction stream after the instruction stream interception operation, and display the content of the game scene area 510A as shown in FIG. 6F .
  • the electronic device 100 can still respond accordingly when detecting a user operation acting on the map area 510B previously displayed.
  • the results of the above responses may be presented on the user interface of the electronic device 200 .
  • the user operation acting on the originally displayed map area 510B is still valid.
  • the user may swipe in various directions in the map identification area 610B to adjust the map displayed in the user interface 620 to view different areas of the map.
  • the content displayed in the above-mentioned map identification area 610B can be a solid color layer with a certain degree of transparency (or a frame with the same size as the map area 510B)
  • the map identification area 610B will not completely block the map identification in the game scene area 610A.
  • the portion covered by area 610B Compared with the game interface 510 before screen projection, the user can watch content with a wider field of view when performing game control on the electronic device 100, and can obtain a better game experience.
  • FIG. 11 exemplarily shows a display method provided by an embodiment of the present application.
  • the method may include steps S101 to S106. in:
  • the electronic device 100 may detect a user operation for invoking a map projection service.
  • the electronic device 100 may be running the game A application and display the game interface of the game A application on the display screen.
  • the game interface reference may be made to the game interface 510 shown in FIG. 6B.
  • the above-mentioned map projection service may be provided by application A in the foregoing embodiment. According to the method shown in FIG. 5A to FIG. 5D, the application A and the game A application can be associated. In this way, application A can provide the above-mentioned map projection service for the game A application.
  • the above-mentioned user operation for invoking the map screen projection service may be, for example, the aforementioned touch operation on the map screen projection control 512E shown in FIG. 6D .
  • a communication connection may be established between the electronic device 100 and the electronic device 200 .
  • the electronic device 100 may request to establish a communication connection with the electronic device 200 .
  • the electronic device 100 and the electronic device 200 may be two devices in the same local area network (eg, the same home Wi-Fi).
  • the embodiments of the present application do not specifically limit the communication connection method between the electronic device 100 and the electronic device 200 .
  • the communication connection between the electronic device 100 and the electronic device 200 may also be established before the electronic device 100 detects a user operation that invokes the map projection service.
  • the electronic device 100 may intercept the map instruction stream from the graphics instruction stream for drawing the game interface, and the graphics instruction stream may include the map instruction stream and the game scene instruction stream.
  • the map instruction stream described above can be used to draw the content in the map area 510B shown in FIG. 6B.
  • the above-mentioned game scene instruction stream can be used to draw the content in the game scene area 510A shown in FIG. 6B .
  • the electronic device 100 may send the encoded map instruction stream or the encoded first video stream to the electronic device 200, where the first video stream is converted from the map instruction stream.
  • the electronic device 100 may perform rendering on the display screen of the electronic device 100 according to the game scene instruction stream.
  • the electronic device 100 can display the content in the game scene area 510A as shown in FIG. 6F on the display screen.
  • the electronic device 100 may also obtain a map identification instruction stream.
  • the map identification instruction stream can be used to draw the content in the map identification area 610B shown in FIG. 7A.
  • the map identification area 610B can be used to identify the location where the map area 510B shown in FIG. 6A is located before the screen is projected.
  • the map identification area 610B may be overlaid on the game scene area 610B.
  • the size and location in the game interface 610 of the map identification area 610B may be the same as the size and location in the game interface 510 of the map area 510B in FIG. 6A .
  • the content in the map identification area 610B may be a solid color layer with certain transparency as shown in FIG. 7A .
  • the above-mentioned solid color layer with certain transparency will not completely block the part of the game scene area 610A covered by the map identification area 610B.
  • the electronic device 100 can display the game interface 610 shown in FIG. 7A on the display screen.
  • the game interface 610 may include a game scene area 610A and a map identification area 610B.
  • the electronic device 200 may perform rendering on the display screen of the electronic device 200 according to the map instruction stream or the first video stream.
  • the electronic device 200 may display the map in the user interface 530 shown in FIG. 6F .
  • the electronic device 100 may also project part of the display content on a user interface in applications such as live broadcast applications, video call applications, and the like to the screen. to other electronic devices.
  • the content of the game scene area 510A in the game A application can be displayed on the electronic device 100 .
  • the content of the map area 510B in the game A application can be projected to the electronic device 200 and displayed by the electronic device 200 .
  • the user can perform game control on the electronic device 100 and view a map on the electronic device 200 during the process of playing the game A.
  • the visual field that the user can watch when performing game control on the electronic device 100 is no longer blocked by the map area 510B, and a better game experience can be obtained.
  • the electronic device 100 can implement the above-mentioned display method by means of the application A. That is, applications that need to be screened do not need to be modified. Then, if the developer of the third-party application does not make adaptive modifications to the application, the electronic device 100 can project part of the display content on one user interface of these third-party applications to other devices. This is beneficial for the display method provided in this application to be suitable for various types of applications such as game applications, live broadcast applications, and video call applications.
  • one user interface of one application may include three parts of display content or more display content.
  • the user interface includes three parts of display content (a first display content, a second display content and a third display content) as an example for description.
  • the electronic device 100 may project the first display content and the third display content to the electronic device 200 and the electronic device 300 respectively, and only locally display the second display content.
  • the electronic device 100 may store a target instruction library A corresponding to the above-mentioned first display content, and a target instruction library B corresponding to the third display content.
  • a target instruction library A corresponding to the above-mentioned first display content
  • a target instruction library B corresponding to the third display content.
  • the electronic device 100 may intercept the instruction stream for drawing the first display content from the graphic instruction stream for drawing the above-mentioned one user interface.
  • the electronic device 100 can intercept the instruction stream for drawing the third display content from the graphic instruction stream for drawing the above-mentioned one user interface.
  • the electronic device 100 may send the instruction stream for drawing the first display content to the electronic device 200 .
  • the electronic device 100 may first perform rendering in the background using the above-mentioned instruction stream for drawing the first display content to obtain an image including the first display content. Then, the electronic device 100 may convert the above-mentioned image containing the first display content into a video stream, and send the video stream to the electronic device 200 . In this way, the electronic device 200 can display the above-mentioned first display content.
  • the electronic device 100 may send the instruction stream for drawing the third display content to the electronic device 300 .
  • the electronic device 100 may first perform rendering in the background using the above-mentioned instruction stream for drawing the third display content to obtain an image including the third display content. Then, the electronic device 100 may convert the above-mentioned image including the third display content into a video stream, and send the video stream to the electronic device 300 . In this way, the electronic device 300 can display the above-mentioned third display content.
  • the remaining instruction streams in the graphics instruction stream used for drawing the above-mentioned one user interface may include the instruction stream used for drawing the second display content.
  • the electronic device 100 may display the second display content.
  • the specific implementation of the electronic device 100 , the electronic device 200 , and the electronic device 300 performing image rendering on the display screen according to the instruction stream may refer to the implementation in the prior art, which is not limited in this embodiment of the present application.
  • the first electronic device may run the first application and display the first user interface.
  • the first user interface may include first content and second content.
  • the above-mentioned first application may be a game application, a live broadcast application, a video call application, or the like in the foregoing embodiments.
  • the above-mentioned first user interface may be, for example, the aforementioned game interface 210 shown in FIG. 1 .
  • the above-mentioned first content may be the second display content (the content in the map area 210B shown in FIG. 1 ) in the foregoing embodiment.
  • the above-mentioned second content may be the first display content in the foregoing embodiment (the content in the game scene area 210A as shown in FIG. 1 ).
  • the first electronic device may display the second user interface in response to the first operation.
  • the second user interface may include the first content.
  • the aforementioned second user interface may be, for example, the aforementioned user interface of the electronic device 100 shown in FIG. 6F .
  • the above-mentioned first operation may be, for example, the aforementioned user operation shown in FIG. 6D acting on the map projection control 512E.
  • the first electronic device may send first data to the second electronic device, and the first data may cause the second electronic device to display the third user interface.
  • the third user interface may be, for example, the aforementioned user interface of the electronic device 200 shown in FIG. 6F .
  • the second user interface may further include third content.
  • the third content is displayed overlaid on a portion of the first content.
  • the third content may have transparency.
  • the second user interface including the third content may be, for example, the aforementioned game interface 610 shown in FIG. 7A .
  • the third content may be the content in the map identification area 610B shown in FIG. 7A.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Optics & Photonics (AREA)
  • Human Computer Interaction (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Radar, Positioning & Navigation (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

本申请提供一种显示方法及相关装置。在该方法中,第一电子设备可以显示一个应用的一个用户界面。该一个用户界面可包括第一显示内容和第二显示内容。第一电子设备可从用于绘制该一个用户界面的图形指令流中截取第一指令流。用于绘制该一个用户界面的图形指令流可包括第一指令流和第二指令流。第一指令流和第二指令流分别用于绘制第一显示内容和第二显示内容。根据第一指令流,第二电子设备可以显示第一显示内容。根据第二指令流,第一电子设备可以显示第二显示内容。上述方法可以实现应用内的投屏,且无需该应用进行适应性修改。

Description

显示方法及相关装置
本申请要求于2021年04月30日提交中国专利局、申请号为202110481999.6、申请名称为“显示方法及相关装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及终端技术领域,尤其涉及一种显示方法及相关装置。
背景技术
随着电子设备(如手机、平板电脑、笔记本电脑等)的发展,电子游戏受到越来越多用户的欢迎。许多电子游戏的游戏界面中部分区域可显示有地图,供用户查看游戏的全局情况。但上述显示地图的区域会覆盖部分显示游戏场景的区域,使得用户查看游戏场景的视野受阻,影响用户的游戏体验。
发明内容
本申请提供一种显示方法及相关装置。该方法可以将一个应用中一个用户界面的第一内容和第二内容分别显示在两个电子设备,实现应用内的投屏,避免一个用户界面中第二内容遮挡第一内容。
第一方面,本申请提供了一种显示方法,可应用于第一电子设备。在该方法中,第一电子设备可运行第一应用,显示第一用户界面。第一用户界面可包括第一内容和第二内容。其中,第二内容覆盖显示在部分第一内容上。第一用户界面与第一应用相关。第一电子设备可响应于第一操作,显示第二用户界面。第二用户界面可包括第一内容,第一内容中被第二内容覆盖的部分呈现在第二用户界面。第一电子设备可向第二电子设备发送第一数据。第一数据使得第二电子设备显示第三用户界面。第三用户界面可包括第二内容。其中,第一电子设备和第二电子设备通信连接。
上述第二用户界面中可不包括第二内容。上述第一内容可包括第一用户界面中由于第一内容遮挡而未被显示出来的内容。经过上述第一操作,第一电子设备可以将第一内容交由第二电子设备显示。那么,在第二用户界面中,第一内容中被第二内容遮挡的部分可以被显示出来。
上述第三用户界面中可不包括上述第一内容。上述第一用户界面与第一应用相关可以表示:第一用户界面中的第一内容和第二内容可以是运行第一应用得到的。第二电子设备根据上述第一数据显示第二内容。第二电子设备中未运行第一应用。即第二电子设备用于绘制上述第二内容的数据是由第一电子设备提供的(即第一数据)。
由上述方法可知,第一电子设备可以将一个应用中一个用户界面的部分显示内容交由第二电子设备显示,实现应用内的投屏。上述方法可以减少一个用户界面中第二内容遮挡第一内容的情况。用户在使用上述应用时,可以获得更好的体验。
结合第一方面,在一些实施例中,上述第二用户界面还可包括第三内容,第三内容可覆盖显示在部分第一内容上。第三内容可以具有透明度。第三内容的显示区域的大小和位置可以分别与第二内容的显示区域的大小和位置相同。
由该实施例可以看出,第一电子设备将上述第二内容交由第二电子设备显示后,上述第三内容可用于标识自己的显示区域是上述第二内容投屏前的显示区域。并且,第三内容具有透明度,不会完全遮挡第一内容中原先被第二内容遮挡的部分。
结合第一方面,在一些实施例中,第二用户界面可以包括上述第一内容而不包括上述第二内容。第一电子设备响应于第一操作,显示第二用户界面的具体方法可以为:第一电子设备响应于第一操作,根据第一指令流生成第二指令流和第三指令流。第一指令流与第一应用相关。第一电子设备可以根据第二指令流显示上述第二用户界面。
第一电子设备可以根据第三指令流,确定上述第一数据。
第一电子设备中可存储有目标指令库。该目标指令库中可包括上述第三指令流。第一电子设备根据第一指令流生成第二指令流和第三指令流的方法可以为:第一电子设备从第一指令流中确定出与目标指令库中的指令匹配的指令,并进行截取操作。经过上述截取操作,第一电子设备可以从上述第一指令流中区分出用于绘制第一内容的第二指令流,和用于绘制第二内容的第三指令流。
上述目标指令库可以是第一电子设备预先存储的,或者是从云服务器获取的。
由该实施例可以看出,上述显示方法不需要第一应用的开发者不对应用进行适应性修改。第一电子设备可以将第一应用中一个用户界面上的部分显示内容投屏至其他设备。这有利于本申请提供的显示方法适用于游戏应用、直播类应用、视频通话类应用等多种类型的应用。
结合第一方面,在一些实施例中,除了上述第一内容,第二用户界面还可以包括第三内容。第三内容覆盖显示在部分第一内容上。第三内容可以具有透明度。第一电子设备响应于第一操作,显示第二用户界面的具体方法可以为:第一电子设备响应于第一操作,根据第一指令流生成第二指令流和第三指令流。上述第一指令流与第一应用相关。第一电子设备可以根据第三指令流生成第四指令流,并根据上述第二指令流和上述第四指令流,生成第五指令流。第一电子设备可以根据上述第五指令流,显示上述包括第一内容和第三内容的用户界面。
第一电子设备可以根据上述第三指令流,确定上述第一数据。
可选的,上述第四指令流可以包含与目标指令库。第四指令流可用于绘制上述第三内容。
第一电子设备可以从目标指令库获取上述第四指令流。进一步的,第一电子设备可以根据第二指令流和第四指令流生成上述第五指令流。
结合第一方面,在一些实施例中,上述第一数据可以为上述第三指令流。或者,上述第一数据可以为第一视频流。第一视频流可以是根据包含第二内容的图像数据得到的。上述包含第二内容的图像数据可以是根据第三指令流得到的。
结合第一方面,在一些实施例中,第一电子设备还可以接收作用在第二用户界面第一区域的第二操作,并执行响应于上述第二操作的指令。上述第一区域可以为第一内容中被第二内容覆盖的部分呈现在第二用户界面的区域。或者,上述第一区域可以为第三内容的显示区域
也即是说,第一电子设备将上述第二内容交由第二电子设备显示后,第一电子设备在原先第二内容的显示区域可响应的用户操作仍然有效。原先第二内容的显示区域即为上述第一区域。
第二方面,本申请提供了一种电子设备,该电子设备为第一电子设备。第一电子设备可包括第一应用、投屏服务调用模块、投屏模块、指令截取模块、图形处理器GPU驱动、GPU、显示屏和存储模块。
第一应用可运行在第一电子设备中。其中,第一电子设备运行第一应用,并调用三维图 形处理库可以得到用于绘制第一用户界面的第一指令流。第一用户界面中可包括第一内容和第二内容。第二内容覆盖显示在部分第一内容上。上述第一内容可包括第一用户界面中由于第一内容遮挡而未被显示出来的内容。上述第一指令可以从第一应用传递至指令截取模块。
投屏服务调用模块可用于响应第一操作,向指令截取模块发送截取指令流的指令,并向投屏模块发送开启投屏功能的指令。
当接收到上述截取指令流的指令,指令截取模块可以利用目标指令库对上述第一指令流进行截取操作,得到第二指令流和第三指令流。上述目标指令库可包括上述第三指令流。第二指令流可以从指令截取模块传递至GPU驱动。GPU驱动可以将上述第二指令流转换为GPU可执行的程序,并驱动GPU执行由第二指令流转换得到的可执行程序。GPU可以得到上述第一内容的图像数据。该第一内容的图像数据可以传递至显示屏。根据上述第一内容的图像数据,显示屏可以显示第二用户界面。第二用户界面可包括第一显示内容。第一内容中被第二内容覆盖的部分呈现在第二用户界面。
投屏模块可用于将第一数据发送给第二电子设备。第一数据可以使得第二电子设备显示第三用户界面。第三用户界面包括第二内容。第三用户界面可不包括第一内容。上述第一数据可以是根据上述第三指令流确定的。
上述存储模块可用于存储第一应用的程序安装包、三维图形处理库和目标指令库。
可以看出,第一电子设备可以将一个应用中一个用户界面的部分显示内容交由第二电子设备显示,实现应用内的投屏。上述方法可以减少一个用户界面中第二内容遮挡第一内容的情况。用户在使用上述应用时,可以获得更好的体验。
结合第二方面,在一些实施例中,指令截取模块还可用于根据第三指令流,生成第四指令流,并根据第二指令流和第四指令流生成第五指令流。上述第四指令流可用于绘制第三内容。上述第五指令流可以从指令截取模块传递至GPU驱动。GPU驱动可以将第五指令流转换为GPU可执行的程序,并驱动GPU执行由第五指令流转换得到的可执行程序。GPU可以得到包括第一内容和第三内容的图像数据。该第一内容和第三内容的图像数据可以传递至显示屏。根据上述第一内容和第三内容的图像数据,显示屏可以显示包含第一内容和第三内容的第二用户界面。在第二用户界面中,第三内容覆盖显示在部分第一内容上。第三内容具有透明度。第三内容的显示区域的大小和位置分别与第二内容的显示区域的大小和位置相同。
由该实施例可以看出,第一电子设备将上述第二内容交由第二电子设备显示后,上述第三内容可用于标识自己的显示区域是上述第二内容投屏前的显示区域。并且,第三内容具有透明度,不会完全遮挡第一内容中原先被第二内容遮挡的部分。
结合第二方面,在一些实施例中,上述第一数据可以为第三指令流。即当指令截取模块得到上述第三指令流,投屏模块可以将第三指令流发送给第二电子设备。第二电子设备可以根据该第三指令流在显示屏上显示第二内容。
结合第二方面,在一些实施例中,上述第一数据可以为第一视频流。第一电子设备中还可以包含图像转换模块和第一存储模块。上述第一存储模块可以为上述存储模块中的一块存储区域。当指令截取模块得到上述第三指令流,第三指令流可以从指令截取模块传递至图像转换模块。图像转换模块可以将第三指令流传递至GPU驱动。图像转换模块还可以将第一存储模块的存储路径传递至GPU驱动。GPU驱动可以将第三指令流转换为GPU可执行的程序,并驱动GPU执行由第三指令流转换得到的可执行程序。GPU可以得到第二内容的图像数据,并将第二内容的图像数据存储至上述第一存储模块。
图像转换模块可用于将上述第二内容的图像数据转换为第一视频流,并将第一视频流传 递至投屏模块。投屏模块可以将第一视频流发送给第二电子设备。第二电子设备可以根据第一视频流在显示屏显示第二内容。
第三方面,本申请提供了一种显示系统。该显示系统可包括第一电子设备和第二电子设备。第一电子设备和第二电子设备通信连接。第一电子设备可用于运行第一应用,显示第一用户界面,第一用户界面包括第一内容和第二内容,其中,第二内容覆盖显示在部分第一内容上,第一用户界面与第一应用相关。第一电子设备还可用于响应于第一操作,显示第二用户界面,第二用户界面包括第一内容,第一内容中被第二内容覆盖的部分呈现在第二用户界面。第一电子设备还可用于向第二电子设备发送第一数据。第二电子设备可用于根据第一数据显示第三用户界面,第三用户界面包括第二内容。
结合第三方面,在一些实施例中,第二用户界面还包括第三内容,第三内容覆盖显示在部分第一内容上,第三内容具有透明度。第三内容的显示区域的大小和位置分别与第二内容的显示区域的大小和位置相同。
结合第三方面,在一些实施例中,第二用户界面可包括第一内容而不包括第二内容。第一电子设备可用于响应于第一操作,根据第一指令流生成第二指令流和第三指令流,第一指令流与第一应用相关;根据第二指令流,显示第二用户界面;根据第三指令流,确定第一数据。
结合第三方面,在一些实施例中,第二用户界面可包括第一内容和第三内容。第一电子设备可用于响应于第一操作,根据第一指令流生成第二指令流和第三指令流,第一指令流与第一应用相关;根据第三指令流,生成第四指令流;根据第二指令流和第四指令流,生成第五指令流;根据第五指令流,显示第二用户界面,第二用户界面包括第一内容和第三内容;根据第三指令流,确定第一数据。
结合第三方面,在一些实施例中,第一数据可以为第三指令流。或者,第一数据可以为第一视频流,第一视频流是根据包含第二内容的图像数据得到的,包含第二内容的图像数据是根据第三指令流得到的。
结合第三方面,在一些实施例中,第一电子设备可用于接收作用在第二用户界面第一区域的第二操作,第一区域为第一内容中被第二内容覆盖的部分呈现在第二用户界面的区域;执行响应于第二操作的指令。
第四方面,本申请还提供了一种电子设备。该电子设备可包括显示屏、通信模块、存储器和处理器,其中,存储器可用于存储计算机程序,处理器可用于调用计算机程序,使得电子设备执行如第一方面中任一可能的实现方式。
第五方面,本申请提供了一种芯片,该芯片应用于设备,该芯片包括一个或多个处理器,该处理器用于调用计算机指令以使得该设备执行如第一方面中任一可能的实现方式。
第六方面,本申请提供了一种包含指令的计算机程序产品,其特征在于,当上述计算机程序产品在设备上运行时,使得上述设备执行如第一方面中任一可能的实现方式。
第七方面,本申请提供了一种计算机可读存储介质,包括指令,其特征在于,当上述指令在设备上运行时,使得上述设备执行如第一方面中任一可能的实现方式。
可以理解地,上述第三方面提供的显示系统、第四方面提供的电子设备、第五方面提供的芯片、第六方面提供的计算机程序产品和第七方面提供的计算机可读存储介质均用于执行本申请实施例所提供的方法。因此,其所能达到的有益效果可参考对应方法中的有益效果,此处不再赘述。
附图说明
图1是本申请实施例提供的一种游戏界面的示意图;
图2是本申请实施例提供的一种电子设备100的结构示意图;
图3是本申请实施例提供的另一种电子设备100的结构示意图;
图4是本申请实施例提供的一种投屏系统的示意图;
图5A~图5D是本申请实施例提供的游戏应用与应用A关联的场景示意图;
图6A~图6F是本申请实施例提供的一些电子设备100投屏的场景示意图;
图7A和图7B是本申请实施例提供的另一些电子设备100投屏的场景示意图;
图8A和图8B是本申请实施例提供的一些电子设备100结束投屏的场景示意图;
图9是本申请实施例提供的一种投屏系统的结构示意图;
图10是本申请实施例提供的另一种投屏系统的结构示意图;
图11是本申请实施例提供的一种显示方法的流程图。
具体实施方式
下面将结合附图对本申请实施例中的技术方案进行清楚、详尽地描述。其中,在本申请实施例的描述中,除非另有说明,“/”表示或的意思,例如,A/B可以表示A或B;文本中的“和/或”仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况,另外,在本申请实施例的描述中,“多个”是指两个或多于两个。
以下,术语“第一”、“第二”仅用于描述目的,而不能理解为暗示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”的特征可以明示或者隐含地包括一个或者更多个该特征,在本申请实施例的描述中,除非另有说明,“多个”的含义是两个或两个以上。
图1示例性示出了一种电子游戏的游戏界面示意图。
如图1所示,电子设备100可以运行游戏应用,并显示游戏界面210。游戏界面210可包括游戏场景区域210A和地图区域210B。其中:
游戏场景区域210A显示的内容可以占满游戏界面210。游戏场景区域210A可用于显示游戏中的环境、建筑、玩家角色、非玩家角色、用于控制玩家角色的操作控件等等元素。
地图区域210B可用于显示游戏中的地图。地图区域210B中可包括玩家角色的位置标记、一些特殊地点的位置标记等等。本申请实施例对游戏场景区域210A和地图区域210B中显示的内容均不作限定。
由图1可以看出,地图区域210B可以覆盖在游戏场景区域210A上。即地图区域210B会遮挡一部分游戏场景区域210A中呈现的内容。游戏场景区域210A中被遮挡的部分无法被用户看到。用户查看游戏场景的视野受阻。如果游戏场景区域210A中呈现的内容没有被上述地图区域210B遮挡,用户的游戏体验会更好。
本申请实施例提供一种显示方法。该方法可以将电子设备100用户界面中的一部分显示内容投屏至电子设备200。电子设备200可以显示上述被投屏的一部分显示内容。具体的,电子设备100可以运行应用A,并显示该应用A的用户界面A。该用户界面A可包括第一显 示内容和第二显示内容。电子设备100可以根据目标指令库从上述用户界面A的图形指令流中截取第一显示内容的图形指令流。根据上述第一显示内容的图形指令流,电子设备200可以显示上述第一显示内容。经过上述图形指令流的截取,电子设备100可以根据上述用户界面A的图形指令流中其它部分图形指令流(如第二显示内容的图形指令流),显示用户界面中A第一显示内容以外的内容。
上述第一显示内容和上述第二显示内容均可独立显示。在一种可能的实现方式中,电子设备100在用户界面A中渲染第一显示内容的渲染线程和渲染第二显示内容的渲染线程是不同的。电子设备100可以并行执行渲染第一显示内容的渲染线程和渲染第二显示内容的渲染线程,实现同时在用户界面中显示第一显示内容和第二显示内容。线程可以表示进程中一个单一顺序的控制流。其中进程为电子设备中已运行的程序。一个进程中可以并行多个线程,每条线程并行执行不同的任务。上述不同的渲染线程可以执行渲染不同内容的任务(如渲染第一显示内容和渲染第二显示内容)。
在一些实施例中,上述第一显示内容可以覆盖在第二显示内容上,并部分遮挡第二显示内容。其中,上述用户界面A的图形指令流可包括用于绘制上述第二显示内容中被第一显示内容遮挡的内容的图形指令流。若电子设备100移除用户界面A中的第一显示内容,用户界面A中可显示第二显示内容中被第一显示内容遮挡的内容。
上述目标指令库可包括绘制第一显示内容的绘制指令(如用于绘制图形的函数以及函数中的参数)。目标指令库可以是电子设备100预先存储的,或者是从云服务器获取的。本申请实施例对电子设备100获取目标指令库的方法不作限定。
也即是说,上述第一显示内容可以是根据上述目标指令库中的绘制指令绘制的得到的内容。
电子设备100根据目标指令库从用户界面A的图形指令流中截取第一显示内容的图形指令流,具体方法可以为:电子设备100从用户界面A的图形指令流中确定出与目标指令库中的指令匹配的指令,并进行截取操作,得到上述第一显示内容的图形指令流。
上述用户界面的图形指令流可包括一条或多条用于绘制上述用户界面的指令。
由上述显示方法可知,电子设备100可以将一个应用中一个用户界面的部分显示内容交由电子设备200显示,实现应用内的投屏。上述显示方法可以减少一个用户界面中第一显示内容遮挡第二显示内容的情况。用户在使用上述应用时,可以获得更好的体验。
上述应用可以是游戏应用、直播类应用、视频通话类应用等等。本申请实施例对上述投屏过程中应用的类型不作限定。
本申请后续实施例中具体以游戏应用为例来介绍本申请实施例提供的显示方法。其中,图1所示的游戏场景区域210A显示的内容即为上述第二显示内容。图1所示的地图区域210B显示的内容即为上述第一显示内容。游戏界面210的图形指令流中可包括地图指令流和游戏场景指令流。其中,用于绘制游戏界面210的图形指令流可以是从游戏引擎中得到的。地图指令流中包括用于绘制地图区域210B显示的内容的指令。游戏场景指令流中包括用于绘制游戏场景区域210A显示的内容的指令。根据游戏场景指令流所绘制的图像可包含游戏场景区域210A中被地图区域210B遮挡的内容。
在一种可能的实现方式中,电子设备100可以根据目标指令库从游戏界面210的图形指令流中截取地图指令流。当截取出地图指令流,电子设备100可以根据该地图指令流进行渲染,得到地图区域210B的图像。进一步的,电子设备100可以将上述地图区域210B的图像 编码为视频流,并将该视频流发送给电子设备200。电子设备200可以显示该视频流。即地图区域210B中呈现的内容可以显示在电子设备200上。另外,电子设备100可以根据指令流截取操作之后余下的指令流,例如游戏场景指令流,在本地显示游戏场景区域210A中的内容。这样,电子设备100可以显示游戏场景区域210A中的内容。电子设备200可以显示地图区域210B中的内容。地图区域210B不再遮挡游戏场景区域210A中的内容。用户在游戏过程中可以获得更大的视野。
在另一种可能的实现方式中,电子设备100可以根据目标指令库从游戏界面210的图形指令流中截取地图指令流,并将该地图指令流发送给电子设备200。电子设备200可以执行该地图指令流中包括的指令,显示地图区域210B中的内容。另外,电子设备100可以根据指令流截取操作之后余下的指令流,例如游戏场景指令流,在本地显示游戏场景区域210A中的内容。这样,电子设备100可以显示游戏场景区域210A中的内容。电子设备200可以显示地图区域210B中的内容。地图区域210B不再遮挡游戏场景区域210A中的内容。用户在游戏过程中可以获得更大的视野。
在一些实施例中,电子设备100中可安装有应用A。该应用A可以例如是应用助手应用、游戏助手应用等等。应用A可用于为与之关联的应用提供的辅助服务包括但不限于:消息免打扰、截屏、录屏、游戏加速。
电子设备100可以将应用A与上述游戏应用关联。通过上述应用A,电子设备100可以获取上述目标指令库。响应于将地图区域210B的内容投屏至电子设备200的用户操作,电子设备100可以根据目标指令库,利用本申请实施例提供的显示方法,将地图区域210B的内容交由电子设备200显示。电子设备100关联应用A和游戏应用的过程在后续实施例中进行介绍,这里先不展开说明。
可以看出,电子设备100可以借助应用A实现上述显示方法。即需要进行投屏的应用无需修改。那么在第三方应用的开发者不对应用进行适应性修改的情况下,电子设备100可以将这些第三方应用中一个用户界面上的部分显示内容投屏至其他设备。这有利于本申请提供的显示方法适用于游戏应用、直播类应用、视频通话类应用等多种类型的应用。
电子设备100可以是手机、平板电脑、笔记本电脑、超级移动个人计算机(ultra-mobile personal computer,UMPC)、上网本、个人数字助理(personaldigital assistant,PDA)等等具有显示屏的设备。本申请实施例对电子设备100的具体类型不作限定。
图2示例性示出了本申请实施例提供的一种电子设备100的结构示意图。
如图2所示,电子设备100可以包括处理器110,外部存储器接口120,内部存储器121,通用串行总线(universal serial bus,USB)接口130,充电管理模块140,电源管理模块141,电池142,天线1,天线2,移动通信模块150,无线通信模块160,音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,传感器模块180,按键190,马达191,指示器192,摄像头193,显示屏194,以及用户标识模块(subscriber identification module,SIM)卡接口195等。其中传感器模块180可以包括压力传感器180A,陀螺仪传感器180B,气压传感器180C,磁传感器180D,加速度传感器180E,距离传感器180F,接近光传感器180G,指纹传感器180H,温度传感器180J,触摸传感器180K,环境光传感器180L,骨传导传感器180M等。
可以理解的是,本申请实施例示意的结构并不构成对电子设备100的具体限定。在本申 请另一些实施例中,电子设备100可以包括比图示更多或更少的部件,或者组合某些部件,或者拆分某些部件,或者不同的部件布置。图示的部件可以以硬件,软件或软件和硬件的组合实现。
处理器110可以包括一个或多个处理单元,例如:处理器110可以包括应用处理器(application processor,AP),调制解调处理器,图形处理器(graphics processing unit,GPU),图像信号处理器(image signal processor,ISP),控制器,存储器,视频编解码器,数字信号处理器(digital signal processor,DSP),基带处理器,和/或神经网络处理器(neural-network processing unit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。
处理器110中还可以设置存储器,用于存储指令和数据。在一些实施例中,处理器110中的存储器为高速缓冲存储器。该存储器可以保存处理器110刚用过或循环使用的指令或数据。如果处理器110需要再次使用该指令或数据,可从所述存储器中直接调用。避免了重复存取,减少了处理器110的等待时间,因而提高了系统的效率。
USB接口130是符合USB标准规范的接口,具体可以是Mini USB接口,Micro USB接口,USB Type C接口等。USB接口130可以用于连接充电器为电子设备100充电,也可以用于电子设备100与外围设备之间传输数据。也可以用于连接耳机,通过耳机播放音频。该接口还可以用于连接其他电子设备,例如AR设备等。
充电管理模块140用于从充电器接收充电输入。其中,充电器可以是无线充电器,也可以是有线充电器。充电管理模块140为电池142充电的同时,还可以通过电源管理模块141为电子设备供电。
电源管理模块141用于连接电池142,充电管理模块140与处理器110。电源管理模块141接收电池142和/或充电管理模块140的输入,为处理器110,内部存储器121,外部存储器,显示屏194,摄像头193,和无线通信模块160等供电。
电子设备100的无线通信功能可以通过天线1,天线2,移动通信模块150,无线通信模块160,调制解调处理器以及基带处理器等实现。
天线1和天线2用于发射和接收电磁波信号。电子设备100中的每个天线可用于覆盖单个或多个通信频带。不同的天线还可以复用,以提高天线的利用率。
移动通信模块150可以提供应用在电子设备100上的包括2G/3G/4G/5G等无线通信的解决方案。移动通信模块150可以包括至少一个滤波器,开关,功率放大器,低噪声放大器(low noise amplifier,LNA)等。移动通信模块150可以由天线1接收电磁波,并对接收的电磁波进行滤波,放大等处理,传送至调制解调处理器进行解调。移动通信模块150还可以对经调制解调处理器调制后的信号放大,经天线1转为电磁波辐射出去。在一些实施例中,移动通信模块150的至少部分功能模块可以被设置于处理器110中。在一些实施例中,移动通信模块150的至少部分功能模块可以与处理器110的至少部分模块被设置在同一个器件中。
调制解调处理器可以包括调制器和解调器。其中,调制器用于将待发送的低频基带信号调制成中高频信号。解调器用于将接收的电磁波信号解调为低频基带信号。随后解调器将解调得到的低频基带信号传送至基带处理器处理。低频基带信号经基带处理器处理后,被传递给应用处理器。应用处理器通过音频设备(不限于扬声器170A,受话器170B等)输出声音信号,或通过显示屏194显示图像或视频。在一些实施例中,调制解调处理器可以是独立的器件。在另一些实施例中,调制解调处理器可以独立于处理器110,与移动通信模块150或其他功能模块设置在同一个器件中。
无线通信模块160可以提供应用在电子设备100上的包括无线局域网(wireless local area networks,WLAN)(如无线保真(wireless fidelity,Wi-Fi)网络),蓝牙(bluetooth,BT),全球导航卫星系统(global navigation satellite system,GNSS),调频(frequency modulation,FM),近距离无线通信技术(near field communication,NFC),红外技术(infrared,IR)等无线通信的解决方案。无线通信模块160可以是集成至少一个通信处理模块的一个或多个器件。无线通信模块160经由天线2接收电磁波,将电磁波信号调频以及滤波处理,将处理后的信号发送到处理器110。无线通信模块160还可以从处理器110接收待发送的信号,对其进行调频,放大,经天线2转为电磁波辐射出去。
电子设备100通过GPU,显示屏194,以及应用处理器等实现显示功能。GPU为图像处理的微处理器,连接显示屏194和应用处理器。GPU用于执行数学和几何计算,用于图形渲染。处理器110可包括一个或多个GPU,其执行程序指令以生成或改变显示信息。
显示屏194用于显示图像,视频等。显示屏194包括显示面板。显示面板可以采用液晶显示屏(liquid crystal display,LCD),有机发光二极管(organic light-emitting diode,OLED),有源矩阵有机发光二极体或主动矩阵有机发光二极体(active-matrix organic light emitting diode的,AMOLED),柔性发光二极管(flex light-emitting diode,FLED),Miniled,MicroLed,Micro-oLed,量子点发光二极管(quantum dot light emitting diodes,QLED)等。在一些实施例中,电子设备100可以包括1个或N个显示屏194,N为大于1的正整数。
电子设备100可以通过ISP,摄像头193,视频编解码器,GPU,显示屏194以及应用处理器等实现拍摄功能。
ISP用于处理摄像头193反馈的数据。例如,拍照时,打开快门,光线通过镜头被传递到摄像头感光元件上,光信号转换为电信号,摄像头感光元件将所述电信号传递给ISP处理,转化为肉眼可见的图像。ISP还可以对图像的噪点,亮度,肤色进行算法优化。ISP还可以对拍摄场景的曝光,色温等参数优化。在一些实施例中,ISP可以设置在摄像头193中。
摄像头193用于捕获静态图像或视频。物体通过镜头生成光学图像投射到感光元件。感光元件可以是电荷耦合器件(charge coupled device,CCD)或互补金属氧化物半导体(complementary metal-oxide-semiconductor,CMOS)光电晶体管。感光元件把光信号转换成电信号,之后将电信号传递给ISP转换成数字图像信号。ISP将数字图像信号输出到DSP加工处理。DSP将数字图像信号转换成标准的RGB,YUV等格式的图像信号。在一些实施例中,电子设备100可以包括1个或N个摄像头193,N为大于1的正整数。
数字信号处理器用于处理数字信号,除了可以处理数字图像信号,还可以处理其他数字信号。例如,当电子设备100在频点选择时,数字信号处理器用于对频点能量进行傅里叶变换等。
视频编解码器用于对数字视频压缩或解压缩。电子设备100可以支持一种或多种视频编解码器。这样,电子设备100可以播放或录制多种编码格式的视频,例如:动态图像专家组(moving picture experts group,MPEG)1,MPEG2,MPEG3,MPEG4等。
NPU为神经网络(neural-network,NN)计算处理器,通过借鉴生物神经网络结构,例如借鉴人脑神经元之间传递模式,对输入信息快速处理,还可以不断的自学习。通过NPU可以实现电子设备100的智能认知等应用,例如:图像识别,人脸识别,语音识别,文本理解等。
外部存储器接口120可以用于连接外部存储卡,例如Micro SD卡,实现扩展电子设备100的存储能力。外部存储卡通过外部存储器接口120与处理器110通信,实现数据存储功 能。例如将音乐,视频等文件保存在外部存储卡中。
内部存储器121可以用于存储计算机可执行程序代码,所述可执行程序代码包括指令。处理器110通过运行存储在内部存储器121的指令,从而执行电子设备100的各种功能应用以及数据处理。内部存储器121可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用程序(比如声音播放功能,图像播放功能等)等。存储数据区可存储电子设备100使用过程中所创建的数据(比如音频数据,电话本等)等。此外,内部存储器121可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件,闪存器件,通用闪存存储器(universal flash storage,UFS)等。
电子设备100可以通过音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,以及应用处理器等实现音频功能。例如音乐播放,录音等。
音频模块170用于将数字音频信息转换成模拟音频信号输出,也用于将模拟音频输入转换为数字音频信号。音频模块170还可以用于对音频信号编码和解码。在一些实施例中,音频模块170可以设置于处理器110中,或将音频模块170的部分功能模块设置于处理器110中。
扬声器170A,也称“喇叭”,用于将音频电信号转换为声音信号。电子设备100可以通过扬声器170A收听音乐,或收听免提通话。
受话器170B,也称“听筒”,用于将音频电信号转换成声音信号。当电子设备100接听电话或语音信息时,可以通过将受话器170B靠近人耳接听语音。
麦克风170C,也称“话筒”,“传声器”,用于将声音信号转换为电信号。当拨打电话或发送语音信息时,用户可以通过人嘴靠近麦克风170C发声,将声音信号输入到麦克风170C。电子设备100可以设置至少一个麦克风170C。在另一些实施例中,电子设备100可以设置两个麦克风170C,除了采集声音信号,还可以实现降噪功能。在另一些实施例中,电子设备100还可以设置三个,四个或更多麦克风170C,实现采集声音信号,降噪,还可以识别声音来源,实现定向录音功能等。
耳机接口170D用于连接有线耳机。耳机接口170D可以是USB接口130,也可以是3.5mm的开放移动电子设备平台(open mobile terminal platform,OMTP)标准接口,美国蜂窝电信工业协会(cellular telecommunications industry association of the USA,CTIA)标准接口。
压力传感器180A用于感受压力信号,可以将压力信号转换成电信号。在一些实施例中,压力传感器180A可以设置于显示屏194。压力传感器180A的种类很多,如电阻式压力传感器,电感式压力传感器,电容式压力传感器等。电容式压力传感器可以是包括至少两个具有导电材料的平行板。当有力作用于压力传感器180A,电极之间的电容改变。电子设备100根据电容的变化确定压力的强度。当有触摸操作作用于显示屏194,电子设备100根据压力传感器180A检测所述触摸操作强度。电子设备100也可以根据压力传感器180A的检测信号计算触摸的位置。在一些实施例中,作用于相同触摸位置,但不同触摸操作强度的触摸操作,可以对应不同的操作指令。例如:当有触摸操作强度小于第一压力阈值的触摸操作作用于短消息应用图标时,执行查看短消息的指令。当有触摸操作强度大于或等于第一压力阈值的触摸操作作用于短消息应用图标时,执行新建短消息的指令。
陀螺仪传感器180B可以用于确定电子设备100的运动姿态。
气压传感器180C用于测量气压。
磁传感器180D包括霍尔传感器。电子设备100可以利用磁传感器180D检测翻盖皮套的开合。在一些实施例中,当电子设备100是翻盖机时,电子设备100可以根据磁传感器180D 检测翻盖的开合。进而根据检测到的皮套的开合状态或翻盖的开合状态,设置翻盖自动解锁等特性。
加速度传感器180E可检测电子设备100在各个方向上(一般为三轴)加速度的大小。当电子设备100静止时可检测出重力的大小及方向。还可以用于识别电子设备姿态,应用于横竖屏切换,计步器等应用。
距离传感器180F,用于测量距离。电子设备100可以通过红外或激光测量距离。在一些实施例中,拍摄场景,电子设备100可以利用距离传感器180F测距以实现快速对焦。
接近光传感器180G可以包括例如发光二极管(LED)和光检测器,例如光电二极管。发光二极管可以是红外发光二极管。电子设备100通过发光二极管向外发射红外光。电子设备100使用光电二极管检测来自附近物体的红外反射光。当检测到充分的反射光时,可以确定电子设备100附近有物体。当检测到不充分的反射光时,电子设备100可以确定电子设备100附近没有物体。电子设备100可以利用接近光传感器180G检测用户手持电子设备100贴近耳朵通话,以便自动熄灭屏幕达到省电的目的。接近光传感器180G也可用于皮套模式,口袋模式自动解锁与锁屏。
环境光传感器180L用于感知环境光亮度。电子设备100可以根据感知的环境光亮度自适应调节显示屏194亮度。环境光传感器180L也可用于拍照时自动调节白平衡。环境光传感器180L还可以与接近光传感器180G配合,检测电子设备100是否在口袋里,以防误触。
指纹传感器180H用于采集指纹。电子设备100可以利用采集的指纹特性实现指纹解锁,访问应用锁,指纹拍照,指纹接听来电等。
温度传感器180J用于检测温度。
触摸传感器180K,也称“触控面板”。触摸传感器180K可以设置于显示屏194,由触摸传感器180K与显示屏194组成触摸屏,也称“触控屏”。触摸传感器180K用于检测作用于其上或附近的触摸操作。触摸传感器可以将检测到的触摸操作传递给应用处理器,以确定触摸事件类型。可以通过显示屏194提供与触摸操作相关的视觉输出。在另一些实施例中,触摸传感器180K也可以设置于电子设备100的表面,与显示屏194所处的位置不同。
骨传导传感器180M可以获取振动信号。
按键190包括开机键,音量键等。按键190可以是机械按键。也可以是触摸式按键。电子设备100可以接收按键输入,产生与电子设备100的用户设置以及功能控制有关的键信号输入。
马达191可以产生振动提示。马达191可以用于来电振动提示,也可以用于触摸振动反馈。
指示器192可以是指示灯,可以用于指示充电状态,电量变化,也可以用于指示消息,未接来电,通知等。
SIM卡接口195用于连接SIM卡。SIM卡可以通过插入SIM卡接口195,或从SIM卡接口195拔出,实现和电子设备100的接触和分离。电子设备100可以支持1个或N个SIM卡接口,N为大于1的正整数。SIM卡接口195可以支持Nano SIM卡,Micro SIM卡,SIM卡等。同一个SIM卡接口195可以同时插入多张卡。所述多张卡的类型可以相同,也可以不同。SIM卡接口195也可以兼容不同类型的SIM卡。SIM卡接口195也可以兼容外部存储卡。电子设备100通过SIM卡和网络交互,实现通话以及数据通信等功能。在一些实施例中,电子设备100采用eSIM,即:嵌入式SIM卡。eSIM卡可以嵌在电子设备100中,不能和电子设备100分离。
电子设备200可以是手机、平板电脑、笔记本电脑、电视、智慧屏、超级移动个人计算机(ultra-mobile personal computer,UMPC)、上网本、个人数字助理(personaldigital assistant,PDA)等等具有显示屏的设备。本申请实施例对电子设备200的具体类型不作限定。
电子设备200的结构示意图可以参考图2所示电子设备100的结构示意图,这里不再赘述。
电子设备100的软件系统可以采用分层架构,事件驱动架构,微核架构,微服务架构,或云架构。本申请实施例以分层架构的Android系统为例,示例性说明电子设备100的软件结构。
图3示例性示出了本申请实施例提供的电子设备100的另一种结构示意图。
电子设备100可以具有如图3所示的软件结构和硬件设备。其中,分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,Android系统可分为四层,从上至下分别为应用程序层,应用程序框架层,安卓运行时(Android runtime)和系统库,以及内核层。
应用程序层可以包括一系列应用程序包。
如图3所示,应用程序包可以包括相机,图库,日历,通话,地图,导航,WLAN,蓝牙,视频,游戏A,应用A等应用程序。
电子设备100在运行游戏A应用时可以显示如图1所示的用户界面。
应用A可以为其它应用(如游戏A应用)提供相应的辅助服务。例如,在与应用A关联的应用运行的过程中,用户可以通过应用A快速开启消息免打扰、游戏加速、地图投屏等服务。
应用程序框架层为应用程序层的应用程序提供应用编程接口(application programming interface,API)和编程框架。应用程序框架层包括一些预先定义的函数。
如图3所示,应用程序框架层可以包括窗口管理器,内容提供器,电话管理器,资源管理器,通知管理器,视图系统,游戏A游戏引擎等。
窗口管理器可用于管理窗口程序。窗口管理器可以获取显示屏大小,判断是否有状态栏,锁定屏幕,截取屏幕等。
内容提供器可用来存放和获取数据,并使这些数据可以被应用程序访问。所述数据可以包括视频,图像,音频,拨打和接听的电话,浏览历史和书签,电话簿等。
视图系统可包括可视控件,例如显示文字的控件,显示图片的控件等。视图系统可用于构建应用程序。显示界面可以由一个或多个视图组成的。例如,包括短信通知图标的显示界面,可以包括显示文字的视图以及显示图片的视图。
电话管理器可用于提供电子设备100的通信功能。例如通话状态的管理(包括接通,挂断等)。
资源管理器可为应用程序提供各种资源,比如本地化字符串,图标,图片,布局文件,视频文件等等。
通知管理器可使应用程序可以在状态栏中显示通知信息,可以用于传达告知类型的消息,可以短暂停留后自动消失,无需用户交互。比如通知管理器被用于告知下载完成,消息提醒等。通知管理器还可以是以图表或者滚动条文本形式出现在系统顶部状态栏的通知,例如后台运行的应用程序的通知,还可以是以对话窗口形式出现在屏幕上的通知。例如在状态栏提示文本信息,发出提示音,电子设备振动,指示灯闪烁等。
游戏A游戏引擎可用于实现游戏A应用的用户界面的渲染。其中,游戏A游戏引擎可以获取用于绘制游戏A应用的用户界面的参数,并调用系统库中三维图形处理库,来实现用户界面的渲染。游戏A游戏引擎还可用于处理玩家与电子设备100之间的沟通,例如来自显示屏、键盘、鼠标等部件的信号。即当用户对游戏A应用程序进行操作,游戏A游戏引擎可以执行相关指令,使得电子设备100可以给出与用户的操作对应的反馈。
Android Runtime包括核心库和虚拟机。Android runtime负责安卓系统的调度和管理。
核心库包含两部分:一部分是java语言需要调用的功能函数,另一部分是安卓的核心库。
应用程序层和应用程序框架层运行在虚拟机中。虚拟机将应用程序层和应用程序框架层的java文件执行为二进制文件。虚拟机用于执行对象生命周期的管理,堆栈管理,线程管理,安全和异常的管理,以及垃圾回收等功能。
系统库可以包括多个功能模块。例如:表面管理器(surface manager),媒体库(Media Libraries),三维(3dimension,3D)图形处理库,二维(2dimension,2D)图形引擎等。
表面管理器可用于对显示子系统进行管理,并且为多个应用程序提供了2D和3D图层的融合。
媒体库可支持多种常用的音频,视频格式回放和录制,以及静态图像文件等。媒体库可以支持多种音视频编码格式,例如:MPEG4,H.264,H.265,MP3,AMR,JPG,PNG等。
3D图形处理库可用于实现三维图形绘图,图像渲染,合成,和图层处理等。3D图形处理库可包括OpenGL,OpenGL ES,OpenCV,Vulkan等等。
2D图形引擎是二维绘图的绘图引擎。2D图形引擎可以例如是SGL等。
内核层是硬件设备和软件之间的层。内核层至少包含显示驱动,摄像头驱动,GPU驱动,音频驱动,传感器驱动。电子设备100可以通过内核层驱动硬件设备实现对应的功能。例如,上述GPU驱动中可包括中央处理器(central processing unit,CPU)执行的使得GPU工作的指令。即CPU可以执行GPU驱动中的指令,使得GPU进行数学和几何计算。进而,显示屏可以根据GPU的计算结果显示图像。
电子设备100的硬件设备可包括显示屏、摄像头、传感器等等。电子设备100的硬件设备具体可以参考对上述图2的介绍。
下面结合在显示屏上显示游戏A应用的游戏界面的场景,示例性说明电子设备100软件以及硬件设备的工作流程。
当触摸传感器180K接收到触摸操作,相应的硬件终端被发给内核层。内核层将触摸操作加工成原始输入事件(包括触摸坐标,触摸操作的时间戳等信息)。原始输入事件被存储在内核层。应用程序框架层从内核层获取原始输入事件,识别该输入事件所对应的控件。以该触摸操作是触摸单击操作,该单击操作所对应的控件为游戏A应用图标的控件为例,游戏A应用可以调用应用程序框架层的接口,例如游戏A游戏引擎。游戏A游戏引擎可以获取用于绘制游戏A应用中游戏界面的参数,并调用系统库中的三维图形处理库(如OpenGL ES),从而得到用于绘制游戏界面的图形指令流。OpenGL ES是一种应用计算机图形程序接口(application programming interface,API)。OpenGL ES中包括多种功能函数/应用程序编程接口。游戏A游戏引擎调用OpenGL ES具体可以表示游戏A游戏引擎对指令中的参数赋值。上述指令中的参数可以是用于绘制游戏界面的参数。例如,图1所示地图区域210B的大小、建筑的尺寸、玩家角色的大小等等。这些参数的取值可以是游戏引擎从本地的游戏A应用程序包或者是从游戏服务器中获取到的。
进一步的,电子设备100可以将用于绘制游戏界面的图形指令流传递至GPU驱动。GPU 驱动可以将上述图形指令流中的指令转换成底层程序,并驱动GPU执行上述底层程序。上述底层程序为GPU可执行的程序(如机器码)。GPU执行上述底层程序,可以得到游戏界面的图像数据。GPU可以与显示屏连接,并将游戏界面的图像数据传递至显示屏。显示屏可以显示游戏A应用的游戏界面。
图4示例性示出了本申请实施例提供的一种投屏系统。
如图4所示,该投屏系统可包括电子设备100和电子设备200。电子设备100和电子设备200的结构可以参考前述实施例的介绍。其中,电子设备100与电子设备200之间建立有通信连接。通过该通信连接,电子设备100可以将需要投屏的内容发送给电子设备200。示例性的,电子设备100和电子设备200可以处于同一局域网(如同一家庭Wi-Fi)中。响应于用于投屏的用户操作,电子设备100可以搜索与自己处于同一局域网的电子设备。当接收到指示电子设备200为投屏设备的指令,电子设备100可以与电子设备200建立上述通信连接。电子设备200可以显示来自电子设备100需要投屏的内容。本申请实施例对电子设备100和电子设备200建立通信连接的方法不作限定。
在发送需要投屏的内容时,电子设备100和电子设备200之间可以利用现有技术中的投屏协议(如Miracast、DLNA、AirPlay等等)。或者,传输需要投屏的内容时所采用的协议还可以是电子设备100和电子设备200之间约定的私有协议。本申请实施例对电子设备100和电子设备200之间传输数据采用的投屏协议不作限定。
下面以游戏应用为例,说明游戏应用与应用A关联的过程。
图5A~图5D示例性示出了游戏应用与应用A关联的场景示意图。
如图5A所示,电子设备100可以显示用户界面410。用户界面410显示了一个放置有应用图标的页面,该页面可包括多个应用图标(例如,视频通话应用A图标、直播应用A图标、微信应用
Figure PCTCN2022083338-appb-000001
运动健康应用图标、游戏B应用图标、游戏C应用图标、游戏A应用图标412、应用A图标411等等)。上述多个应用图标下方还可显示有页面指示符,以表明当前显示的页面与其他页面的位置关系。页面指示符的下方有多个托盘图标(例如,相机应用图标、联系人应用图标、拨号应用图标、信息应用图标)。托盘图标在页面切换时保持显示。本申请实施例对用户界面410上显示的内容不作限定。
响应于作用在应用A图标411的用户操作,电子设备100可以启动应用A,并显示如图5B所示的用户界面420。用户界面420可包括关联应用显示区421、添加控件422、返回控件423和标题栏424。其中:
返回控件423可用于指示电子设备100返回用户界面420的上一级用户界面。例如,响应于作用在返回控件423的用户操作,电子设备100可以退出应用A,并显示如图5A所示的用户界面410。
标题栏424可用于指示用户界面420显示的内容。标题栏424的表现形式可以为文本信息“应用A”、图标或其他形式。
关联应用显示区421中包括一个或多个与应用A关联的应用图标。例如,微信应用图标、游戏B应用图标、游戏C应用图标。上述已经与应用A关联的应用为电子设备100已经安装的应用。当一个应用与应用A关联,这一个应用在运行的过程中,应用A图标可以悬浮显示在这一个应用的用户界面上,或者显示在可被调出和隐藏的侧边应用栏中。这样,用户在使用这一个应用时,可以快速调用应用A可提供的辅助服务。不限于上述悬浮图标、侧边应用 栏,电子设备100还可以通过其它形式为用户提供调用应用A可提供的辅助服务的入口。
上述辅助服务可包括但不限于以下服务:消息免打扰、截屏、录屏、游戏加速、地图投屏。其中:
消息免打扰可用于在调用这项服务的应用运行时,不在该应用的用户界面上显示其它应用(如微信应用、信息应用、拨号应用等)的消息通知。在一种可能的实现方式中,当调用上述消息免打扰服务,电子设备100可以通过通知管理器管理各应用的消息通知,使得各应用的消息通知不显示在用户界面上。
截屏可用于在调用这项服务的应用运行时,截取该应用的用户界面并保存为图片。
录屏可用于在调用这项服务的应用运行时,将从开始录屏到结束录屏得到的多帧图像保存为视频。
游戏加速可以是应用A为游戏应用提供的辅助服务。当游戏应用调用游戏加速的服务,电子设备100可以在游戏应用运行时采用偏向性能的系统参数。例如将更多的计算资源和存储资源分配给游戏应用、使用WLAN网络和移动数据进行网络加速等等,以提升游戏性能。
地图投屏也可以是应用A为游戏应用提供的辅助服务。在一些实施例中,安装有应用A的电子设备100中存储有与游戏应用对应的目标指令库。该目标指令库中可包括用于绘制该游戏应用中地图的指令和参数。在另一些实施例中,当应用A与游戏应用关联,电子设备100可以从云服务器获取该游戏应用对应的目标指令库。当游戏应用调用地图投屏的服务,电子设备100可以利用本申请实施例提供的显示方法将该游戏应用中的地图交由电子设备200显示。
不限于是上述为游戏应用提供的地图投屏服务,应用A还可以利用本申请实施例提供的显示方法为其他类型的应用(如直播类应用、视频通话类应用等)提供应用内投屏服务。例如,一个视频通话应用在运行过程中,用户界面可包括己方图像显示区域和对方图像显示区域。其中,己方和对方为进行视频通话的两方。上述对方图像显示区域可以以悬浮小窗的形式显示在用户界面上,并覆盖在己方图像显示区域上。当这一个视频通话应用调用应用内投屏服务,电子设备100可以利用本申请实施例提供的显示方法将这一个视频通话应用中对方图像显示区域的内容交由电子设备200显示。上述对方图像显示区域的内容是根据对方视频通话设备的摄像头采集的视频流得到的。在上述投屏过程中,电子设备100还可以将接收到的对方视频通话设备传输的视频流发送给电子设备200。
添加控件422可用于添加与应用A关联的应用。响应于作用在添加控件422的用户操作,电子设备100可以显示如图5C所示的用户界面430。
如图5C所示,用户界面430可包括返回控件433、标题栏434、游戏A应用图标431、关联控件432。
返回控件433可用于指示电子设备100返回用户界面430的上一级用户界面。例如,响应于作用在返回控件433的用户操作,电子设备100可以显示如图5B所示的用户界面420。
标题栏434可用于指示用户界面为电子设备100关联应用A与其它应用的界面。标题栏434的表现形式可以为文本信息“添加”、图标或其他形式。
关联控件432可用于关联游戏A应用与应用A。响应于作用在关联控件432的用户操作,电子设备100可以关联游戏A应用与应用A。
相比于图5B所示的关联应用显示区421,图5D所示用户界面420中关联应用显示区421包括游戏A应用图标。即游戏A应用已经与应用A关联。
用户界面430中还可以包括更多可与应用A关联的应用图标以及这些应用对应的关联控 件。例如,直播应用A图标、视频通话应用A图标、音乐应用图标、运动健康应用图标。这些应用图标对应的应用均为电子设备100已经安装的应用。
上述图5A~图5D所示的用户界面仅为示例性说明,不应对本申请构成限定。
在一些实施例中,电子设备100可以将特定类型的应用自动与应用A关联。上述特定类型的应用可以例如是游戏应用、直播类应用、视频通话类应用等类型的应用。具体的,电子设备100可以获取自己已安装的应用的类型。例如,应用的程序安装包中包含应用类型的标识。根据上述应用类型的标识,电子设备100可以从自己已安装的应用中筛选出上述特定类型的应用,并自动将上述特定类型的应用与应用A关联。本申请实施例对电子设备获取应用的类型的方法不作限定。
也即是说,用户可以不用进行图5A~图5D所示手动关联应用A与其它应用的操作。当电子设备100安装上述特定类型的应用,电子设备100可以自动将上述被安装的特定类型的应用与应用A关联。
基于前述图5A~图5D所示游戏A应用与应用A关联,下面结合投屏游戏A应用中地图的场景为例介绍本申请实施例提供的显示方法。
图6A~图6F示例性示出了电子设备100将游戏A应用的地图投屏至电子设备200的场景示意图。
如图6A所示,响应于作用在用户界面410中游戏A应用图标412的用户操作,电子设备100可以启动游戏A应用,并显示如图6B所示的游戏界面510。游戏界面510可包括游戏场景区域510A和地图区域510B。游戏场景区域510A和地图区域510B分别可以参考前述图1所示的游戏场景区域210A和地图区域210B。这里不再赘述。
如图6B所示,响应于作用在电子设备100屏幕上方左侧(或右侧)边缘向内滑动的用户操作,电子设备100可以调出图6C所示的侧边应用栏511。侧边应用栏511中可包括应用助手快捷键511A。应用助手快捷键511A可用于用户快速调用应用A为游戏A应用提供的辅助服务。
如图6C所示,响应于作用在应用助手快捷键511A的用户操作,电子设备100可以显示图6D所示的服务显示区512。服务显示区512中可包括一个或多个应用A可为游戏A应用提供的辅助服务控件。例如,消息免打扰控件512A、截屏控件512B、录屏控件512C、游戏加速控件512D、地图投屏控件512E、全部服务控件512F。响应于作用在这些控件上的用户操作,电子设备100可以调用这些控件各自对应的服务。这些控件各自对应的服务可以参考前述实施例的说明,这里不再赘述。
如图6D所示,响应于作用在地图投屏控件512E的用户操作,电子设备100可以搜索附近可用于投屏的电子设备,并显示图6E所示的投屏设备选项框513。上述可用于投屏的电子设备可以为与电子设备100在同一局域网(如同一家庭Wi-Fi),且具有显示屏的电子设备。本申请实施例对电子设备100搜索附近可用于投屏的电子设备的方法不作限定。
如图6E所示,投屏设备选项框513中可包括提示语513A、可用设备列表513B和设备搜索控件513C。其中:
提示语513A可用于提示用户上述地图投屏服务的作用。提示语513A可以为文字信息“请选择投屏设备”。本申请实施例对提示语513A的具体内容不作限定。
设备搜索控件513C可用于触发电子设备100搜索附近可用于投屏的电子设备。设备搜 索控件513C上可包括文字提示“查找更多设备”。本申请实施例对设备搜索控件513上的文字提示不作限定。
可用设备列表513B可用于显示电子设备100搜索到的可用于投屏的电子设备选项。例如,电子设备200选项和电子设备300选项。示例性的,响应于作用在电子设备200选项的用户操作,电子设备100可以请求与电子设备200建立通信连接
当接收到电子设备100请求建立通信连接的请求,电子设备200可以与电子设备100建立通信连接。
电子设备100可以根据目标指令库从游戏界面510的图形指令流中截取地图指令流。电子设备100可以根据指令流截取操作之后余下的指令流,例如游戏场景指令流,在本地显示游戏场景区域510A。
如图6F所示,当调用地图投屏服务,电子设备100可以在游戏界面显示游戏场景区域510A。可看出,游戏场景区域510A的内容没有被上述地图区域510B遮挡。用户在游戏过程中可以查看到更大视野范围的内容,具有更好的游戏体验。
电子设备100可以将上述地图指令流发送给电子设备200,或者将对上述地图指令流进行渲染以及编码得到的视频流发送给电子设备200。电子设备200可以显示如图6F所示的用户界面530。用户界面530中可包括图6B所示地图区域510B中呈现的地图。
在一种可能的实现方式中,电子设备100将上述地图指令流发送给电子设备200。电子设备200可以根据电子设备100屏幕分辨率和电子设备200屏幕分辨率的比例,来缩放上述地图指令流中的参数。这样,地图区域510B中地图的大小可以与电子设备200屏幕的大小适配。
在另一种可能的实现方式中,电子设备100将对上述地图指令流进行渲染以及编码得到的视频流发送给电子设备200。电子设备200可以根据电子设备100屏幕分辨率和电子设备200屏幕分辨率的比例,对视频流中各帧图像进行缩放。这样,地图区域510B中地图的大小可以与电子设备200屏幕的大小适配。
在一些实施例中,当运行与应用A关联的应用(如游戏A应用),电子设备100可以运行应用A,调用应用A可以提供的辅助服务(如地图投屏服务)。即用户可以不用进行如图6B~图6D所示用于调用地图投屏服务的用户操作。这可以简化上述地图投屏过程中的用户操作。
由图6A~图6F所示的实施例可以看出,游戏A应用中游戏场景区域510A的内容可以在电子设备100显示。游戏A应用中地图区域510B的内容可以投屏至电子设备200,由电子设备200显示。这样,用户在玩游戏A的过程中,可以在电子设备100上进行游戏操控,并在电子设备200上查看地图。其中,用户在电子设备100上进行游戏操控时所能观看到的视野不再受到地图区域510B的遮挡,可以获得更好的游戏体验。
图7A和图7B示例性示出了另一种投屏后电子设备100和电子设备200的用户界面示意图。
在一些实施例中,当调用上述地图投屏服务,电子设备100可以显示如图7A所示的游戏界面610。游戏界面610可包括游戏场景区域610A和地图标识区域610B。其中,游戏场景区域610A可以参考前述图1中游戏场景区域210A的介绍,这里不再赘述。地图标识区域610B可用于标识投屏前图6A所示地图区域510B所在的位置。地图标识区域610B可以覆盖 在游戏场景区域610A上。地图标识区域610B的大小以及在游戏界面610中的位置可以与图6A中地图区域510B的大小以及在游戏界面510中的位置相同。与地图区域510B中的内容不同的是,地图标识区域610B中的内容可以为图7A所示纯色且具有一定透明度的图层。上述纯色且具有一定透明度的图层不会完全遮挡游戏场景区域610A中被地图标识区域610B覆盖的部分。
可选的,地图标识区域610B中的内容可以为与地图区域510B大小相同的边框。
上述用于绘制地图标识区域610B的内容的指令可以是从目标指令库中获取的。也即是说,除了包括用于绘制地图区域510B的内容的地图指令流,目标指令库中还包括用于绘制地图标识区域610B的内容的地图标识指令流。当接收到调用地图投屏服务的用户操作,电子设备100可以从用于绘制游戏界面510(即投屏前的游戏界面)的图形指令流中截取上述地图指令流。电子设备100可以根据指令流截取操作之后余下的指令流(如游戏场景指令流),以及从目标指令库中获取的地图标识指令流在本地显示如图7A所示的游戏界面610。
在一种可能的实现方式中,用于绘制地区标识区域610B的内容的指令可以是电子设备100生成的。其中,电子设备100可以根据地图指令流生成上述地图标识指令流。例如,地图标识区域610B的大小和位置分别与地图区域510B的大小和位置相同。地图标识指令流中的指令和参数的取值可以由地图指令流中的指令和参数的取值确定。
本申请实施例对上述地图标识区域610B中显示的内容的具体形式不作限定。
在一些实施例中,如图6B所示,电子设备100可以对作用在游戏界面510中地图区域510B的用户操作进行对应的响应。例如,响应于作用在地图区域510B中向右滑动的用户操作,电子设备100可以调整地图区域510B中显示的地图。其中,地图区域510B中显示的地图向右移动。地图向右移动的量可以由上述用户操作中向右滑动的量确定。经过上述移动之后,地图区域510B可显示与上述移动之前地图左侧边缘连接但未显示出来的地图。地图向右移动移出地图区域510B的部分被隐藏。即用户可以在地图区域510B中向各个方向滑动调整显示在地图区域510B中的地图,来查看地图的不同区域。
当调用上述地图投屏服务,电子设备100可以对作用在游戏界面610中地图标识区域610B的用户操作进行对应的响应。如图7A所示,响应于作用在地图标识区域610B中向右滑动的用户操作,电子设备100可以获取到用于绘制地图向右移动后图6B所示地图区域510B中可显示的地图的地图指令流。
如图7B所示,根据上述地图指令流,电子设备200可以在用户界面610显示上述向右移动后的地图。地图向右移动的量可以由上述用户操作中向右滑动的量确定。
电子设备100接收到作用在地图标识区域610B中向右滑动的用户操作之前,电子设备100投屏至电子设备200的地图可以参考图6F所示的地图。电子设备100接收到作用在地图标识区域610B中向右滑动的用户操作之后,电子设备100投屏至电子设备200的地图可以参考图7B所示的地图。比较图6F和图7B可知,经过上述移动之后,用户界面620可显示与用户界面530中地图左侧边缘连接但未显示在用户界面530的地图。地图向右移动移出用户界面530中地图右侧边缘的部分被隐藏。其中,地图向右移动的量可以由上述用户操作中向右滑动的量确定。
也即是说,在调用上述地图投屏服务之后,作用在原先显示地图区域510B的用户操作仍然有效。响应于作用在地图标识区域610B(原先显示地图区域510B)的用户操作,电子设备100可以调整应该显示在地图区域510B中的地图。而上述应该显示在地图区域510B中的地图被投屏至电子设备200。那么电子设备200中显示的地图也随之调整。这样,在调用 上述地图投屏服务之后,用户仍可在地图标识区域610B中进行相应的用户操作。例如,用户可以在地图标识区域610B中向各个方向滑动调整显示在用户界面620中的地图,来查看地图的不同区域。本申请实施例对上述作用在地图标识区域610B(或地图区域510B)的用户操作不作限定。
另外,由于上述地图标识区域610B中显示的内容可以为纯色且具有一定透明度的图层(或与地图区域510B大小相同的边框),地图标识区域610B不会完全遮挡游戏场景区域610A中被地图标识区域610B覆盖的部分。相比于投屏之前的游戏界面510,用户在电子设备100上进行游戏操控时可以观看到更大视野范围的内容,可以获得更好的游戏体验。
图8A和图8B示例性示出了电子设备100结束地图投屏服务的场景示意图。
如图8A所示,电子设备100已调用地图投屏服务,并在游戏界面显示游戏场景区域510A中的内容。利用图6A和图6B所示的用户操作,电子设备100可以显示服务显示区512。响应于作用在地图投屏控件512E的用户操作,电子设备100可以结束地图投屏服务。
如图8B所示,响应于作用在地图投屏控件512E的用户操作,电子设备100可以显示服务结束提示框531。服务结束提示框531可包括文字提示语“确认结束地图投屏?”,以询问用户是否结束地图投屏服务。本申请实施例对上述文字提示语的具体内容不作限定。服务结束提示框531还可包括确认控件531A和取消控件531B。其中,确认控件531A可用于触发电子设备100结束地图投屏服务。取消控件531B可用于指示电子设备100继续将地图投屏至电子设备200。
响应于作用在确认控件531A的用户操作,电子设备100可以显示图6B所示的游戏界面510。游戏界面510可包括游戏场景区域510A和地图区域510B。其中,地图区域510B覆盖在游戏场景区域510A上,并遮挡一部分游戏场景区域510A中的内容。
当结束地图投屏服务,电子设备100可以停止利用目标指令库从用于绘制游戏界面510中的图形指令流中截取地图指令流。即电子设备100可以根据用于绘制游戏界面510中的图形指令流,在本地显示如图6B所示的用户界面510。
本申请实施例对用于结束上述地图投屏服务的用户操作不作限定。
基于上述调用地图投屏服务的场景,下面介绍本申请实施例提供的一种投屏系统的结构示意图。
如图9所示,投屏系统800可包括电子设备100和电子设备200。电子设备100可包括投屏服务调用模块810、游戏A应用820、投屏模块830、指令截取模块840、GPU驱动850、GPU860、显示屏870、图像转换模块880、第一存储模块890。电子设备200可包括投屏模块8100、视频播放模块8110。
在未接收到调用地图投屏服务的用户操作之前,电子设备100可以利用游戏A应用820、指令截取模块840、GPU驱动850和GPU860在显示屏870上显示游戏界面。其中,游戏A应用820中可包括游戏引擎821。游戏引擎821可以获取用于绘制游戏A应用中游戏界面的参数(如图6B所示地图区域510B的大小、建筑的尺寸、玩家角色的大小等等)。游戏引擎821可以调用3D图形处理库,得到用于绘制游戏界面的图形指令流。游戏引擎821可以将上述图形指令流传递至指令截取模块840。
指令截取模块840可以获取用于接收来自游戏引擎821的图形指令流的接口。游戏引擎821可以通过上述接收图形指令流的接口来传递图形指令流。那么指令截取模块840可以接 收到上述图形指令流。
在未接收到用于截取地图指令流的指令时,指令截取模块840可以直接将接收到的图形指令流传递至GPU驱动850。GPU驱动850可以将上述图形指令流中的指令转换成底层程序,并驱动GPU860执行上述底层程序。上述底层程序为GPU860可执行的程序(如机器码)。GPU860执行上述底层程序,可以得到游戏界面的图像数据,并将该游戏界面的图像数据传递至显示屏870。显示屏870可以显示游戏A的游戏界面(如图6B所示的游戏界面510)。
若电子设备100接收到用于调用地图投屏服务的用户操作,电子设备100和电子设备200可以根据图9所示的投屏系统分别显示图6B所示游戏场景区域510A中的内容、地图区域510B中的内容。
具体的,电子设备100可以运行游戏A应用820对应的应用程序。其中,电子设备100可以根据前述实施例所述的方法,利用游戏引擎821、指令截取模块840、GPU驱动850和GPU860在显示屏870上显示游戏界面。当检测到用于调用地图投屏服务的用户操作,投屏服务调用模块810可以向指令截取模块840发送截取地图指令流的指令,并向投屏模块830发送开启投屏功能的指令。上述用于调用地图投屏服务的用户操作可以例如是前述图6D所示作用在地图投屏控件512E上的触摸操作。
在一些实施例中,当电子设备100检测到上述用于调用地图投屏服务的用户操作,电子设备100和电子设备200可以建立通信连接,以传输需要投屏的数据。电子设备100和电子设备200之间可以利用现有技术中的投屏协议(如Miracast、DLNA、AirPlay等等)来传输需要投屏的数据。本申请实施例对电子设备100和电子设备200之间传输数据采用的投屏协议不作限定。可选的,传输需要投屏的内容时所采用的协议还可以是电子设备100和电子设备200之间约定的私有协议。
示例性的,当投屏模块830接收到上述开启投屏功能的指令,电子设备100可以搜索与自己处于同一家庭Wi-Fi,且具有投屏功能的电子设备,并显示前述图6E所示的用户界面。
可选的,电子设备100和电子设备200之间的通信连接可以是在电子设备100检测到上述用于调用地图投屏服务的用户操作之前建立的。
当接收到上述截取地图指令流的指令,指令截取模块840可以利用目标指令库从用于绘制游戏界面的图形指令流中截取地图指令流。其中,上述用于绘制游戏界面的图形指令流为游戏引擎821发送的。该图形指令流中可包括地图指令流和游戏场景指令流。指令截取模块840截取地图指令流的方法具体可以为:指令截取模块840获取与游戏A应用对应的目标指令库。该与游戏A应用对应的目标指令库中包括用于绘制游戏A用户界面中地图区域(如图6B所示的地图区域510B)的指令。指令截取模块840可以从接收到的图形指令流中确定出与目标指令库匹配的指令,并进行截取操作。这样,指令截取模块840可以区别图形指令流中的地图指令流和游戏场景指令流。
经过上述图形指令流的截取,指令截取模块840可以将游戏场景指令流传递给GPU驱动850,并将地图指令流传递给图像转换模块860。
当接收到上述游戏场景指令流,GPU驱动850可以将游戏场景指令流中的指令转换为游戏场景底层程序,并驱动GPU860执行上述游戏场景底层程序。上述游戏场景底层程序为GPU860可执行的程序(如机器码)。GPU860可以执行上述游戏场景底层程序得到游戏场景图像数据,并将游戏场景图像数据传递至显示屏870。显示屏870可以显示游戏场景区域中的内容(如图6F所示的游戏场景区域510A)。
当接收到上述地图指令流,图像转换模块880可以将地图指令流传递至GPU驱动850。 另外,图像转换模块880还可以获取第一存储模块890的地址,并将该第一存储模块890的地址传递给GPU驱动850。GPU驱动850可以将地图指令流中的指令转换为地图底层程序,并驱动GPU860执行上述地图底层程序。GPU驱动850可以指示GPU860将执行上述地图底层程序得到的数据存储至第一存储模块890。上述地图底层程序为GPU860可执行的程序(如机器码)。GPU860可以执行上述地图底层程序,得到地图图像数据。根据第一存储模块890的地址,GPU860可以将上述地图图像数据存储至第一存储模块890。上述GPU可以并行处理游戏场景底层程序和地图底层程序。
图像转换模块880可以从第一存储模块890中获取上述地图图像数据,并将上述地图图像数据转换为第一视频流。其中,图像转换模块880可以利用H.264或者H.265等等编码方式对图像进行编码,将图像转换为视频流。本申请实施例对图像转换模块880进行编码的方法不作限定。
在一些实施例中,图像转换模块880可以将每连续k帧图像进行编码转换为视频流,并将包含这k帧图像的视频流传递给投屏模块830。即电子设备100每得到k帧地图的图像,可以将包含这k帧地图的图像的数据发送给电子设备200。电子设备200可以显示这k帧图像的图像。图6B所示地图区域510B中的内容可能随游戏场景区域510A中的内容变化而变化。上述k的取值不宜过大,否则电子设备100上显示的内容与电子设备200上显示的内容可能不同步。上述k的取值可以根据经验值设定。本申请实施例对k的取值不作限定。上述方法可以降低游戏A应用820一个游戏界面上的两部分显示内容分别显示在电子设备100和电子设备200上的时延,减少电子设备100上显示的内容与电子设备200上显示的内容不同步的情况。
图像转换模块880可以将第一视频流传递给投屏模块830。
投屏模块830可以基于电子设备100和电子设备200之间采用的投屏协议对第一视频流进行编码,并将经过编码的第一视频流发送给电子设备200。
电子设备200中的投屏模块8100可以接收到上述经过编码的第一视频流。投屏模块8100可以基于电子设备100和电子设备200之间采用的投屏协议对上述经过编码的第一视频流进行解码,得到第一视频流。投屏模块8100可以将第一视频流传递给视频播放模块8110。
视频播放模块8110可用于播放第一视频流中包含的图像。这样,原本显示在电子设备100游戏界面510中地图区域510B的内容被投屏至电子设备200(参考图6F所示的用户界面530)。经过上述投屏处理后,电子设备100可以不再显示图6B所示地图区域510B的内容。
在一些实施例中,电子设备200可以获取电子设备100的屏幕分辨率。根据电子设备100屏幕分辨率和电子设备200屏幕分辨率的比例,电子设备200可以对第一视频流中各帧图像进行缩放。这样,地图区域510B中地图的大小可以与电子设备200屏幕的大小适配。
在一些实施例中,上述投屏服务调用模块810、指令截取模块840和图像转换模块880均可以是前述实施例中应用A中的模块。即安装有应用A的电子100中可以利用上述投屏服务调用模块810、指令截取模块840和图像转换模块880来实现本申请实施例提供的显示方法。
由图9所示的投屏系统800可知,游戏A应用中游戏场景区域510A的内容可以在电子设备100显示。游戏A应用中地图区域510B的内容可以投屏至电子设备200,由电子设备200显示。这样,用户在玩游戏A的过程中,可以在电子设备100上进行游戏操控,并在电子设备200上查看地图。其中,用户在电子设备100上进行游戏操控时所能观看到的视野不 再受到地图区域510B的遮挡,可以获得更好的游戏体验。
并且,电子设备100可以借助应用A实现上述显示方法。即需要进行投屏的应用无需修改。那么在第三方应用的开发者不对应用进行适应性修改的情况下,电子设备100可以将这些第三方应用中一个用户界面上的部分显示内容投屏至其他设备。这有利于本申请提供的显示方法适用于游戏应用、直播类应用、视频通话类应用等多种类型的应用。
在一些实施例中,与上述游戏A应用820对应的目标指令库中还包括地图标识指令流。上述地图标识指令流可用于绘制图7A所示地图标识区域610B的内容。例如,地图标识区域610B的内容可以是纯色且具有一定透明度的图层。地图标识区域610B可以参考前述实施例的介绍,这里不再赘述。上述地图标识指令流可以是根据地图指令流确定。例如,地图标识指令流中与地图标识区域610B的大小、在游戏界面610中的位置对应的指令以及参数,和地图指令流中与地图区域510B的大小、在游戏界面510中的位置对应的指令以及参数相同。指令截取模块840可以从目标指令库中获取上述地图标识指令流,并将该地图标识指令流与游戏场景指令流合并。其中,地图标识指令流可以替代用于绘制游戏界面510的图形指令流中的地图指令流,实现与游戏场景指令流的合并。
指令截取模块840可以将合并后的地图标识指令流和游戏场景指令流传递给GPU驱动850。根据上述游戏场景指令流和上述地图标识指令流,电子设备100可以显示如图7A所示的游戏界面610。
当游戏A应用820接收到作用在图7A所示地图标识区域610B(即投屏前图6B所示显示有地图区域510B)的用户操作,可显示在地图区域510B中的地图会响应于上述用户操作而被调整。游戏引擎821可以获取上述地图调整后的参数(如地图中元素的特征等等),并调用3D图形处理库,得到图形指令流。该图形指令流中包括用于绘制调整后的地图的指令流。其中,游戏引擎821在调用3D图形处理库时可以对指令中的参数赋值。上述指令中的参数可以包括上述地图调整后的参数。
进一步的,指令截取模块840可以从上述图形指令流中截取地图指令流。该地图指令流可用于绘制响应于上述用户操作而被调整的地图。电子设备100将被投屏的数据(即由上述地图指令流转换得到的视频流)传输给电子设备200。电子设备200可以显示上述被调整的地图。
在另一些实施例中,当调用地图投屏服务,电子设备100可以根据指令流截取操作之后余下的指令流在本地显示屏进行渲染,显示如图6F所示游戏场景区域510A的内容。其中,当检测到作用在原先显示有地图区域510B的用户操作,电子设备100仍可进行相应的响应。上述响应的结果可以呈现在电子设备200的用户界面上。
由上述实施例可以看出,在调用上述地图投屏服务之后,作用在原先显示有地图区域510B的用户操作仍然有效。例如,用户可以在地图标识区域610B中向各个方向滑动调整显示在用户界面620中的地图,来查看地图的不同区域。另外,由于上述地图标识区域610B中显示的内容可以为纯色且具有一定透明度的图层(或与地图区域510B大小相同的边框),地图标识区域610B不会完全遮挡游戏场景区域610A中被地图标识区域610B覆盖的部分。相比于投屏之前的游戏界面510,用户在电子设备100上进行游戏操控时可以观看到更大视野范围的内容,可以获得更好的游戏体验。
下面以游戏引擎821调用的3D图形处理库为OpenGL ES为例,对目标指令库中的指令 进行示例性介绍。
glTexImage2D(GL_TEXTURE_2D,0,GL_RGB,width,height,0,GL_RGB,GL_UNSIGNED_BYTE,data)。
指令glTexImage2D可用于生成一个二维图像。其中,指令glTexImage2D中的第一个参数可以指定图像的类型。“GL_TEXTURE_2D”可以表示图像的类型为二维图像。指令glTexImage2D中的第二个参数可以指定图像加载的层次。该第二个参数为0可以表示没有进行缩小的原始图片等级。指令glTexImage2D中的第三个参数可以指定图像的内部格式。上述内部格式可以表示是图像的像素在显卡中存储的格式。“GL_RGB”可以表示图像中像素的颜色值是以RGB的格式存储的。指令glTexImage2D中的第四个参数和第五个参数可分别指定图像的宽和高。指令glTexImage2D中的第六个参数可以指定图像的边界宽度。该第六个参数为0可以表示图像的边界宽度为0。指令glTexImage2D中的第七个参数可以指定图像的像素在内存中的存储格式。该第七个参数为“GL_RGB”可以表示图像中像素的颜色值在内存中是以RGB的格式存储的。指令glTexImage2D中的第八个参数可以指定图像的像素在内存中的数据类型。指令glTexImage2D中的第九个参数可以指定一个指向内存中图像数据存储位置的指针。
例如,图6B所示地图区域510B中的内容为二维图像。该二维图像可以是利用上述指令glTexImage2D生成的。目标指令库中可包含该指令以及该指令中与地图区域510B中的内容对应的参数。与目标指令库中指令的名称和指令中的参数进行匹配,电子设备100可以从用于绘制游戏界面的图形指令流中截取出地图指令流。
glDrawElements(GL_TRIANGLE,36,GL_UNSIGNED_SHORT,0)。
指令glDrawElements可用于绘制图元。图元是渲染的基本图形。图元由顶点组成的。一个顶点、一条线段、一个三角形或者多边形都可以成为图元。其中,指令glDrawElements中的第一个参数可以指定图元的类型。“GL_TRIANGLE”可以表示图元的类型为三角形。指令glDrawElements中的第二个参数为绘制图元的数量与一个图元顶点数的乘积。由于图元的类型为三角形,一个图元的顶点数为3。指令glDrawElements中的第二个参数为36可以表示绘制图元的数量为12个。指令glDrawElements中的第三个参数可以指定图元数据的数据类型。指令glDrawElements中的第四个参数可以指令一个指向内存中图元数据存储位置的指针。
例如,图6B所示地图区域510B中的内容可包括地图中玩家角色的位置标记。该位置标记可以是利用上述指令glDrawElements生成的。目标指令库中可包含该指令以及该指令中与上述位置标记对应的参数。与目标指令库中指令的名称和指令中的参数进行匹配,电子设备100可以从绘制游戏界面的图形指令流中截取出地图指令流。
在用于绘制游戏界面的图形指令流中,参数的具体取值可以是游戏引擎821从本地的游戏A应用程序包或者是从游戏服务器中获取到的。
上述指令glTexImage2D和上述指令glDrawElements仅为本申请实施例的示例性说明,不应对本申请构成限定。不限于上述示例性说明的指令,目标指令库中还可以包括更多的指令。不同的应用可对应有不同的目标指令库。电子设备100可以利用与一个应用对应的目标指令库,例如与游戏A应用820对应的目标指令库,截取出用于绘制地图区域510B的内容的地图指令流。
在一种可能的实现方式中,与一个应用对应的目标指令库可以是在获取绘制这一个应用中用户界面的图形指令流,并对该图形指令流进行分析得到的。其中,上述用户界面的图形指令流可以包括用于绘制第一显示内容的指令流A,以及用于绘制第二显示内容的指令流B。 上述第一显示内容覆盖在上述第二显示内容上,并部分遮挡第二显示内容。对上述用户界面的图形指令流进行分析可以是人工分析。例如,根据第二显示内容在上述用户界面中显示的特征(如第二显示内容的长、宽,第二显示内容中包含的元素等),确定出上述指令流A,并将指令流A保存为目标指令库。可选的,对上述用户界面的图形指令流进行分析可以机器执行的。其中,机器可以根据自己存储的指令流筛选规则从上述用户界面的图形指令流中确定出上述指令流A。上述指令流筛选规则可以是根据第二显示内容在上述用户界面中显示的特征确定的。本申请实施例对获取与一个应用对应的目标指令库的方法不作限定。
图10示例性示出了本申请实施例提供的另一种投屏系统的结构示意图。
如图10所示,投屏系统900可包括电子设备100和电子设备200。电子设备100可以包括投屏服务调用模块910、游戏A应用920、投屏模块930、指令截取模块940、GPU驱动950、GPU960和显示屏970。电子设备200可以包括投屏模块980、GPU驱动990、GPU9100和显示屏9110。
在未接收到调用地图投屏服务的用户操作之前,电子设备100可以利用游戏A应用920、指令截取模块940、GPU驱动950和GPU960在显示屏970上显示游戏界面。具体可以参考实施例中对电子设备100未接收到调用地图投屏服务的用户操作时在显示屏显示游戏界面的介绍。这里不再赘述。
若电子设备100接收到用于调用地图投屏服务的用户操作,电子设备100和电子设备200可以根据图10所示的投屏系统分别显示图6B所示游戏场景区域510A中的内容、地图区域510B中的内容。
具体的,电子设备100可以运行游戏A应用920对应的应用程序。其中,电子设备100可以根据前述实施例所述的方法,利用游戏引擎921、指令截取模块940、GPU驱动950和GPU960在显示屏970上显示游戏界面。当检测到用于调用地图投屏服务的用户操作,投屏服务调用模块910可以向指令截取模块940发送截取地图指令流的指令,并向投屏模块930发送开启投屏功能的指令。上述用于调用地图投屏服务的用户操作可以例如是前述图6D所示作用在地图投屏控件512E上的触摸操作。
需要投屏的数据可以通过电子设备100和电子设备200之间的通信连接进行传输。电子设备100和电子设备200之间建立通信连接的方法可以参考前述实施例。这里不再赘述。
当接收到上述截取地图指令流的指令,指令截取模块940可以利用目标指令库从用于绘制游戏界面的图形指令流中截取地图指令流。其中,上述用于绘制游戏界面的图形指令流为游戏引擎921发送的。该图形指令流中可包括地图指令流和游戏场景指令流。指令截取模块940截取地图指令流的方法具体可以为:指令截取模块940获取与游戏A应用对应的目标指令库。该与游戏A应用对应的目标指令库中包括用于绘制游戏A用户界面中地图区域(如图6B所示的地图区域510B)的指令。指令截取模块940可以从接收到的图形指令流中确定出与目标指令库匹配的指令,并进行截取操作。这样,指令截取模块940可以区别图形指令流中的地图指令流和游戏场景指令流。
经过上述图形指令流的截取,指令截取模块940可以将游戏场景指令流传递给GPU驱动950,并将地图指令流传递给投屏模块930。
当接收到上述游戏场景指令流,GPU驱动950可以将游戏场景指令流中的指令转换为游戏场景底层程序,并驱动GPU960执行上述游戏场景底层程序。上述游戏场景底层程序为GPU960可执行的程序(如机器码)。GPU960可以执行上述游戏场景底层程序中的指令得到 游戏场景图像数据,并将游戏场景图像数据传递至显示屏970。显示屏970可以显示游戏场景区域中的内容(如图6F所示的游戏场景区域510A)。
当接收到上述地图指令流,投屏模块930可以基于电子设备100和电子设备200之间采用的协议对地图指令流进行编码,并将经过编码的地图指令流发送给电子设备200。
电子设备200中的投屏模块980可以接收到上述经过编码的地图指令流。投屏模块980可以基于电子设备100和电子设备200之间采用的协议对上述经过编码的地图指令流进行解码,得到地图指令流。投屏模块980可以将地图指令流传递给GPU驱动990。GPU驱动990可以将地图指令流中的指令转换为地图底层程序,并驱动GPU9100执行上述地图底层程序。GPU9100可以执行上述地图底层程序,得到地图图像数据。GPU9100可以将地图图像数据传递至显示屏9110。电子设备200可以在显示屏9110上显示地图图像(参考图6F所示的用户界面530)。
也即是说,电子设备100可以将用于绘制地图区域510B中的内容的地图指令流发送给电子设备200。电子设备200可以运行该地图指令流,在显示屏上绘制地图区域510B中的内容。
在一些实施例中,电子设备200可以获取电子设备100的屏幕分辨率。根据电子设备100屏幕分辨率和电子设备200屏幕分辨率的比例,电子设备200可以缩放接收到的地图指令流中的参数。这样,地图区域510B中地图的大小可以与电子设备200屏幕的大小适配。
在一些实施例中,上述投屏服务调用模块910、指令截取模块940均可以是前述实施例中应用A中的模块。即安装有应用A的电子100中可以利用上述投屏服务调用模块910、指令截取模块940来实现本申请实施例提供的显示方法。
由图10所示的投屏系统900可知,图6B所示游戏A应用中游戏场景区域510A的内容可以在电子设备100显示。游戏A应用中地图区域510B的内容可以投屏至电子设备200,由电子设备200显示。这样,用户在玩游戏A的过程中,可以在电子设备100上进行游戏操控,并在电子设备200上查看地图。其中,用户在电子设备100上进行游戏操控时所能观看到的视野不再受到地图区域510B的遮挡,可以获得更好的游戏体验。
并且,电子设备100可以借助应用A实现上述显示方法。即需要进行投屏的应用无需修改。那么在第三方应用的开发者不对应用进行适应性修改的情况下,电子设备100可以将这些第三方应用中一个用户界面上的部分显示内容投屏至其他设备。这有利于本申请提供的显示方法适用于游戏应用、直播类应用、视频通话类应用等多种类型的应用。
在一些实施例中,与上述游戏A应用920对应的目标指令库中还包括地图标识指令流。上述地图标识指令流可用于绘制图7A所示地图标识区域610B的内容。例如,地图标识区域610B的内容可以是纯色且具有一定透明度的图层。地图标识区域610B可以参考前述实施例的介绍,这里不再赘述。上述地图标识指令流可以是根据地图指令流确定。例如,地图标识指令流中与地图标识区域610B的大小、在游戏界面610中的位置对应的指令以及参数,和地图指令流中与地图区域510B的大小、在游戏界面510中的位置对应的指令以及参数相同。指令截取模块940可以从目标指令库中获取上述地图标识指令流,并将该地图标识指令流与游戏场景指令流合并。其中,地图标识指令流可以替代用于绘制游戏界面510的图形指令流中的地图指令流,实现与游戏场景指令流的合并。
指令截取模块940可以将合并后的地图标识指令流和游戏场景指令流传递给GPU驱动 950。根据上述游戏场景指令流和上述地图标识指令流,电子设备100可以显示如图7A所示的游戏界面610。
当游戏A应用920接收到作用在图7A所示地图标识区域610B(即投屏前图6B所示显示有地图区域510B)的用户操作,可显示在地图区域510B中的地图会响应于上述用户操作而被调整。游戏引擎921可以获取上述地图调整后的参数(如地图中元素的特征等等),并调用3D图形处理库,得到图形指令流。该图形指令流中包括用于绘制调整后的地图的指令流。其中,游戏引擎921在调用3D图形处理库时可以对指令中的参数赋值。上述指令中的参数可以包括上述地图调整后的参数。
进一步的,指令截取模块940可以从上述图形指令流中截取地图指令流。该地图指令流可用于绘制响应于上述用户操作而被调整的地图。电子设备100将被投屏的数据(即上述地图指令流)传输给电子设备200。电子设备200可以显示上述被调整的地图。
在另一些实施例中,当调用地图投屏服务,电子设备100可以根据指令流截取操作之后余下的指令流在本地显示屏进行渲染,显示如图6F所示游戏场景区域510A的内容。其中,当检测到作用在原先显示有地图区域510B的用户操作,电子设备100仍可进行相应的响应。上述响应的结果可以呈现在电子设备200的用户界面上。
由上述实施例可以看出,在调用上述地图投屏服务之后,作用在原先显示地图区域510B的用户操作仍然有效。例如,用户可以在地图标识区域610B中向各个方向滑动调整显示在用户界面620中的地图,来查看地图的不同区域。另外,由于上述地图标识区域610B中显示的内容可以为纯色且具有一定透明度的图层(或与地图区域510B大小相同的边框),地图标识区域610B不会完全遮挡游戏场景区域610A中被地图标识区域610B覆盖的部分。相比于投屏之前的游戏界面510,用户在电子设备100上进行游戏操控时可以观看到更大视野范围的内容,可以获得更好的游戏体验。
图11示例性示出了本申请实施例提供的一种显示方法。
如图11所示,该方法可包括步骤S101~S106。其中:
S101、电子设备100可以检测到调用地图投屏服务的用户操作。
电子设备100可正在运行游戏A应用,并在显示屏上显示游戏A应用的游戏界面。该游戏界面可以参考前述图6B所示的游戏界面510。
上述地图投屏服务可以是前述实施例中应用A提供的。根据前述图5A~图5D所示的方法,该应用A和游戏A应用可以关联。这样,应用A可以为游戏A应用提供上述地图投屏服务。
上述用于调用地图投屏服务的用户操作可以例如是前述图6D所示作用在地图投屏控件512E上的触摸操作。
S102、电子设备100和电子设备200之间可以建立通信连接。
当检测到上述调用地图投屏服务的用户操作,电子设备100可以请求与电子设备200建立通信连接。其中,电子设备100和电子设备200可以是在同一局域网(如同一家庭Wi-Fi)的两个设备。本申请实施例对电子设备100和电子设备200之间通信连接的方法不作具体限定。
在一些实施例中,电子设备100和电子设备200之间的通信连接也可以是在电子设备100检测到调用地图投屏服务的用户操作之前建立的。
S103、电子设备100可以从绘制游戏界面的图形指令流中截取地图指令流,图形指令流 中可包括地图指令流和游戏场景指令流。
上述地图指令流可用于绘制图6B所示地图区域510B中的内容。上述游戏场景指令流可用于绘制图6B所示游戏场景区域510A中的内容。
电子设备100从图形指令流中截取地图指令流的实现方法可以参考前述实施例。这里不再赘述。
S104、电子设备100可以向电子设备200发送经过编码的地图指令流或经过编码的第一视频流,第一视频流由地图指令流转换得到。
电子设备100向电子设备200发送经过编码的地图指令流的方法可以参考前述图10所示的实施例。电子设备100向电子设备200发送经过编码的第一视频流的方法可以参考前述图9所示的实施例。
S105、电子设备100可以根据游戏场景指令流在电子设备100的显示屏进行渲染。
根据游戏场景指令流,电子设备100可以在显示屏显示如图6F所示游戏场景区域510A中的内容。
在一些实施例中,电子设备100还可以获取地图标识指令流。该地图标识指令流可用于绘制图7A所示地图标识区域610B中的内容。地图标识区域610B可用于标识投屏前图6A所示地图区域510B所在的位置。地图标识区域610B可以覆盖在游戏场景区域610B上。地图标识区域610B的大小以及在游戏界面610中的位置可以与图6A中地图区域510B的大小以及在游戏界面510中的位置相同。地图标识区域610B中的内容可以为图7A所示纯色且具有一定透明度的图层。上述纯色且具有一定透明度的图层不会完全遮挡游戏场景区域610A中被地图标识区域610B覆盖的部分。
根据游戏场景指令流和地图标识指令流,电子设备100可以在显示屏显示如图7A所示的游戏界面610。游戏界面610可包括游戏场景区域610A和地图标识区域610B。
S106、电子设备200可以根据地图指令流或第一视频流,在电子设备200的显示屏进行渲染。
根据地图指令流或第一视频流,电子设备200可以显示图6F所示用户界面530中的地图。
本申请实施例对上述显示方法中的应用不作限定,除了游戏A应用,电子设备100可以还可以将直播类应用、视频通话类应用等等类型的应用中一个用户界面上的部分显示内容投屏至其它电子设备显示。
由图11所示的显示方法可知,游戏A应用中游戏场景区域510A的内容可以在电子设备100显示。游戏A应用中地图区域510B的内容可以投屏至电子设备200,由电子设备200显示。这样,用户在玩游戏A的过程中,可以在电子设备100上进行游戏操控,并在电子设备200上查看地图。其中,用户在电子设备100上进行游戏操控时所能观看到的视野不再受到地图区域510B的遮挡,可以获得更好的游戏体验。
并且,电子设备100可以借助应用A实现上述显示方法。即需要进行投屏的应用无需修改。那么在第三方应用的开发者不对应用进行适应性修改的情况下,电子设备100可以将这些第三方应用中一个用户界面上的部分显示内容投屏至其他设备。这有利于本申请提供的显示方法适用于游戏应用、直播类应用、视频通话类应用等多种类型的应用
在一些实施例中,不限于两部分显示内容,一个应用的一个用户界面中可包括三部分显示内容或者更多的显示内容。以这一个用户界面中包括三部分显示内容(第一显示内容、第 二显示内容和第三显示内容)为例进行说明。电子设备100可以将第一显示内容和第三显示内容分别投屏至电子设备200和电子设备300,而仅在本地显示第二显示内容。
具体的,电子设备100中可存储有与上述第一显示内容对应的目标指令库A,和与第三显示内容对应的目标指令库B。电子设备100获取目标指令库的方法可以参考前述实施例的说明。根据上述目标指令库A,电子设备100可以从用于绘制上述一个用户界面的图形指令流中截取用于绘制第一显示内容的指令流。根据上述目标指令库B,电子设备100可以从用于绘制上述一个用户界面的图形指令流中截取用于绘制第三显示内容的指令流。
电子设备100可以将用于绘制第一显示内容的指令流发送给电子设备200。或者,电子设备100可以先在后台利用上述用于绘制第一显示内容的指令流进行渲染,得到包含第一显示内容的图像。然后,电子设备100可以将上述包含第一显示内容的图像转换为视频流,并将该视频流发送给电子设备200。这样,电子设备200可以显示上述第一显示内容。
电子设备100可以将用于绘制第三显示内容的指令流发送给电子设备300。或者,电子设备100可以先在后台利用上述用于绘制第三显示内容的指令流进行渲染,得到包含第三显示内容的图像。然后,电子设备100可以将上述包含第三显示内容的图像转换为视频流,并将该视频流发送给电子设备300。这样,电子设备300可以显示上述第三显示内容。
经过上述指令流截取的操作,用于绘制上述一个用户界面的图形指令流中余下的指令流可包括用于绘制第二显示内容的指令流。根据上述用于绘制第二显示内容的指令流,电子设备100可以显示第二显示内容。电子设备100、电子设备200和电子设备300根据指令流在显示屏上进行图像渲染的具体实现方式可以参考现有技术中的实现,本申请实施例对此不作限定。
在本申请实施例中,第一电子设备可以运行第一应用,显示第一用户界面。第一用户界面可包括第一内容和第二内容。上述第一应用可以是前述实施例中的游戏应用、直播类应用、视频通话类应用等等应用。上述第一用户界面可以例如是前述图1所示的游戏界面210。上述第一内容可以是前述实施例中的第二显示内容(如图1所示地图区域210B中的内容)。上述第二内容可以是前述实施例中的第一显示内容(如图1所示的游戏场景区域210A中的内容)。
在本申请中,第一电子设备可以响应于第一操作,显示第二用户界面。第二用户界面可包括第一内容。上述第二用户界面可以例如是前述图6F所示电子设备100的用户界面。上述第一操作可以例如是前述图6D所示作用在地图投屏控件512E所示的用户操作。
在本申请中,第一电子设备可以向第二电子设备发送第一数据,第一数据可以使得第二电子设备显示第三用户界面。第三用户界面可以例如是前述图6F所示电子设备200的用户界面。
在本申请中,第二用户界面还可以包括第三内容。第三内容覆盖显示在部分第一内容上。第三内容可以具有透明度。包括第三内容的第二用户界面可以例如是前述图7A所示的游戏界面610。第三内容可以是图7A所示地图标识区域610B中的内容。
以上所述,以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的范围。

Claims (9)

  1. 一种显示方法,应用于第一电子设备,其特征在于,所述方法包括:
    运行第一应用,显示第一用户界面,所述第一用户界面包括第一内容和第二内容,其中,所述第二内容覆盖显示在部分所述第一内容上,所述第一用户界面与所述第一应用相关;
    响应于第一操作,显示第二用户界面,所述第二用户界面包括所述第一内容,所述第一内容中被所述第二内容覆盖的部分呈现在所述第二用户界面;
    向第二电子设备发送第一数据,所述第一数据使得第二电子设备显示第三用户界面,所述第三用户界面包括所述第二内容,其中,所述第一电子设备和所述第二电子设备通信连接。
  2. 根据权利要求1所述的方法,其特征在于,所述第二用户界面还包括第三内容,所述第三内容覆盖显示在部分所述第一内容上,所述第三内容具有透明度。
  3. 根据权利要求2所述的方法,其特征在于,所述第三内容的显示区域的大小和位置分别与所述第二内容的显示区域的大小和位置相同。
  4. 根据权利要求1所述的方法,其特征在于,所述响应于第一操作,显示第二用户界面,所述方法具体包括:
    响应于所述第一操作,根据第一指令流生成第二指令流和第三指令流,所述第一指令流与所述第一应用相关;
    根据所述第二指令流,显示所述第二用户界面;
    所述方法还包括:
    根据所述第三指令流,确定所述第一数据。
  5. 根据权利要求2或3所述的方法,其特征在于,所述响应于第一操作,显示第二用户界面,所述方法具体包括:
    响应于所述第一操作,根据第一指令流生成第二指令流和第三指令流,所述第一指令流与所述第一应用相关;
    根据所述第三指令流,生成第四指令流;
    根据所述第二指令流和所述第四指令流,生成第五指令流;
    根据所述第五指令流,显示所述第二用户界面,所述第二用户界面包括所述第一内容和所述第三内容;
    所述方法还包括:
    根据所述第三指令流,确定所述第一数据。
  6. 根据权利要求4或5所述的方法,其特征在于,所述第一数据为所述第三指令流;或者,所述第一数据为第一视频流,所述第一视频流是根据包含所述第二内容的图像数据得到的,所述包含第二内容的图像数据是根据所述第三指令流得到的。
  7. 根据权利要求1-6中任一项所述的方法,其特征在于,所述方法还包括:
    接收作用在所述第二用户界面第一区域的第二操作,所述第一区域为所述第一内容中被所述第二内容覆盖的部分呈现在所述第二用户界面的区域;
    执行响应于所述第二操作的指令。
  8. 一种电子设备,其特征在于,所述电子设备包括显示屏、通信模块、存储器和处理器,其中,所述存储器用于存储计算机程序,所述处理器用于调用所述计算机程序,使得所述电子设备执行权利要求1-7中任一项所述的方法。
  9. 一种计算机可读存储介质,包括指令,其特征在于,当所述指令在电子设备上运行,使得所述电子设备执行权利要求1-7中任一项所述的方法。
PCT/CN2022/083338 2021-04-30 2022-03-28 显示方法及相关装置 WO2022227978A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
EP22794451.9A EP4316619A1 (en) 2021-04-30 2022-03-28 Display method and related apparatus

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110481999.6A CN115253285A (zh) 2021-04-30 2021-04-30 显示方法及相关装置
CN202110481999.6 2021-04-30

Publications (1)

Publication Number Publication Date
WO2022227978A1 true WO2022227978A1 (zh) 2022-11-03

Family

ID=83746104

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/083338 WO2022227978A1 (zh) 2021-04-30 2022-03-28 显示方法及相关装置

Country Status (3)

Country Link
EP (1) EP4316619A1 (zh)
CN (1) CN115253285A (zh)
WO (1) WO2022227978A1 (zh)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104978156A (zh) * 2014-04-02 2015-10-14 联想(北京)有限公司 多屏显示方法及多屏显示处理装置
US20160006721A1 (en) * 2014-07-07 2016-01-07 Facebook, Inc. Providing Social Network Content Based on the Login State of a User
CN110941501A (zh) * 2019-11-29 2020-03-31 维沃移动通信有限公司 一种应用共享方法及电子设备
CN111408145A (zh) * 2020-02-28 2020-07-14 网易(杭州)网络有限公司 游戏时播放直播内容的方法、装置、电子设备及存储介质
US20200379635A1 (en) * 2019-06-01 2020-12-03 Apple Inc. User interfaces with increased visibility
CN112286477A (zh) * 2020-11-16 2021-01-29 Oppo广东移动通信有限公司 投屏显示方法及相关产品
CN112394895A (zh) * 2020-11-16 2021-02-23 Oppo广东移动通信有限公司 画面跨设备显示方法与装置、电子设备

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104978156A (zh) * 2014-04-02 2015-10-14 联想(北京)有限公司 多屏显示方法及多屏显示处理装置
US20160006721A1 (en) * 2014-07-07 2016-01-07 Facebook, Inc. Providing Social Network Content Based on the Login State of a User
US20200379635A1 (en) * 2019-06-01 2020-12-03 Apple Inc. User interfaces with increased visibility
CN110941501A (zh) * 2019-11-29 2020-03-31 维沃移动通信有限公司 一种应用共享方法及电子设备
CN111408145A (zh) * 2020-02-28 2020-07-14 网易(杭州)网络有限公司 游戏时播放直播内容的方法、装置、电子设备及存储介质
CN112286477A (zh) * 2020-11-16 2021-01-29 Oppo广东移动通信有限公司 投屏显示方法及相关产品
CN112394895A (zh) * 2020-11-16 2021-02-23 Oppo广东移动通信有限公司 画面跨设备显示方法与装置、电子设备

Also Published As

Publication number Publication date
EP4316619A1 (en) 2024-02-07
CN115253285A (zh) 2022-11-01

Similar Documents

Publication Publication Date Title
US11989482B2 (en) Split-screen projection of an image including multiple application interfaces
WO2020259452A1 (zh) 一种移动终端的全屏显示方法及设备
US20220050656A1 (en) Method for displaying ui component and electronic device
US20230419570A1 (en) Image Processing Method and Electronic Device
WO2021213164A1 (zh) 应用界面交互方法、电子设备和计算机可读存储介质
WO2021036770A1 (zh) 一种分屏处理方法及终端设备
CN114397979A (zh) 一种应用显示方法及电子设备
WO2020093988A1 (zh) 一种图像处理方法及电子设备
WO2022105445A1 (zh) 基于浏览器的应用投屏方法及相关装置
CN113961157B (zh) 显示交互系统、显示方法及设备
WO2022017205A1 (zh) 一种显示多个窗口的方法及电子设备
WO2021008589A1 (zh) 一种应用的运行方法及电子设备
CN113935898A (zh) 图像处理方法、系统、电子设备及计算机可读存储介质
WO2022001258A1 (zh) 多屏显示方法、装置、终端设备及存储介质
CN114040242A (zh) 投屏方法和电子设备
CN110989961A (zh) 一种声音处理方法及其装置
WO2022127632A1 (zh) 一种资源管控方法及设备
CN113887264A (zh) 扫码方法、系统及相关装置
CN115756268A (zh) 跨设备交互的方法、装置、投屏系统及终端
WO2022042769A2 (zh) 多屏交互的系统、方法、装置和介质
WO2021238740A1 (zh) 一种截屏方法及电子设备
WO2023005900A1 (zh) 一种投屏方法、电子设备及系统
WO2022143310A1 (zh) 一种双路投屏的方法及电子设备
WO2022095906A1 (zh) 一种按键映射方法、电子设备及系统
WO2022062902A1 (zh) 一种文件传输方法和电子设备

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22794451

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2022794451

Country of ref document: EP

ENP Entry into the national phase

Ref document number: 2022794451

Country of ref document: EP

Effective date: 20231026

NENP Non-entry into the national phase

Ref country code: DE