The present invention relates to a method and apparatus for moving an object in a mobile terminal. In particular, the present invention relates to a method and apparatus for moving an object from the current position to a target position at a speed varying according to the remained distance to the target position in response to a movement command for moving the object on the display screen of the mobile terminal.
Recently, the mobile terminal is becoming a multi-functional device that supports various supplementary functions such as electronic organizer function, game function, and schedule manager function. With the diversification of functions of the mobile terminal, it becomes more necessary to provide efficient user interface for facilitating the use of the various types of supplementary services.
Meanwhile, with the popularity of mobile terminals such as smartphone, there are many user requirements for convenient and useful interfaces that have been never introduced before.
There is therefore a need of an interface which rotates or moves the screen or object seamlessly in response to the change in screen orientation of the mobile terminal or the receipt of an object movement command.
The present invention has been conceived to solve the above problem, and it is an object of the present invention to provide a method and apparatus for moving, when an object movement command is received, the object from the current position to a target position with the movement distance per unit time which is set differently.
In more detail, it is an object of the present invention to provide a method and apparatus for moving an object smoothly from the view point of the user by calculating center point between the current position and the target position of the object gradually.
In accordance with an aspect of the present invention, an object movement method of a terminal includes displaying an object; receiving a movement command for moving the object; and moving the object from a current position to a target position at a speed varying according to a remained distance to the target position.
In accordance with another aspect of the present invention, a terminal includes a display unit which displays an object; an input unit which receives movement command for moving the displayed object; and a control unit which controls, in receipt of the movement command, moving the object from a current position to a target position at a speed varying according to a remained distance to the target position.
According to the present invention, the user is capable of experiencing smooth movement of the object.
In the following description, the term ‘object’ denotes any of things including image, motion picture, still picture, icon, and button, but not limited to the above enumerated items.
In the following description, the term ‘movement’ denotes any of actions including rotation of an object in accordance with the rotation of the mobile terminal, change of icon in position, and screen shift in response to image flip input, but not limited to the above-enumerated actions.
Exemplary embodiments of the present invention are described with reference to the accompanying drawings in detail. The same reference numbers are used throughout the drawings to refer to the same or like parts. Detailed description of well-known functions and structures incorporated herein may be omitted to avoid obscuring the subject matter of the present invention.
In the following, a description is made of the algorithm for calculating movement position (rotation angle) per unit time to provide the user with natural motion (rotation) when an object displayed on the screen is moved (rotated) in response to a user input. That is, the present invention proposes a method for calculating a position (rotation angle) changing gradually according to a certain environmental parameter with the input of current position (angle) and target position (angle) of the object based on a reference point.
The RF unit 110 is responsible for transmitting/receiving radio signals carrying data. The RF unit 110 can include an RF transmitter for up-converting and amplifying transmission signal and an RF receiver for low noise amplifying and down-converting the received signal. The RF unit 110 outputs the data received over the radio channel to the control unit 170 and transmits the data output by the control unit 110 over the radio channel.
The audio processing unit 120 can include a codec pack, and the codec pack can include a data codec for processing packet data and an audio codec for processing audio signal including voice. The audio processing unit 120 converts a digital audio signal to an analog audio signal by means of the audio codec to output the audio through a speaker (SPK) and converts the analog audio signal input through a microphone (MIC) to the digital audio signal by means of the audio codec.
The touchscreen unit 130 includes a touch panel 131 and a display panel 132. The touch panel 131 detects a touch input made by the user. The touch sensor can be implemented by one of a capacitive overlay, a resistive overlay, and an infrared beam, or a pressure sensor. The touch panel 131 also can be implemented with other types of sensing devices detecting contact or pressure made by an object. The touch panel 131 detects a touch input made by the user and generates a detection signal to the control unit 170. The detection signal includes the coordinates at which the touch input is detected. In case that the contact of the touch is moved, the touch panel 131 generates the detection signal including the coordinates on the path of the contact to the control unit 170.
The display panel 132 can be implemented with any of Liquid Crystal Display (LCD), Organic Light Emitting Diodes (OLED), and Active Matrix OLED (AMOLED) so as to provide the user with information such as menu of the mobile terminal 100, input data, and function setting information in the form of visual data. The display panel 132 outputs the booting screen, standby mode screen, menu screen, call progress screen, and various application execution screens.
Although the description is directed to the mobile terminal equipped with a touchscreen, the present invention can be applied to the mobile terminals implemented without touchscreen. In case of the mobile terminal having no touchscreen, the touchscreen unit 130 of
The key input unit 140 generates a key signal for controlling the mobile terminal 100 to the control unit 170 in response to the user's key manipulation. The key input unit 140 can be implemented with a keypad having numeric keys, navigation keys and functions keys arranged at a side of the mobile terminal. According to an embodiment of the present invention, when the mobile terminal 100 can be fully controlled only with the touchscreen unit 130, the key input unit 140 can be omitted.
The storage unit 150 is responsible for storing programs and data necessary for the operations of the mobile terminal 100 and can be divided into a program region and a data region. The program region stores the programs for controlling the entire operations of the mobile terminal, Operating System (OS) for booting up the mobile terminal 100, application programs related to the playback of multimedia contents and optional functions of the mobile terminal 100 such as camera function, audio playback function, still and motion picture playback function, etc. The data region stores the data generated in association with the operation of the mobile terminal 100 such as still and motion pictures, phonebook, and audio data.
The sensing unit 160 may include any of all the types of sensors capable of acquiring motion, impact, direction, and slop information of the mobile terminal. The sensing unit 160 may include a gyro censor, a motion sensor, a proximity sensor, etc.
The control unit 170 controls overall operations of the components of the mobile terminal. Particularly, when an object movement command is received, the control unit 170 sets the movement distance per unit time differently to move the object from the current position to a target position. In order to accomplish this, the control unit 170 further includes a movement direction and distance determiner 171, a per-unit time movement distance determiner 172, and a display position determiner 173.
If the object movement command is received, the movement direction and distance determiner 171 determines the movement direction and entire movement distance of the object. In more detail, the movement direction and distance determiner 171 sets the movement direction and entire movement distance of the object based on the target position and current position of the object.
In order to determine the movement direction, the movement direction and distance determiner 171 determines a first temporary value according to the sizes of the target position and current position. The movement direction and distance determiner 171 determines the difference value between the target and current positions and a second temporary value according to the size of the middle distance. Next, the movement direction and distance determiner 171 determines the multiplication result of the first and second temporary values. For example, if the multiplication result is a positive number, the object moves in an increasing direction and, otherwise, if the multiplication result is a negative number, the object moves in a decreasing direction.
The movement direction and distance determiner 171 calculates a difference value (D0) between the target and current positions. Next, the movement direction and distance determiner 171 determine the entire movement distance of the object according to the size of the difference value acquired by subtracting the distance value between the target and current positions from the maximum distance value (maximum distance value−D0). The entire movement distance determination procedure is described in detail with reference to
The per-unit time movement distance determiner 172 determines the distance to move per unit time within the entire movement distance. For this purpose, the per-unit time movement distance determiner 172 may set the value obtained by dividing the distance from the current position to the target position of the object with divisor value as the distance per unit time. In this case, the divisor value is a sum of the initial divisor value and increment divisor value, the increment divisor value increases sequentially whenever unit time elapses.
The display position determiner 173 calculates the position where the object is displayed on the screen based on whether the value to which the distance and direction of movement of the object from the current position is exceed the target position without deviating from the range on the screen.
Although the description is directed to the case where the control unit 170, the movement direction and distance determiner 171, the per-unit time movement distance determiner 172, and the display position determiner 173 are formed as separate blocks responsible for distinct functions for the convenience purpose but not limited to that configuration. For example, certain function of the movement direction and distance determiner 171 may be performed by the control unit 170 in itself.
First, the control unit 170 displays an object to be moved on the display panel of the mobile terminal 100 at step S210. The control unit 170 determines whether an object movement command is received at step S220. In this case, the control unit 170 may determine the receipt of the movement command based on whether the position of the object changes. The control unit 170 may also determine the receipt of the movement command based on whether the rotation of the mobile terminal is detected by means of the sensing unit 160.
If it is determined that the position of the object has changed, the control unit 170 initializes the parameters necessary for moving the object by setting the movement distance per unit time differently. The parameters are described later in detail.
Next, the control unit 170 determines whether the current position and the target position match each other at step S240. If the current and target positions match, this means that the object has moved to the target position completely and thus the procedure returns to step S210 because no more movement of the object is necessary.
Otherwise, if the current and target positions mismatch, this means that the object has to move further to reach the target object and thus the control unit 170 calculates the movement direction and distance at step S250.
Then the control unit 170 calculates the movement direction and the entire movement distance of the object at step S250. The procedure of calculating the movement direction and the entire movement distance of the object according to an embodiment of the present invention is described later with reference to
After calculating the movement direction and entire movement distance, the control unit calculates the movement distance per unit time at step S260. In this case, the control unit 170 may set the movement distance per unit time for the object variable. According to an embodiment of the present invention, this makes it possible to vary the movement speed of the object from the current position to the target position and thus the user feels that the object moves smoothly. Description on the step S260 for calculating the movement distance per unit time is made is made later in more detail with reference to
The control unit 170 calculates the position where the object is displayed on the screen based on whether the value obtained by applying the movement distance and direction to the current position of the object exceeds the target position in the range on the screen at step S270.
The control unit 170 moves the object according to the movement direction and the movement distance per unit time determined as above at step S280. The control unit 170 determines whether the target position of the object has changed at step S290.
If the target position has not changed, the control unit 170 returns the procedure to step S240 to adjust the movement distance per unit time based on the movement distance per unit time which has been set right before. Otherwise, if the target position has changed, the control unit 170 returns the procedure to step S230 to initialize the movement distance per unit time to the initial reference value.
As described above, the method according to an embodiment of the present invention checks whether the target position has changed even in moving the object and, if the target position has changed, initializes the parameters to calculate the movement direction and distance again. As a consequence, the user feels that the object moves smoothly.
In
First, a description is made of the process of calculating the movement direction of the object. In order to calculate the movement direction of the object, the control unit 170 determines whether the target and current positions match each other at step S310. If the target and current positions match, this means that there is no need of object movement and thus the procedure goes to step S315. The control unit 170 sets both the movement direction and movement distance to 0 and ends the procedure.
Otherwise, if the target and current positions mismatch, the control unit 170 determines whether the target position is greater than the current position at step S320. At this time, the control unit 170 compares the absolute coordinate values of the target position and the absolute coordinate values of the current position. For example, if the target position is upper right as compared to the current position, it is interpreted that the target position is greater than the current position on both the horizontal and vertical axes. For another example, if the target position is lower right as compared to the current position, it is interpreted that the target position is greater than the current position on the horizontal axis but less than the current position on the vertical axis. If the movement is rotation, the control unit may compare the target position and the current position in size of rotation angle. For example, if the current position is at 240 degree to a certain reference position in the clockwise direction and if the current position is at 30 degree to the reference position in the clockwise direction, this is interpreted that the target position is greater than the current position.
If it is determined that the target position is greater than the current position, the control unit 170 sets the first temporary value to 1 (positive integer) at step S325. Otherwise if it is determined that the target position is less than the current position, the control unit sets the first temporary value to −1 (negative integer) at step S330.
The control unit 170 determines the difference value between the target and current positions is equal to or less than a middle distance (MID_DIST) at step S335. If the movement is a rotation movement, the middle distance denotes the half of a 360 degree, i.e. 180 degree. Likewise, if the movement is a linear strain movement, the middle distance may denote the coordinates at the middle between bottom left point and the top right point on the screen. If the difference value is equal to or less than the middle distance value, the control unit 170 sets the second temporary value to 1 (positive integer) at step S340 and, otherwise if the difference value is greater than the middle distance value, the control unit 170 sets the second temporary value to −1 (negative integer).
The control unit 170 multiplies the first and second temporary values to acquire the movement direction value at step S350. Next, the control unit 170 determines whether the calculated movement direction value is 1 (positive integer) or −1 (negative integer) at step S355.
If the movement direction value is 1 (positive integer), the control unit 170 determines that the movement direction of the object is an increment direction at step S360. Otherwise, if the movement direction value is −1 (negative integer), the control unit 170 determines that the movement direction of the object is a decrement direction at step S365.
In this way, the control unit 170 calculates the first and second temporary values and determines the movement direction of the object based on the multiplication result of the two temporary values.
Meanwhile, the control unit 170 determines to calculate the movement distance of the object at step S370. In this case, the control unit 170 calculates the size (D0) of the difference value between the target position and the current position at step S375. Next, the control unit 170 compares the D0 value and the size of difference value (D1) between the maximum distance value (MAX_DIST) and D0. The maximum distance value corresponds to 360 degree for the rotation movement or coordinates values at the top right point on the screen for the linear strait movement.
If D0 is greater than D1, the control unit 170 sets the entire movement distance to D1 at step S380. Otherwise, if D0 is less than D1, the control unit 170 sets the entire movement distance to D0 at step S385.
A description is made of the order of acquiring the movement direction of the object in the exemplary case of part <a> of
In part <a> of
Hereinafter, a description is made of the order of acquiring the movement distance of the object in the example case of part <a> of
In part <a> of
In summary, the control unit 170 configures such that the object moves as much as d0 in the clockwise direction in the exemplary case of part <a> of
Hereinafter, a description is made of the order of acquiring the movement direction of the object in the exemplary case of part <b> of
In part <b> of
A description is made of the order of acquiring movement distance of an object in the exemplary case of part <b> of
In part <b> of
In summary, the control unit 170 configures such that the object moves as much as dl in the counterclockwise direction in the exemplary case of part <b> of
Hereinafter, a description is made of the order of calculating the movement direction of the object tin the exemplary case of part <c> of
In part <c> of
Hereinafter, a description is made of the order of calculating the movement distance of the object in part <c> of
In part <c> of
In summary, the control unit 170 configures such that the object moves as much as d0 in the clockwise direction in the exemplary case of part <c> of
Finally, a description is made of the order of acquiring the movement direction of the object in part <d> of
Since the current and target positions mismatch in part <d> of
Hereinafter, a description is made of the order of acquiring movement distance of the object in part <d> of
The control unit 170 compares the distance value D0 between the target and current positions with the difference value D1 between the maximum distance value and D0 to calculate the entire movement distance of the object. Since D0 is greater than D1 in part <d> of
In summary, the control unit 170 configures such that the object moves as much as dl in the counterclockwise direction.
A description is made of the principle of determining the objects' movement distance per unit time according to an embodiment of the present invention. The object's movement distance per unit time is determined by equation (1):
Movement distance per unit time=movement distance (DIST)/divisor (1),
where the movement distance (DIS) denotes the distance from the current position to the target position.
According to a preferred embodiment of the present invention, the movement distance decreases as time advances, and the divisor increases as time goes on. Accordingly, the object's movement distance per unit time decreases gradually. This means that the object moves fast at the time which the movement command is received, and the movement speed of the object decreases gradually as the object is drawn near the target position.
The procedure of determining object's movement distance per unit time is described with reference to
First, the control unit 170 sets the devisor according to equation 2 at step S510.
Divisor=initial divisor value (DIV_INIT)+increment divisor value (INC_DIV)*n(INTER)(n increment by 1 whenever unit time elapses) (2),
where the divisor denotes a certain parameter dividing the movement distance of the object (distance from the current position to the target position) in the current time duration.
The control unit 170 determines whether the value obtained by dividing the movement distance with the divisor is greater than a predetermined minimum movement distance at step S520. Here, the reason for setting the minimum movement distance is to have the object arrive the target position accurately.
If the value obtained by dividing the movement distance with the divisor is greater than the minimum movement distance, the control unit 170 sets the movement distance per unit time to the movement distance/divisor value according to equation (1) at step S530. Otherwise, if the value obtained by dividing the movement distance with the divisor is less than the minimum movement distance, the control unit 170 sets the movement distance per unit time to the minimum movement distance at step S540.
Although the description is directed to the case where the object's movement speed per unit time decreases as the object is drawn near the target position, it is also possible to implement the present invention in such a way that the movement speed per unit time increases as the object is drawn near the target. In this case, if the increment divisor value is set to a negative value in equation (2), the adviser value decreases whenever the unit time elapses and, as a consequence, the movement distance per unit time increases.
In part (a) of
In part (b) of
In part (c) of
As shown in part (d) of
According to an embodiment of the present invention, the operations of parts (c) and (d) of
Meanwhile, if the target position changes in the state that the object is moving, the time duration may be initialized to INTER=0 in part (a) of
As described above, it should be noted that when the increment divisor value is negative the movement distance per unit time increases gradually.
The object's movement distance per unit time id indicated by DELTA in
The distance (movement distance) from the current position to the target position is indicated by DIST. As shown in equation (1), the movement distance is in proportion to the movement distance per unit time, the curve is similar to that of
The divisor value is proportion to the increment divisor value (INC_DIV). Since it is assumed that the increment divisor value is 1 (positive value) in table 1, the divisor value forms a straight line having the slope of 1 in the graph.
The variation of the current position of the object has a relationship of inverse proportion to the object's movement speed per unit time. Referring to the graph of
Parts (a) to (d) of
Part (a) of
Part (c) of
The above descriptions on the various cases of movement speed variations of the object are just examples of the present invention but not limited thereto.
The control unit 170 sets a temporary position of the object using equation (3) at step S1205.
Temporary position (TMP)=current position (CUR_POS)+movement distance per unit time (DELTA)*movement direction value (DIR) (3)
The control unit 170 determines whether the temporary position is greater than the maximum distance value at step S1210. If the temporary position is greater than the maximum distance value, this means that the position where the object is displayed is out of the display region of the display panel of the mobile terminal or the object rotates an angle equal to or greater than 360 degree. In this case, the control unit 170 updates the old temporary position to a new temporary position with the value obtained by subtracting the maximum distance value from the old temporary position.
Otherwise if the temporary position is not greater than the maximum distance value, the control unit 170 determines whether the temporary position is less than a minimum distance value at step S1220. If the temporary position is less than the minimum distance value, this means that that the position where the object is displayed is out of the display region of the display panel of the mobile terminal or the object rotates in the inverse direction. In this case, the control unit 170 updates the old temporary position to a new temporary position with the value obtained by adding the maximum distance value to the old temporary position.
The control unit determines whether the object's movement direction value is 1 (increment direction) and whether the target position is greater than the current position at step S1230. If the object's movement direction value is 1 and if the target position is greater than the current position, the control unit 170 sets the final temporary position to the minimum value between the temporary position and the target position at step 1235.
Otherwise, if the conditions of step 1230 are not fulfilled, the control unit 170 determines whether the object's movement direction value is −1 (decrement direction) and if the current position is greater than the target position at step S1240. If the object's movement direction value is set to −1 and if the current position is greater than the target position, the control unit 170 sets the final temporary position to the maximum value between the temporary position and the target position.
Otherwise, if the conditions of step S1240 are not fulfilled or after step S1235 of step S1245, the control unit 170 determines the current position to the temporary position (determined at previous step) at step S1250.
In this case, the mobile terminal may set the image's rotation speed per unit time variable as shown in
The mobile terminal may receive the icon movement command for moving the icon from the current position 1410 to the target position 1420. Then the mobile terminal may sets the icon's movement speed per the unit time variable as shown in
Although
According to the present invention, if the object movement command is received, the mobile terminal sets the movement distance per unit time to a value variable as time advance such that the object is moved from the current position to the target position and then displayed at the target position. With this operation, the user is capable of experiencing smooth movement of the object. Since the movement distance per unit time is calculated at every drawn timing, if the target position changes in the state that the object is moving, the movement distance is recalculated in real time in response to the repeated user input.
The specification and drawings are to be regarded in an illustrative rather than a restrictive sense in order to help understand the present invention. It is obvious to those skilled in the art that various modifications and changes can be made thereto without departing from the broader spirit and scope of the invention.
Number | Date | Country | Kind |
---|---|---|---|
10-2012-0077265 | Jul 2012 | KR | national |
Filing Document | Filing Date | Country | Kind |
---|---|---|---|
PCT/KR2013/006299 | 7/15/2013 | WO | 00 |