WO2018045685A1 - 一种图片显示方法及装置 - Google Patents
一种图片显示方法及装置 Download PDFInfo
- Publication number
- WO2018045685A1 WO2018045685A1 PCT/CN2016/113347 CN2016113347W WO2018045685A1 WO 2018045685 A1 WO2018045685 A1 WO 2018045685A1 CN 2016113347 W CN2016113347 W CN 2016113347W WO 2018045685 A1 WO2018045685 A1 WO 2018045685A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- coordinates
- coordinate
- displayed
- picture
- current
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input 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/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0484—Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
- G06F3/04845—Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range for image manipulation, e.g. dragging, rotation, expansion or change of colour
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input 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/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0484—Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input 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/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0484—Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
- G06F3/04847—Interaction techniques to control parameter settings, e.g. interaction with sliders or dials
Definitions
- the present invention relates to the field of picture processing, and in particular, to a picture display method and apparatus.
- the teacher hopes to gradually display the content of the teaching, rather than showing it all at once. For example, when an art teacher is in class, he wants a picture to be presented little by little. For example, the math teacher wants to explain the steps of solving the problem step by step.
- the PPT can be used for step-by-step display
- the step-by-step display of the PPT is not flexible enough, and the production is difficult, the production time is long, and the use experience is not good.
- an object of the present invention is to provide a picture display method and apparatus that can gradually display an image according to a user's operation.
- the invention provides a picture display method, comprising the following steps:
- the coordinates of the mouse at the current time are acquired, and the coordinates of the current time are stored in a preset point set;
- a pixel corresponding to the current moving path is displayed.
- acquiring the coordinates of the mouse at the current time and storing the coordinates of the current time in the preset point set further includes:
- the coordinates of the mouse at the current time are acquired, and the coordinates of the current time are stored in a preset point set, specifically:
- the third coordinate is set as a coordinate of the current time, and the coordinate of the current time is stored in a preset point set.
- the current moving path is generated according to the coordinates of the current time and the coordinates of the previous time.
- the displaying a pixel corresponding to the current moving path is specifically:
- the method before displaying the pixel corresponding to the current moving path, the method further includes:
- the preset path width is set to the current moving path.
- the invention also provides a picture display device, comprising:
- a listening unit configured to acquire coordinates of the mouse at a current time when the mouse is located in a hidden area of the picture to be displayed, and store the coordinates of the current time in a preset point set;
- a query unit configured to query coordinates of the last moment before the current moment in the set of points
- a moving path generating unit configured to generate a current moving path according to the coordinates of the current time and the coordinates of the previous time
- a display unit configured to display a pixel corresponding to the current moving path.
- the method further comprises:
- a hiding unit configured to set a clip property of a picture to be displayed as an empty Geometry object to hide the picture to be displayed.
- the monitoring unit specifically includes:
- a coordinate monitoring module configured to monitor a first coordinate of the mouse in a display screen coordinate system
- a coordinate transformation module configured to obtain, according to the first coordinate and the preset second coordinate, a third coordinate of the mouse relative to the to-be-displayed image; wherein the second coordinate is a reference point of the to-be-displayed image The coordinates in the display screen coordinate system;
- a saving module configured to: when determining that the third coordinate is located in a hidden area of the picture to be displayed, The coordinates are set to the coordinates of the current time, and the coordinates of the current time are stored in a preset point set.
- the method further comprises:
- a path width setting unit configured to set a preset path width to the current moving path.
- the image display method and device provided by the embodiment of the invention can display the corresponding area on the picture to be displayed according to the path formed by the user moving the mouse, so that the user can display the image according to the actual side moving the mouse, thereby realizing flexible
- the picture shows that the whole process operation is simple and easy to operate, which satisfies the requirements in teaching or demonstration and enhances the interactive effect.
- FIG. 1 is a schematic flowchart of a picture display method according to an embodiment of the present invention.
- FIG. 2 is a schematic diagram of a portion of a picture to be displayed according to an embodiment of the present invention.
- FIG. 3 is a schematic structural diagram of a picture display device according to an embodiment of the present invention.
- FIG. 4 is a schematic structural view of the monitoring unit of FIG. 3.
- an embodiment of the present invention provides a picture display method, which may be performed by an image display device, which may be a notebook, a desktop computer, or other smart terminal.
- the image display method includes at least the following steps:
- the picture to be displayed needs to be hidden first, that is, the transparency of all pixels of the picture to be displayed is set to 1 (normalized transparency), and the picture to be displayed is invisible.
- the hidden state is, the transparency of all pixels of the picture to be displayed is set to 1 (normalized transparency), and the picture to be displayed is invisible.
- the clip attribute of the to-be-displayed image may be set to an empty Geometry object. At this time, the to-be-displayed The transparency of the pixels of the picture becomes 1 (ie, completely transparent), thereby achieving the effect of hiding the picture.
- the picture display device keeps listening to the position of the user on the display screen through the mouse, and when the mouse is located in the hidden area of the picture to be displayed, acquires the coordinates of the mouse at the current time, and The coordinates of the current time are stored in a preset point set.
- the coordinates initially acquired by the image display device are the coordinates of the mouse relative to the display screen, that is, the coordinates in the display screen coordinate system, it is necessary to perform coordinate conversion to obtain the mouse relative to the The coordinates of the image to be displayed.
- the third coordinate is set as the coordinate of the current time, and the coordinate of the current time is stored in the preset point set.
- the coordinates of the current time obtained by the step S101 are stored in the point set, and thus the coordinates of the previous time before the current time can be queried in the point set, wherein This coordinate is the coordinate transformed by the coordinate system.
- the current moving path may be generated.
- the current moving path can be generated by StreamGeometry.
- a context object StreamGeometryContext that can draw a path is obtained by the Open method in StreamGeometry.
- the StreamGeometryContext contains two methods: Begin Figure and LineTo, and Begin Figure is the first point that should be drawn in the initialization. Where (the coordinates of the previous moment), LinkTo is the coordinates of the second point (the coordinates of the current moment), which connects the second point with the first one to become a line, generates a moving route, and then passes the GetWidenedPathGeometry in the StreamGeometryContext.
- the method can generate a current moving path according to the moving route.
- the image display device when the user continuously moves or slides the mouse, can continuously generate a moving path.
- the coordinates of the current time and the previous time need to be determined.
- the coordinates are No continuous, if not continuous, the current moving path will not be generated based on these two coordinates.
- the absolute value of the difference between the x value and the y value of the two coordinates is continuously required to be no more than a predetermined parameter (if preferred, the parameter may be selected to be 1).
- the coordinates of the current time are (x, y)
- the coordinates of the previous time are (x ⁇ 1, y), (x ⁇ 1, y ⁇ 1), (x, y ⁇ 1)
- these two points are continuous, otherwise they are not continuous. Its purpose is to prevent additional display problems caused by users clicking in different locations.
- the image display device sets the current movement path to the Clip attribute of the picture to be displayed, and at this time, only the area corresponding to the current movement path is displayed on the picture to be displayed.
- the pixels, the other parts remain transparent. In this way, the corresponding part can be displayed according to the user's operation, thereby meeting the needs in teaching or demonstration.
- the embodiment of the present invention can be used to hide the entire painting first, and then use the mouse to wipe out the first displayed area, thereby achieving a little A little presentation of the purpose.
- the math teacher wants to explain the steps of solving the problem step by step. You can set the entire problem-solving step to be hidden first, and you can step one step at the time of the lecture to achieve the purpose of step-by-step presentation.
- the picture display method provided by the embodiment of the present invention can display the corresponding area on the picture to be displayed according to the path formed by the user moving the mouse, so that the user can display the image while moving the mouse according to the actual needs.
- Achieve flexible picture display, the whole process operation is simple to implement, easy to operate, meet the needs of teaching or demonstration, and enhance the effect of interaction.
- the line width of the moving path is 1 pixel, which causes the user to need a lot of sliding operations to display the content to be displayed, which is very inconvenient to operate.
- the method further includes:
- the preset path width is set to the current moving path.
- the shape of the mouse can be set to an eraser-like shape, and the height of the eraser is the preset path width, so that when the display is performed, the current mouse is displayed.
- the pixels in the covered range are displayed together, so that the number of pixels displayed each time is large, thereby avoiding the problem of requiring frequent movement or sliding of the mouse.
- the path width can be selected by the user, so that the user can select the required path width according to the actual situation to meet the actual use requirements.
- the present invention further provides a picture display device 100, including:
- the monitoring unit 10 is configured to acquire the coordinates of the mouse at the current time when the mouse is located in the hidden area of the picture to be displayed, and store the coordinates of the current time into a preset point set.
- the query unit 20 is configured to query coordinates of the previous set of points in the set of points before the current moment.
- the moving path generating unit 30 is configured to generate a current moving path according to the coordinates of the current time and the coordinates of the previous time.
- the moving path generating unit 30 before the current moving path is generated according to the coordinates of the current time and the coordinates of the previous time, the moving path generating unit 30 first needs to determine the current time. Whether the coordinates are continuous with the coordinates of the previous time, and if not, the current moving path is not generated based on the two coordinates. Wherein, the absolute value of the difference between the x value and the y value of the two coordinates is continuously required to be no more than a predetermined parameter (if preferred, the parameter may be selected to be 1).
- the display unit 40 is configured to display pixels corresponding to the current moving path.
- the display unit 40 sets the current movement path to the Clip attribute of the picture to be displayed, and at this time, only the area corresponding to the current movement path is displayed on the picture to be displayed.
- the pixels, the other parts remain transparent. In this way, the corresponding part can be displayed according to the user's operation, thereby meeting the needs in teaching or demonstration.
- the picture display device 100 can display a corresponding area on the picture to be displayed according to a path formed by the user moving the mouse, so that the user can display the image while moving the mouse according to actual needs.
- the flexible image display is realized, the whole process operation is simple to implement, the operation is convenient, the requirements in teaching or demonstration are satisfied, and the interaction effect is improved.
- the method further comprises:
- the hiding unit 50 is configured to set a clip attribute of the picture to be displayed as an empty Geometry object to hide the picture to be displayed.
- the picture to be displayed needs to be hidden first, that is, all the pictures to be displayed are
- the transparency of the pixel is set to 1 (normalized transparency), and the picture to be displayed is in a hidden state that is invisible.
- the Clip property of the to-be-displayed image may be set to an empty Geometry object. At this time, the transparency of the pixel of the picture to be displayed becomes 1 (ie, completely transparent), thereby realizing the effect of hiding the picture.
- the listening unit 10 specifically includes:
- the coordinate monitoring module 11 is configured to monitor the first coordinate of the mouse in the display screen coordinate system.
- the coordinate transformation module 12 is configured to obtain, according to the first coordinate and the preset second coordinate, a third coordinate of the mouse relative to the to-be-displayed image; wherein the second coordinate is a reference of the to-be-displayed image The coordinates at the display screen coordinate system.
- the saving module 13 is configured to: when determining that the third coordinate is located in a hidden area of the to-be-displayed image, set the third coordinate as a coordinate of the current time, and save the coordinate of the current time into a preset In the collection of points.
- the method further comprises:
- the path width setting unit 50 is configured to set a preset path width to the current moving path.
- the shape of the mouse can be set to an eraser-like shape, and the height of the eraser is the preset path width, so that when the display is performed, the current mouse is displayed.
- the pixels in the covered range are displayed together, so that the number of pixels displayed each time is large, thereby avoiding the problem of requiring frequent movement or sliding of the mouse.
- the path width can be selected by the user, so that the user can select the required path width according to the actual situation to meet the actual use requirements.
- the storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).
Landscapes
- Engineering & Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Human Computer Interaction (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- User Interface Of Digital Computer (AREA)
- Controls And Circuits For Display Device (AREA)
Abstract
一种图片显示方法及装置,可根据用户移动鼠标形成的路径来显示所述待显示图片上的相应的区域,使得用户可以根据实际的边移动鼠标边显示图像,实现了灵活的图片显示。该方法包括如下步骤:当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合(S101);查询所述点集合中位于当前时刻之前的上一个时刻的坐标(S102);根据所述当前时刻的坐标与所述上一个时刻的坐标,生成当前移动路径(S103);显示与所述当前移动路径对应的像素(S104)。
Description
本发明涉及图片处理领域,尤其涉及一种图片显示方法及装置。
随着计算机技术的发展,智能化教学已经逐渐普及到各个校园中,基于智能化教学,老师可利用各种智能化教学设备,如大屏智能平板等实现教学而不需要再使用粉笔在黑板上写字,从而提高了教学的效率,也解决了老师吃粉笔灰的问题。
在有些教学情况下,老师希望可以逐渐显示其教学内容,而非一下子完整显示出来。例如,美术老师上课时想让一幅画一点一点的呈现出来,又比如数学老师想让解题的步骤一步一步的呈现出来。
现有技术中,虽然利用PPT可以实现逐步显示,但是PPT的逐步显示不够灵活,而且制作难度大,制作所需时间也比较长,使用体验不佳。
发明内容
针对上述问题,本发明的目的在于提供一种图片显示方法及装置,可根据用户的操作来逐步进行图像的显示。
本发明提供了一种图片显示方法,包括如下步骤:
当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合;
查询所述点集合中位于当前时刻之前的上一个时刻的坐标;
根据所述当前时刻的坐标与所述上一个时刻的坐标,生成当前移动路径;
显示与所述当前移动路径对应的像素。
优选地,在当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合之前,还包括:
将待显示图片的clip属性设置为一个空的Geometry对象,以隐藏所述待显示图片。
优选地,所述当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合,具体为:
监听鼠标在显示屏幕坐标系下的第一坐标;
根据所述第一坐标及预置的第二坐标,得到所述鼠标相对于待显示图片的第三坐标;其中,所述第二坐标为所述待显示图片的参考点在所述显示屏幕坐标系下的坐标;
当判断所述第三坐标位于所述待显示图片的隐藏区域内时,将所述第三坐标设置为当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合中。
优选地,当所述当前时刻的坐标与所述上一个时刻的坐标连续时,根据所述当前时刻的坐标与所述上一个时刻的坐标,生成当前移动路径。
优选地,所述显示与所述当前移动路径对应的像素,具体为:
将所述当前路径设置给所述待显示图片的clip属性,以显示与所述当前移动路径对应的像素。
优选地,在显示与所述当前移动路径对应的像素之前,还包括:
将预置的路径宽度设置给所述当前移动路径。
本发明还提供一种图片显示装置,包括:
监听单元,用于当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合;
查询单元,用于查询所述点集合中位于当前时刻之前的上一个时刻的坐标;
移动路径生成单元,用于根据所述当前时刻的坐标与所述上一个时刻的坐标,生成当前移动路径;
显示单元,用于显示与所述当前移动路径对应的像素。
优选地,还包括:
隐藏单元,用于将待显示图片的clip属性设置为一个空的Geometry对象,以隐藏所述待显示图片。
优选地,所述监听单元具体包括:
坐标监听模块,用于监听鼠标在显示屏幕坐标系下的第一坐标;
坐标变换模块,用于根据所述第一坐标及预置的第二坐标,得到所述鼠标相对于待显示图片的第三坐标;其中,所述第二坐标为所述待显示图片的参考点在所述显示屏幕坐标系下的坐标;
保存模块,用于当判断所述第三坐标位于所述待显示图片的隐藏区域内时,将所述第三
坐标设置为当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合中。
优选地,还包括:
路径宽度设置单元,用于将预置的路径宽度设置给所述当前移动路径。
本发明实施例提供的图片显示方法及装置,可根据用户移动鼠标形成的路径来显示所述待显示图片上的相应的区域,使得用户可以根据实际的边移动鼠标边显示图像,实现了灵活的图片显示,整个过程操作实现简单,操作便捷,满足了教学或演示中的需求,提升了互动的效果。
为了更清楚地说明本发明的技术方案,下面将对实施方式中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施方式,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是本发明实施例提供的图片显示方法的流程示意图。
图2是本发明实施例提供的待显示图片部分显示时的示意图。
图3是本发明实施例提供的图片显示装置的结构示意图。
图4是图3的监听单元的结构示意图。
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。
请参阅图1,本发明实施例提供了一种图片显示方法,其可由图像显示装置来执行,所述图像显示装置可为笔记本、台式电脑或其他智能终端。
其中,所述图片显示方法至少包括如下步骤:
S101,当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合。
在本发明实施例中,首先需要将所述待显示图片隐藏起来,即将所述待显示图片的所有像素的透明度设置为1(归一化的透明度),此时所述待显示图片呈不可视的隐藏状态。
其中,可将所述待显示图片的clip属性设置为一个空的Geometry对象。这时,所述待显
示图片的像素的透明度变成1(即完全透明),从而实现隐藏图片的效果。
在本发明实施例中,所述图片显示装置会保持监听用户通过鼠标在显示屏幕上的位置,当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合。
需要说明的是,由于所述图像显示装置初始获取的坐标是鼠标相对于显示屏幕的坐标,即在显示屏幕坐标系下的坐标,因而需要进行坐标系的换算来得到所述鼠标相对于所述待显示图像的坐标。
具体地,所述图像显示装置首先通过系统接口获取与鼠标在显示屏幕坐标系下的第一坐标P1(P1.x,P1.y),然后获取所述待显示图片的参考点(如左上角的点)在所述显示屏幕坐标系下的第二坐标P2(P2.x,P2.y),接着根据所述第一坐标P1及所述二坐标P2,得到第三坐标P3=(P1.x-P2.x,P1.y-P2.y),即得到所述鼠标相对于待显示图片的第三坐标。最后当判断所述第三坐标位于所述待显示图片的隐藏区域内时,将所述第三坐标设置为当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合中。
S102,查询所述点集合中位于当前时刻之前的上一个时刻的坐标。
在本发明实施例中,由步骤S101监听得到的当前时刻的坐标都会存入到所述点集合中,因而可以在所述点集合中查询到位于当前时刻之前的上一个时刻的坐标,其中,这个坐标是经过坐标系变换后的坐标。
S103,根据所述当前时刻的坐标与所述上一个时刻的坐标,生成当前移动路径。
在本发明实施例中,在获得当前时刻的坐标与所述上一个时刻的坐标后,即可以生成当前移动路径。
具体地,可通过StreamGeometry来生成当前移动路径,首先,通过StreamGeometry中的Open方法获取一个可以绘制路径的上下文对象StreamGeometryContext,StreamGeometryContext包含两个方法:BeginFigure和LineTo,BeginFigure就是初始化第一个点应该画在那里(上一时刻的坐标),LinkTo是第二点的坐标(当前时刻的坐标),它将第二个点与第一个连接起来从而成为一条线,生成移动路线,再通过StreamGeometryContext中的GetWidenedPathGeometry方法就可以根据所述移动路线生成当前移动路径。
在本发明实施例中,当用户不断移动或滑动鼠标时,所述图像显示装置就可以不断生成移动路径。
需要说明的是,在本发明实施例中,在根据所述当前时刻的坐标与所述上一个时刻的坐标,生成当前移动路径之前,首先需要判断所述当前时刻的坐标与所述上一个时刻的坐标是
否连续,如果不连续,则不会根据这两个坐标生成当前移动路径。其中,连续要求这两个坐标的x值和y值的差的绝对值不大于预定的参数(如优选的,所述参数可选择为1)。例如假设所述当前时刻的坐标为(x,y),则当所述上一个时刻的坐标为(x±1,y),(x±1,y±1),(x,y±1)时,则这两个点连续,否则不连续。其目的是防止用户在不同的位置点击时造成的额外显示的问题。
例如,如图2所述,假设用户上一时刻的鼠标的坐标在A点,然后退出滑动显示的模式后,移动到B点,并再次进行滑动显示模式,则这时候不应该根据这两个点生成当前移动路径,否则会使得AB之间的区域都显示出来。
S104,显示与所述当前移动路径对应的像素。
在本发明实施例中,所述图像显示装置将所述当前移动路径设置给所述待显示图片的Clip属性,此时所述待显示图片上只会显示与所述当前移动路径对应的区域内的像素,其它部分还是保持透明状态。这样,就可以根据用户的操作显示相应的部分,从而满足教学或演示中的需求。
例如,美术老师上课时有一幅画想让它一点一点的呈现出来,就可以使用本发明实施例,先将整幅画隐藏,再用鼠标将首先显示的区域擦出来,从而实现一点一点呈现的目的。再例如,数学老师想让解题的步骤一步一步的呈现出来,可以先将整个的解题步骤设置为隐藏,在讲课的时候可以讲一步擦一步,从而实现一步一步呈现的目的。
综上所述,本发明实施例提供的图片显示方法,可根据用户移动鼠标形成的路径来显示所述待显示图片上的相应的区域,使得用户可以根据实际需要的边移动鼠标边显示图像,实现了灵活的图片显示,整个过程操作实现简单,操作便捷,满足了教学或演示中的需求,提升了互动的效果。
为了便于对本发明的理解,下面将对本发明的一些优选实施例做更进一步的描述。
上述实施例中,所述移动路径的线宽为1个像素,这导致用户可能需要非常多的滑动操作才能显示自己所要显示的内容,操作非常不便。
为此,在本优选实施例中,还包括:
将预置的路径宽度设置给所述当前移动路径。
如图2所示,在本优选实施例中,可将鼠标的形状设置成类似橡皮擦的形状,橡皮擦的高度即是预置的路径宽度,这样,在显示的时候,会将当前鼠标所覆盖的范围内的像素都一并显示,使得每次显示的像素点的数目较多,从而避免了需要频繁移动或滑动鼠标的问题。
此外,所述路径宽度可由用户选择,这样用户可根据实际情况选择需要的路径宽度,以满足实际的使用需求。
请参阅图3,本发明还提供一种图片显示装置100,包括:
监听单元10,用于当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合。
查询单元20,用于查询所述点集合中位于当前时刻之前的上一个时刻的坐标。
移动路径生成单元30,用于根据所述当前时刻的坐标与所述上一个时刻的坐标,生成当前移动路径。
需要说明的是,在本发明实施例中,所述移动路径生成单元30在根据所述当前时刻的坐标与所述上一个时刻的坐标,生成当前移动路径之前,首先需要判断所述当前时刻的坐标与所述上一个时刻的坐标是否连续,如果不连续,则不会根据这两个坐标生成当前移动路径。其中,连续要求这两个坐标的x值和y值的差的绝对值不大于预定的参数(如优选的,所述参数可选择为1)。例如假设所述当前时刻的点击点的坐标为(x,y),则当所述上一个时刻的点击点的坐标为(x±1,y),(x±1,y±1),(x,y±1)时,则这两个点连续,否则不连续。其目的是防止用户在不同的位置点击时造成的额外显示的问题。
例如,如图2所述,假设用户上一时刻的鼠标的坐标在A点,然后退出滑动显示的模式后,移动到B点,并再次进行滑动显示模式,则这时候不应该根据这两个点生成当前移动路径,否则会使得AB之间的区域都显示出来。
显示单元40,用于显示与所述当前移动路径对应的像素。
在本发明实施例中,所述显示单元40将所述当前移动路径设置给所述待显示图片的Clip属性,此时所述待显示图片上只会显示与所述当前移动路径对应的区域内的像素,其它部分还是保持透明状态。这样,就可以根据用户的操作显示相应的部分,从而满足教学或演示中的需求。
综上所述,本发明实施例提供的图片显示装置100,可根据用户移动鼠标形成的路径来显示所述待显示图片上的相应的区域,使得用户可以根据实际需要的边移动鼠标边显示图像,实现了灵活的图像显示,整个过程操作实现简单,操作便捷,满足了教学或演示中的需求,提升了互动的效果。
其中,优选地,还包括:
隐藏单元50,用于将待显示图片的clip属性设置为一个空的Geometry对象,以隐藏所述待显示图片。
在本发明实施例中,首先需要将所述待显示图片隐藏起来,即将所述待显示图片的所有
像素的透明度设置为1(归一化的透明度),此时所述待显示图片呈不可视的隐藏状态。
其中,可将所述待显示图片的Clip属性设置为一个空的Geometry对象。这时,所述待显示图片的像素的透明度变成1(即完全透明),从而实现隐藏图片的效果。
请参阅图4,其中,优选地,所述监听单元10具体包括:
坐标监听模块11,用于监听鼠标在显示屏幕坐标系下的第一坐标。
坐标变换模块12,用于根据所述第一坐标及预置的第二坐标,得到所述鼠标相对于待显示图片的第三坐标;其中,所述第二坐标为所述待显示图片的参考点在所述显示屏幕坐标系下的坐标。
保存模块13,用于当判断所述第三坐标位于所述待显示图片的隐藏区域内时,将所述第三坐标设置为当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合中。
优选地,还包括:
路径宽度设置单元50,用于将预置的路径宽度设置给所述当前移动路径。
如图2所示,在本优选实施例中,可将鼠标的形状设置成类似橡皮擦的形状,橡皮擦的高度即是预置的路径宽度,这样,在显示的时候,会将当前鼠标所覆盖的范围内的像素都一并显示,使得每次显示的像素点的数目较多,从而避免了需要频繁移动或滑动鼠标的问题。
此外,所述路径宽度可由用户选择,这样用户可根据实际情况选择需要的路径宽度,以满足实际的使用需求。
以上所揭露的仅为本发明一种较佳实施例而已,当然不能以此来限定本发明之权利范围,本领域普通技术人员可以理解实现上述实施例的全部或部分流程,并依本发明权利要求所作的等同变化,仍属于发明所涵盖的范围。
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的程序可存储于一计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,所述的存储介质可为磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)或随机存储记忆体(Random Access Memory,RAM)等。
Claims (10)
- 一种图片显示方法,其特征在于,包括如下步骤:当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合;查询所述点集合中位于当前时刻之前的上一个时刻的坐标;根据所述当前时刻的坐标与所述上一个时刻的坐标,生成当前移动路径;显示与所述当前移动路径对应的像素。
- 根据权利要求1所述的图片显示方法,其特征在于,在当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合之前,还包括:将待显示图片的clip属性设置为一个空的Geometry对象,以隐藏所述待显示图片。
- 根据权利要求1所述的图片显示方法,其特征在于,所述当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合,具体为:监听鼠标在显示屏幕坐标系下的第一坐标;根据所述第一坐标及预置的第二坐标,得到所述鼠标相对于待显示图片的第三坐标;其中,所述第二坐标为所述待显示图片的参考点在所述显示屏幕坐标系下的坐标;当判断所述第三坐标位于所述待显示图片的隐藏区域内时,将所述第三坐标设置为当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合中。
- 根据权利要求1所述的图片显示方法,其特征在于,当所述当前时刻的坐标与所述上一个时刻的坐标连续时,根据所述当前时刻的坐标与所述上一个时刻的坐标,生成当前移动路径。
- 根据权利要求2所述的图片显示方法,其特征在于,所述显示与所述当前移动路径对应的像素,具体为:将所述当前路径设置给所述待显示图片的clip属性,以显示与所述当前移动路径对应的像素。
- 根据权利要求1至5任意一项所述的图片显示方法,其特征在于,在显示与所述当前移动路径对应的像素之前,还包括:将预置的路径宽度设置给所述当前移动路径。
- 一种图片显示装置,其特征在于,包括:监听单元,用于当监听到鼠标位于待显示图片的隐藏区域内时,获取所述鼠标在当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合;查询单元,用于查询所述点集合中位于当前时刻之前的上一个时刻的坐标;移动路径生成单元,用于根据所述当前时刻的坐标与所述上一个时刻的坐标,生成当前移动路径;显示单元,用于显示与所述当前移动路径对应的像素。
- 根据权利要求7所述的图片显示装置,其特征在于,还包括:隐藏单元,用于将待显示图片的clip属性设置为一个空的Geometry对象,以隐藏所述待显示图片。
- 根据权利要求7所述的图片显示装置,其特征在于,所述监听单元具体包括:坐标监听模块,用于监听鼠标在显示屏幕坐标系下的第一坐标;坐标变换模块,用于根据所述第一坐标及预置的第二坐标,得到所述鼠标相对于待显示图片的第三坐标;其中,所述第二坐标为所述待显示图片的参考点在所述显示屏幕坐标系下的坐标;保存模块,用于当判断所述第三坐标位于所述待显示图片的隐藏区域内时,将所述第三坐标设置为当前时刻的坐标,并将所述当前时刻的坐标存入预设的点集合中。
- 根据权利要求7至9任意一项所述的图片显示装置,其特征在于,还包括:路径宽度设置单元,用于将预置的路径宽度设置给所述当前移动路径。
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201610814996.9A CN106406698A (zh) | 2016-09-09 | 2016-09-09 | 一种图片显示方法及装置 |
| CN201610814996.9 | 2016-09-09 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2018045685A1 true WO2018045685A1 (zh) | 2018-03-15 |
Family
ID=57999145
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2016/113347 Ceased WO2018045685A1 (zh) | 2016-09-09 | 2016-12-30 | 一种图片显示方法及装置 |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN106406698A (zh) |
| WO (1) | WO2018045685A1 (zh) |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN107544730B (zh) * | 2017-08-25 | 2020-06-09 | 广州视源电子科技股份有限公司 | 图片显示方法、装置及可读存储介质 |
| CN113867876B (zh) * | 2021-10-08 | 2024-02-23 | 北京字跳网络技术有限公司 | 表情显示的方法、装置、设备及存储介质 |
Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2011055459A1 (ja) * | 2009-11-09 | 2011-05-12 | パイオニア株式会社 | 情報処理装置、その方法、および、表示装置 |
| CN103019516A (zh) * | 2012-12-10 | 2013-04-03 | 北京奇虎科技有限公司 | 用于显示页面的方法和设备 |
| CN103543925A (zh) * | 2013-10-18 | 2014-01-29 | 北京搜狗科技发展有限公司 | 一种操作图片的方法和装置 |
| CN104090709A (zh) * | 2014-06-11 | 2014-10-08 | 小米科技有限责任公司 | 图片切换方法和装置 |
| CN104679432A (zh) * | 2015-03-04 | 2015-06-03 | 成都品果科技有限公司 | 一种基于移动端浏览器跨平台人机交互浏览图片的方法 |
Family Cites Families (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN103455770A (zh) * | 2013-08-18 | 2013-12-18 | 苏州量跃信息科技有限公司 | 通过触摸屏实现的数据内容消隐方法及终端 |
-
2016
- 2016-09-09 CN CN201610814996.9A patent/CN106406698A/zh active Pending
- 2016-12-30 WO PCT/CN2016/113347 patent/WO2018045685A1/zh not_active Ceased
Patent Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2011055459A1 (ja) * | 2009-11-09 | 2011-05-12 | パイオニア株式会社 | 情報処理装置、その方法、および、表示装置 |
| CN103019516A (zh) * | 2012-12-10 | 2013-04-03 | 北京奇虎科技有限公司 | 用于显示页面的方法和设备 |
| CN103543925A (zh) * | 2013-10-18 | 2014-01-29 | 北京搜狗科技发展有限公司 | 一种操作图片的方法和装置 |
| CN104090709A (zh) * | 2014-06-11 | 2014-10-08 | 小米科技有限责任公司 | 图片切换方法和装置 |
| CN104679432A (zh) * | 2015-03-04 | 2015-06-03 | 成都品果科技有限公司 | 一种基于移动端浏览器跨平台人机交互浏览图片的方法 |
Non-Patent Citations (1)
| Title |
|---|
| CLOCK. ANDROID (SCRATCHVIEW, 5 September 2016 (2016-09-05), pages 2 - 7, Retrieved from the Internet <URL:http://www.jb51.net/article/91972.htm> * |
Also Published As
| Publication number | Publication date |
|---|---|
| CN106406698A (zh) | 2017-02-15 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US12388954B2 (en) | Display apparatus and control methods thereof | |
| US9268423B2 (en) | Definition and use of node-based shapes, areas and windows on touch screen devices | |
| WO2017101441A1 (zh) | 远程批注移动、缩放的同步方法与系统 | |
| CN110716680A (zh) | 智能交互平板的控制方法和装置 | |
| CN108415658A (zh) | 智能交互平板的操作方法、装置以及智能交互平板 | |
| CN109375980B (zh) | 基于Andriod系统的触控绘图方法 | |
| CN108376044A (zh) | 智能交互平板的操作方法、装置以及智能交互平板 | |
| CN108733296B (zh) | 书写笔迹的擦除方法、装置和设备 | |
| CN112181268B (zh) | 一种基于智能笔的答题方法、装置、终端和系统 | |
| US20160378272A1 (en) | Systems and methods for providing multi-focus to applications for collaboration | |
| CN106991711A (zh) | 笔迹编辑方法和系统 | |
| JP2017107485A (ja) | 電子機器及び表示制御方法 | |
| US20240303026A1 (en) | Method and device for multiple-terminal collaboratively updating displayed content | |
| WO2017114255A1 (zh) | 一种针对投影图像的触控方法及装置 | |
| CN108492349B (zh) | 书写笔画的处理方法、装置、设备和存储介质 | |
| WO2018045685A1 (zh) | 一种图片显示方法及装置 | |
| Kukimoto et al. | HyperInfo: interactive large display for informal visual communication | |
| CN107391015B (zh) | 一种智能平板的控制方法、装置、设备及存储介质 | |
| CN112083628B (zh) | 一种智能投影装置、及投影交互方法 | |
| CN105786360A (zh) | 一种用移动终端演示ppt文档的方法和装置 | |
| CN116301494A (zh) | 工具栏交互方法、装置、计算机可读存储介质及电子设备 | |
| WO2022206171A1 (zh) | 远程书写显示的方法、装置和存储介质 | |
| CN114764294B (zh) | 电子白板的页面元素操作方法、装置及设备 | |
| CN111966313A (zh) | 一种融合白板的实现方法、装置、设备和介质 | |
| KR102317091B1 (ko) | 영상 처리 장치 및 방법 |
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: 16915619 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 32PN | Ep: public notification in the ep bulletin as address of the adressee cannot be established |
Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 080819) |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 16915619 Country of ref document: EP Kind code of ref document: A1 |