Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by ks13 · Dec 20, 2011 at 03:41 PM · textimage

Text to image

Hello, i'm asked to make a module that takes a string, and adds it on an image, like captions. The goal here is to put text on different images of a gallery depending on the author or language chosen by the user. Does unity have a method/function to do this?

Comment
Add comment · Show 2
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image ks13 · Dec 21, 2011 at 08:40 AM 0
Share

Thank you for the suggestion, i will try to use it for what was of me. But you should put your advice as an aswer so i can select is as a correct answer.

avatar image asafsitner · Dec 21, 2011 at 09:27 AM 0
Share

Glad I could help. =)

2 Replies

· Add your reply
  • Sort: 
avatar image
1
Best Answer

Answer by asafsitner · Dec 20, 2011 at 05:21 PM

While you can certainly access the pixel array of an image, I believe it would be far easier to implement with a Text Mesh object:

http://unity3d.com/support/documentation/Components/class-TextMesh.html

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
0

Answer by jahroy · Dec 20, 2011 at 05:17 PM

Personally, I would approach this by using Unity's GUI system.

I would draw a label with text either below, next to, or on top of the texture.

http://unity3d.com/support/documentation/ScriptReference/GUI.Label.html

If you really have to create a texture from your text, that's a different story.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image ks13 · Dec 21, 2011 at 08:39 AM 0
Share

I already thought about that but the reason they ask me for an image is so that it could be placed on the walls beside the images. So when someone is strolling around the gallery the image should be in 3D, and GUI.Label is 2D. So i think the Text$$anonymous$$esh suggested by asafsitner is a better option.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

6 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Print char to a 2D image? 1 Answer

Why isn't the text preferred size calculating correctly? 0 Answers

Instantiated UI objects with image components not appearing, rest of object works fine. 0 Answers

Some questions regarding card game 2 Answers

Can I add text and image in a content like a document? 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges