Jump to content

Get 2D position on screen from a visible 3D point


Road Kill Kenny
 Share

Recommended Posts

Hi all,

 

The title is rather self explanatory but I'll elaborate. I'm trying to find out how to get a 2D XY point on the screen from a visible XYZ position in space.

 

See what I am trying to do is make a data driven cinematic / story event class which goes through a bunch of data and does certain actions depending on the data and steps through a bunch of different actions in sequence.

 

So one of the actions that I want to create is for a 2D cartoon like text bubble to pop up adjacent to a 3D character. Now I know the character position and if I can determine what that position is in 2D on the screen I'll be able to easily position the text bubble so it is pointing to the character.

 

So any idea's? Its sort of like I need the opposite of a CameraPick.

STS - Scarlet Thread Studios

AKA: Engineer Ken

 

Fact: Game Development is hard... very bloody hard.. If you are not prepared to accept that.. Please give up now!

Link to comment
Share on other sites

AMD Bulldozer FX-4 Quad Core 4100 Black Edition

2 x 4GB DDR3 1333Mhz Memory

Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5

Windows 7 Home 64 bit

 

BlitzMax 1.50 • Lua 5.1 MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro

3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET

 

LE 2.5/3.4 • Skyline UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0

 

Marleys Ghost's YouTube Channel Marleys Ghost's Blog

 

"I used to be alive like you .... then I took an arrow to the head"

Link to comment
Share on other sites

No worries Ken, its the same command I used for NPC AI labels, so I could see what was on their minds lol

 

 

http://www.leadwerks.com/werkspace/topic/2538-cameraunproject-entity-labels/

AMD Bulldozer FX-4 Quad Core 4100 Black Edition

2 x 4GB DDR3 1333Mhz Memory

Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5

Windows 7 Home 64 bit

 

BlitzMax 1.50 • Lua 5.1 MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro

3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET

 

LE 2.5/3.4 • Skyline UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0

 

Marleys Ghost's YouTube Channel Marleys Ghost's Blog

 

"I used to be alive like you .... then I took an arrow to the head"

Link to comment
Share on other sites

No worries Ken, its the same command I used for NPC AI labels, so I could see what was on their minds lol

 

 

http://www.leadwerks...-entity-labels/

 

That's a great idea! I'll be coding the AI for npc's in about a month or two and I'll be sure to use that XD

 

thanks.

STS - Scarlet Thread Studios

AKA: Engineer Ken

 

Fact: Game Development is hard... very bloody hard.. If you are not prepared to accept that.. Please give up now!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...