Displaying a Bitmap

ThePentiumGuy

Senior Contributor
Joined
May 21, 2003
Messages
1,113
Location
Boston, Massachusetts
hey

in d3d, ive tried displaying a bitmap..
i figured out that you gotta move the vertices around to adjust to the size of the bitmap(30x30)

Visual Basic:
        verts(0) = CreateFlexVertex(0, 0, 0, Color.Transparent.ToArgb, 0, 0)
        verts(1) = CreateFlexVertex(30, 0, 0, Color.Transparent.ToArgb, 1, 0)
        verts(2) = CreateFlexVertex(0, 30, 0, Color.Transparent.ToArgb, 0, 1)
        verts(3) = CreateFlexVertex(30, 30, 0, Color.Transparent.ToArgb, 1, 1)

the above displays a big green square,
changing the 30's to 1's, you can see the image a little better
but if you change the 1's to .3 or something, he becomes easeir to see

any idea what values would work for this? or am i doing this wrong altogether?

note, the file's attached, binaries are there to get the path for the images, but theres no EXEs
 

Attachments

i have - .05 pretty small, you can barely see the image now
even still, the image doesnt look like it should be, its somewhat twisted and backward..

- atm, idk how to use cameras right now

quick reply tho :-p

thx
 
you know what?

i just realized the problem, i was displaying the image using World Coordinates o_O

i needed to use ScreenCoordinates by changing the vertex type from

CustomVertex.PositionTextured to CustomVertex.TransformedTextured

that was really stupid on my part...
sry
 
Back
Top