[go: up one dir, main page]

HK1082085B - Device and method for image processing - Google Patents

Device and method for image processing Download PDF

Info

Publication number
HK1082085B
HK1082085B HK06104006.8A HK06104006A HK1082085B HK 1082085 B HK1082085 B HK 1082085B HK 06104006 A HK06104006 A HK 06104006A HK 1082085 B HK1082085 B HK 1082085B
Authority
HK
Hong Kong
Prior art keywords
line
image processing
perspective transformation
coordinate
model
Prior art date
Application number
HK06104006.8A
Other languages
Chinese (zh)
Other versions
HK1082085A1 (en
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
Priority claimed from JP2004184233A external-priority patent/JP4560711B2/en
Application filed by 世嘉股份有限公司 filed Critical 世嘉股份有限公司
Publication of HK1082085A1 publication Critical patent/HK1082085A1/en
Publication of HK1082085B publication Critical patent/HK1082085B/en

Links

Description

Image processing apparatus and method
Technical Field
The present invention relates generally to image processing technology, and more particularly to an image processing method used in a game application program and a computer game of a home game device.
Background
There is a soccer game which is a game program of a conventional home game device. In this soccer game, field lines (white lines) are constructed by a plurality of polygons to which a white line texture is added. In this procedure, a viewpoint is defined in a common coordinate system, and a screen image of a line in the field of this coordinate system as seen from the viewpoint is subjected to perspective transformation and rendered in a frame buffer. When the viewpoint is far from the line and the angle of looking at the line from the viewpoint is small relative to the line, the line may become a width of one dot or less due to the resolution of the display device in the game device, and inconvenience may be caused because the line may become discontinuous or displayed in dots on the screen.
To overcome such a problem, as disclosed in japanese patent document 2955989, a polygon of a line located on a field is inclined to increase an area when viewed from a viewpoint.
Further, fig. 8 is a diagram explaining why a line object cannot be accurately displayed. It is assumed that eight triangular polygons will be displayed closely as shown in fig. 8 (2). Each of the symbols □ ■ a shown in fig. 8(1) represents one pixel on the screen. Since each triangle (1 to 8 in fig. 8 (2)) is closely arranged, the pixel ■ will overlap with an adjacent triangle. To avoid such overlap, whether to display the pixel ■ is determined according to a particular operation. As a result, a situation may occur in which the edges of the polygon are not properly represented. As the area of the polygon decreases, the ratio of pixels representing edges will increase and thus the accuracy of the polygon will deteriorate. Thus, elongated polygons are sometimes displayed as dots or not at all.
Disclosure of Invention
An object of the present invention is to provide an image processing technique capable of clearly displaying lines on a field on a screen regardless of a distance to a viewpoint or a visual direction.
In order to achieve the above object, the present invention is an image processing method of an image processing apparatus having an image processing operation unit that executes: a step of arranging a straight line or curved line model formed of a polygon in a coordinate system of a three-dimensional virtual space based on an image processing program stored in a memory; setting a viewpoint in a coordinate system; a step of performing perspective transformation on the model viewed from the viewpoint; and a step of rendering, in the rendering memory, another line having a fixed width superimposed on the perspective-transformed image of the model based on the coordinate position after the perspective transformation of the model; the other line is drawn with a fixed width at the coordinate position where the model is subjected to the perspective transformation, regardless of the position occupied by the width in the coordinate where the model is subjected to the perspective transformation.
According to the present invention, even if the width of the straight line model (object) after perspective transformation is smaller than a value to be displayed on the display device, such as shown in fig. 8, or if the width cannot be displayed due to an algorithm, since another line (separate line) having a fixed width is displayed at the position of the line object, there is an advantage in that a player can always see the field line; for example, the boundary (line) of the game field in a ball game, such as a soccer game, regardless of the position of the virtual viewpoint. When the width of the line object after the perspective transformation is smaller than a displayable value, the width of the additional line to be drawn is sufficient only by the amount of one pixel (one dot).
The additional line having one dot width connects a plurality of pixels on the display in a line shape (straight line, curved line, circular line, etc.), and is preferably displayed as a line to which a line texture having one dot width is applied. Data corresponding to such texture is set in an area of a predetermined pixel of the frame buffer. White lines are preferably used as such texture.
The present invention also relates to a program that causes a computer to execute each of the above-described steps, and a recording medium having such a program recorded thereon.
Further, the present invention is an image processing apparatus having a memory storing an image processing program, and an arithmetic unit executing image processing based on the program, the arithmetic unit including: a unit that arranges a straight line or curved line model formed of polygons in a coordinate system of a three-dimensional virtual space based on an image processing program stored in a memory; a unit that sets a viewpoint in a coordinate system; a unit that performs perspective transformation on the model viewed from the viewpoint; and a unit that superimposes and draws another line having a fixed width on the perspective-converted image of the model based on the coordinate position after the perspective conversion of the model in the drawing memory; this additional line is drawn with a fixed width at the coordinate position where the model is subjected to the perspective transformation, regardless of the position occupied by the width in the coordinate where the model is subjected to the perspective transformation.
Further, the present invention is an image processing method in an image processing apparatus configured to read out object data from a storage unit and arrange the same in a three-dimensional virtual space, and output a two-dimensional projection image of an object viewed from a prescribed viewpoint, wherein the object is a line object formed of polygons and constitutes a straight line, a line segment, or a curve having a prescribed width in the three-dimensional virtual space; a storage unit that stores start point position coordinate data and end point position coordinate data that are further set corresponding to position coordinates of a line object in a three-dimensional virtual space; the image processing program includes: a step of arranging line objects in a three-dimensional virtual space; a step of performing two-dimensional perspective transformation on the linear object and the start point position coordinates and the end point position coordinates from the viewpoint position; and a step of drawing a line segment connecting the start point position coordinate and the end point position coordinate after the two-dimensional perspective transformation with a fixed width by overlapping the two-dimensional perspective transformation image of the line object.
According to the present invention, since a straight line having a prescribed width connecting position coordinates of both ends of a line object can be drawn in a frame buffer by superimposing on a two-dimensional perspective-transformed image of the line object, an image of the line object will always be displayed on a display unit even when the line object becomes one pixel or less after, for example, undergoing perspective transformation.
Further, the present invention is an image processing method in an image processing apparatus configured to read out object data from a storage unit and arrange them in a three-dimensional virtual space, and output a two-dimensional projection image of an object viewed from a prescribed viewpoint, wherein a line texture drawn as a straight line, a line segment, or a curved line having a prescribed width in the two-dimensional projection image is added to the object; a storage unit that stores start point position coordinate data and end point position coordinate data that are further set corresponding to position coordinates of a line texture in a three-dimensional virtual space; the image processing program includes: a step of arranging objects in a three-dimensional virtual space; a step of performing two-dimensional perspective transformation on the object and the start point position coordinates and the end point position coordinates from the viewpoint position; and a step of drawing a line segment connecting the start point position coordinate and the end point position coordinate after the two-dimensional perspective transformation with a fixed width by overlapping the two-dimensional perspective transformation image of the object.
Drawings
FIG. 1 is a block diagram of a gaming device employing the present invention;
FIG. 2 is a view showing a frame format (frame format) of a model employing the line of the present invention;
FIG. 3 is a schematic diagram showing a state in which another line having a width of one dot is placed on a line object;
fig. 4 is a schematic diagram showing a case where perspective transformation is performed on a line object based on a viewpoint;
fig. 5 is a diagram showing a display image (1) of a line object when a perspective-transformed image of the line object is smaller than a displayable range, and a display image (2) of another line having a dot width;
FIG. 6 is a flow chart showing a line display operation;
FIG. 7 is a schematic diagram illustrating a display operation of additional lines when the line model is a loop;
fig. 8 is a schematic diagram showing an example of the drawing operation of the line model.
Detailed Description
Fig. 1 is a block diagram of a game device as one example of an image processing device of the present invention. The game apparatus 100 has a storage device or storage medium (including an optical disk and an optical disk drive) 101 for storing game programs and data (including video and audio data), a CPU 102 for executing the game programs and controlling the entire system and performing coordinate calculation for displaying images, a system memory 103 for storing programs and data required for the CPU 102 to perform processing, a BOOTROM 104 for storing programs and data required to start the game apparatus 100, and a bus arbiter 105 for controlling programs and data flows of respective modules of the game apparatus 100 or externally connected devices, which are connected through a bus, respectively.
A rendering processor 106 is connected to the bus, and video (movie) data read out from a program data storage device or storage medium 101 and an image created according to the operation of a player or the progress of a game are displayed on a display 110 by the rendering processor 106. Graphics data and the like required for creating an image by the rendering processor 106 are stored in a graphics memory (frame buffer) 107.
A sound processor 108 is connected to the bus, and audio data read out from the program data storage device or the storage medium 101 and sound effects and audio created according to the operation of the player or the progress of the game are output from a speaker 111 through the sound processor 108. Audio data and the like required for the sound processor 108 to generate sound are stored in the sound memory 109.
The game apparatus 100 is connected to the modem 112, and can communicate with other game apparatuses 100 and a network server via a telephone line (not shown). Further, a backup memory 113 (including a disk storage medium and a storage device) for recording information of the progress of the game and program data input/output through a modem, and a controller 114 for inputting information to the game apparatus 100 to control the game apparatus 100 and an external connection device according to the operation of the player are also connected to the game apparatus 100. The CPU and the rendering processor constitute an image arithmetic processing unit.
In order to achieve the specific object of the image processing to which the present invention is applied, a field is defined in a three-dimensional virtual space in an application such as a soccer game using a game apparatus as shown in fig. 1. The image processing of the present invention is applied to the lines that make up the field.
Fig. 2 is a plan view showing a state in which a line object 202 is placed in a field 200. This line object is composed of a plurality of polygons, and when the line object is displayed on the display 110, a white line texture is added to the polygons after perspective transformation. Coordinates in a three-dimensional virtual space of a model of a line (line object) composed of polygons are defined in a game program. Further, data for changing the coordinates of the virtual viewpoint is stored in the game program. The line object is subjected to perspective transformation based on the coordinates of the virtual viewpoint, and a texture is applied to the position of the perspective-transformed line object.
Fig. 3 is a plan view showing an example of image display of a line object, and shows a state in which another line 204 having a width of one point is placed on a plurality of or a single polygon 202 constituting the line object. This additional line defines two points: i.e., the start point and the end point of the position coordinates of the polygon corresponding to the line object in the common coordinate system (e.g., the middle point of the narrow sides at both ends of the line object, the vertex coordinates at both ends in the width direction, etc.), and is defined by connecting the two points by a straight line having a point width. The start point and the end point are defined in relative coordinate systems of each polygon, and when the polygons are placed in the virtual three-dimensional space, coordinate systems in the virtual space of the start point and the end point are defined.
As shown in fig. 4, the line object 202 is arranged on the field 200 in the three-dimensional virtual space (common coordinate system), and is very close to the field or slightly away from the field in the upward direction (Y-axis direction). The lines of the polygon viewed from the virtual viewpoint 210 are subjected to perspective transformation (transformation into two-dimensional coordinates), and the line objects are rendered in the graphics memory based on the transformed coordinates.
Meanwhile, for the other lines, the CPU or the rendering processor calculates coordinates of the perspective-transformed start point 206 and end point 208 in the virtual coordinate system, and associates the corresponding pixels in the graphic memory with the start point and the end point. Subsequently, the image processing operation unit determines a plurality of pixels connecting the start point and the end point with a straight line, and defines all connections of these pixels as a drawn image of another line.
In fig. 4, the width of the line object viewed from the viewpoint will become smaller the further the viewpoint 210 moves in the direction of the arrow, i.e., the farther it is from the line object and approaches the field 200, and the width of the line object viewed from the viewpoint will become smaller than the displayable width of the display device when the viewpoint moves in the direction of the arrow.
Fig. 5(1) is a diagram showing a display screen of a line viewed from a viewpoint when the viewpoint 210 shown in fig. 4 is far from the line polygon and the viewpoint position is close to the field. When the view of the line polygon 202 becomes smaller than the pixel level, or due to arithmetic processing relating to the pixels constituting the sides of the polygon of the line object, a phenomenon such as the line becoming a shape of a point (202A) or the line being cut off (202B) will occur. Fig. 5(2) is a view in a frame format showing a view of the entire line in a case where an additional line shown in fig. 5 is drawn, and this additional line is not displayed after perspective transformation based on the viewpoint 210, but is forcibly drawn in a fixed width in the graphic memory. Therefore, even when the polygon appears as a broken line, the other line can be clearly displayed on the screen. Since the line itself is displayed narrow in this case, it is sufficient that the width of the other line is at least one pixel (dot).
Fig. 6 is a flowchart relating to the operation of the image processing by the game device shown in fig. 1 based on the above description. At S700, the image processing arithmetic unit determines a viewpoint position and a visible direction, and at S702, it performs perspective transformation on the three-dimensional virtual space field and the line object. At S704, the positions on the screen coordinates of the start point and the end point of the additional line are determined, and at S706, a plurality of pixels in the graphic memory connecting the start point and the end point are determined. At S708, the line object and the additional line are overlapped and drawn. Next, at S710, characters (such as players and balls) are drawn on the line.
In addition, in the above description, although the description describes a case where another line is a straight line, it may be a curved line. In fig. 7, processing is performed such that the object is an approximate circle (polygon) formed by a plurality of polygons 600. A plurality of start points 603 and end points 604 are arranged corresponding to this circular object and further lines 602 are drawn connecting these start and end points. A plurality of additional lines are connected to form an approximately circular outer shape along the circular line object. In addition, although the start point and the end point are defined for all polygons in fig. 7, the start point and the end point may be defined as a single polygon connecting the polygons.
Further, although the lines are illustrated as white lines arranged on the field, long objects (such as strings) may be used as the lines.
In the above embodiment, although it is possible to display another line on the line object regardless of how the line object looks after the perspective conversion, it is possible to display another line even when the width of the line object after the perspective conversion becomes smaller than the displayable width.
In the above-described embodiment, although the width of the additional line is made to be the amount of one pixel in the display coordinate system, it is not limited thereto, and it is preferable that the width of the additional line is displayed as the width of one pixel or several pixels in consideration that the line object is displayed as an intermittent line when the line object is reduced and displayed.

Claims (4)

1. An image processing method of an image processing apparatus including an image processing arithmetic unit,
the image processing operation unit executes:
a step of arranging a straight line or curved line model formed of a polygon in a coordinate system of a three-dimensional virtual space based on an image processing program stored in a memory;
a step of setting a viewpoint in the coordinate system;
a step of performing perspective transformation on the model viewed from the viewpoint; and
a step of rendering a further line having a fixed width on the perspective-transformed image of the model in a superimposed manner based on the coordinate position of the model after perspective transformation in a rendering memory;
wherein the additional line is drawn to be overlapped with a fixed width at a coordinate position after the perspective transformation of the model, regardless of a position occupied by the width in the coordinate after the perspective transformation of the model.
2. An image processing apparatus includes a memory for storing an image processing program and an arithmetic unit for performing image processing according to the program,
the arithmetic unit includes:
means for arranging a straight line or curved line model formed of a polygon in a coordinate system of a three-dimensional virtual space based on an image processing program stored in a memory;
means for setting a viewpoint in the coordinate system;
means for performing a perspective transformation on the model as seen from the viewpoint; and
a means for rendering a further line having a fixed width in a rendering memory so as to be superimposed on the perspective-transformed image of the model, based on the coordinate position of the model after perspective transformation;
wherein the additional line is drawn to be overlapped with a fixed width at a coordinate position after the perspective transformation of the model, regardless of a position occupied by the width in the coordinate after the perspective transformation of the model.
3. An image processing method in an image processing apparatus configured to read out object data from a storage device and arrange them in a three-dimensional virtual space, and output a two-dimensional projection image of the object as viewed from a prescribed viewpoint,
wherein the object is a line object formed of a polygon and constitutes a straight line, a line segment, or a curve having a prescribed width in a three-dimensional virtual space;
the storage means stores start point position coordinate data and end point position coordinate data which are further set corresponding to position coordinates of a line object in a three-dimensional virtual space; and
the image processing method comprises the following steps:
a step of arranging the line objects in a three-dimensional virtual space;
a step of performing two-dimensional perspective transformation on the line object and the start point position coordinates and end point position coordinates from the viewpoint position; and
and drawing a line segment connecting the start position coordinate and the end position coordinate after the two-dimensional perspective transformation with a fixed width by superimposing the line segment on the two-dimensional perspective transformation image of the line object.
4. An image processing method in an image processing apparatus configured to read out object data from a storage device and arrange them in a three-dimensional virtual space, and output a two-dimensional projection image of the object as viewed from a prescribed viewpoint,
wherein a line texture drawn as a straight line, a line segment, or a curve having a prescribed width in the two-dimensional projection image is added to the object;
the storage means stores start point position coordinate data and end point position coordinate data further set corresponding to position coordinates of the line texture in the three-dimensional virtual space; and
the image processing method comprises the following steps:
a step of arranging the objects in the three-dimensional virtual space;
a step of performing two-dimensional perspective transformation on the object and the start point position coordinates and end point position coordinates from the viewpoint position; and
and drawing a line segment connecting the start position coordinate and the end position coordinate after the two-dimensional perspective transformation with a fixed width, the line segment being superimposed on the two-dimensional perspective transformation image of the object.
HK06104006.8A 2004-06-22 2006-03-31 Device and method for image processing HK1082085B (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2004-184233 2004-06-22
JP2004184233A JP4560711B2 (en) 2004-06-22 2004-06-22 Image processing

Publications (2)

Publication Number Publication Date
HK1082085A1 HK1082085A1 (en) 2006-05-26
HK1082085B true HK1082085B (en) 2008-07-25

Family

ID=

Similar Documents

Publication Publication Date Title
US12400393B2 (en) Method and system for rendering panoramic video
JP4180065B2 (en) Image generation method, image generation apparatus, and image generation program
US7333108B2 (en) Entertainment apparatus, object display device, object display method, recording medium and character display method
JP2005293122A (en) Game software with function to display large-surface object, and game device
JP5044549B2 (en) Three-dimensional game display system, display method, and display program
CN100357975C (en) Image processing
JP2001178963A5 (en)
EP2034446A1 (en) Image processing program and image processor
EP1533753B1 (en) Method for drawing an object that changes transparency
JP4513423B2 (en) Object image display control method using virtual three-dimensional coordinate polygon and image display apparatus using the same
US8345001B2 (en) Information processing system, entertainment system, and information processing system input accepting method
US7847754B2 (en) Image processing program and image display device
US20100156932A1 (en) Method for inserting moving picture into 3-dimension screen and record medium for the same
HK1082085B (en) Device and method for image processing
WO2011070946A1 (en) Image processing method and computer-readable recording medium
US7173618B2 (en) Image creation program and method of creating image
CN116437061A (en) Demonstration image laser projection method, device, computer equipment and storage medium
JP2002092635A (en) Image processing device
JP2002262178A (en) Video display device
CN109814703A (en) A kind of display methods, device, equipment and medium
JP3048130B2 (en) Pseudo three-dimensional image display device and pseudo three-dimensional image display method
JP2002251626A (en) Method for generating image and program used for the same
JP6823946B2 (en) How to draw figures, drawing devices and simulators
CN117915057A (en) Image processing method and virtual reality display system
JP2003015214A (en) Image display device