Embedding editText value on Image The 2019 Stack Overflow Developer Survey Results Are In Unicorn Meta Zoo #1: Why another podcast? Announcing the arrival of Valued Associate #679: Cesar Manara The Ask Question Wizard is Live! Data science time! April 2019 and salary with experienceIs Java “pass-by-reference” or “pass-by-value”?Sort a Map<Key, Value> by valuesLazy load of images in ListViewHow to get an enum value from a string value in Java?How do I determine whether an array contains a particular value in Java?Stop EditText from gaining focus at Activity startupPlace cursor at the end of text in EditTextHow to send image from one activity to another in android?Android: Multiple image viewE/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException for (No such file or directory)

What do I do when my TA workload is more than expected?

Make it rain characters

Are spiders unable to hurt humans, especially very small spiders?

Why did Peik Lin say, "I'm not an animal"?

What was the last x86 CPU that did not have the x87 floating-point unit built in?

Huge performance difference of the command find with and without using %M option to show permissions

How to make Illustrator type tool selection automatically adapt with text length

Word to describe a time interval

Why are PDP-7-style microprogrammed instructions out of vogue?

Circular reasoning in L'Hopital's rule

ELI5: Why do they say that Israel would have been the fourth country to land a spacecraft on the Moon and why do they call it low cost?

Is it ok to offer lower paid work as a trial period before negotiating for a full-time job?

Example of compact Riemannian manifold with only one geodesic.

Deal with toxic manager when you can't quit

Using dividends to reduce short term capital gains?

Can withdrawing asylum be illegal?

Word for: a synonym with a positive connotation?

What happens to a Warlock's expended Spell Slots when they gain a Level?

What's the point in a preamp?

Can each chord in a progression create its own key?

Button changing its text & action. Good or terrible?

Can the Right Ascension and Argument of Perigee of a spacecraft's orbit keep varying by themselves with time?

Working through the single responsibility principle (SRP) in Python when calls are expensive

Mortgage adviser recommends a longer term than necessary combined with overpayments



Embedding editText value on Image



The 2019 Stack Overflow Developer Survey Results Are In
Unicorn Meta Zoo #1: Why another podcast?
Announcing the arrival of Valued Associate #679: Cesar Manara
The Ask Question Wizard is Live!
Data science time! April 2019 and salary with experienceIs Java “pass-by-reference” or “pass-by-value”?Sort a Map<Key, Value> by valuesLazy load of images in ListViewHow to get an enum value from a string value in Java?How do I determine whether an array contains a particular value in Java?Stop EditText from gaining focus at Activity startupPlace cursor at the end of text in EditTextHow to send image from one activity to another in android?Android: Multiple image viewE/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException for (No such file or directory)



.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








0















I am to upload a random image from my gallery to Firebase storage. Before uploading, I am to caption the image. I was wondering how I could embed the caption (edittext value) into the image, and in the process maybe create a new image file which is a combination of the original image and the caption. So that upon uploading, the image file that will be stored in storage is the image plus the embedded caption. Think of it as the way you can caption an instagram story, like in the attached screenshot.enter image description here



Here is the code that I use to get the selected image from gallery



 @Override
protected void onActivityResult(int requestCode, int resultCode, Intent data)
{
super.onActivityResult(requestCode, resultCode, data);

if(requestCode==Gallery_Pick && resultCode==RESULT_OK && data!=null)


PostDescription.setVisibility(View.VISIBLE);


ImageUri = data.getData();
SelectPostImage.setImageURI(ImageUri);



...
then in uploading the image to Firebase storage



 StorageReference filePath = PostsImagesRefrence.child("Post_Images").child(ImageUri.getLastPathSegment() + timesfm + ".jpg");
filePath.putFile(ImageUri).addOnCompleteListener(new OnCompleteListener<UploadTask.TaskSnapshot>()
@Override
public void onComplete(@NonNull Task<UploadTask.TaskSnapshot> task)

if(task.isSuccessful())

downloadUrl = task.getResult().getDownloadUrl().toString();
Toast.makeText(PostActivity.this, "Success!!", Toast.LENGTH_SHORT).show();

SavingToDb();


else

String message = task.getException().getMessage();
Toast.makeText(PostActivity.this, "Error occured: " + message, Toast.LENGTH_SHORT).show();


);


Any help will be appreciated. Thank you.










share|improve this question




























    0















    I am to upload a random image from my gallery to Firebase storage. Before uploading, I am to caption the image. I was wondering how I could embed the caption (edittext value) into the image, and in the process maybe create a new image file which is a combination of the original image and the caption. So that upon uploading, the image file that will be stored in storage is the image plus the embedded caption. Think of it as the way you can caption an instagram story, like in the attached screenshot.enter image description here



    Here is the code that I use to get the selected image from gallery



     @Override
    protected void onActivityResult(int requestCode, int resultCode, Intent data)
    {
    super.onActivityResult(requestCode, resultCode, data);

    if(requestCode==Gallery_Pick && resultCode==RESULT_OK && data!=null)


    PostDescription.setVisibility(View.VISIBLE);


    ImageUri = data.getData();
    SelectPostImage.setImageURI(ImageUri);



    ...
    then in uploading the image to Firebase storage



     StorageReference filePath = PostsImagesRefrence.child("Post_Images").child(ImageUri.getLastPathSegment() + timesfm + ".jpg");
    filePath.putFile(ImageUri).addOnCompleteListener(new OnCompleteListener<UploadTask.TaskSnapshot>()
    @Override
    public void onComplete(@NonNull Task<UploadTask.TaskSnapshot> task)

    if(task.isSuccessful())

    downloadUrl = task.getResult().getDownloadUrl().toString();
    Toast.makeText(PostActivity.this, "Success!!", Toast.LENGTH_SHORT).show();

    SavingToDb();


    else

    String message = task.getException().getMessage();
    Toast.makeText(PostActivity.this, "Error occured: " + message, Toast.LENGTH_SHORT).show();


    );


    Any help will be appreciated. Thank you.










    share|improve this question
























      0












      0








      0








      I am to upload a random image from my gallery to Firebase storage. Before uploading, I am to caption the image. I was wondering how I could embed the caption (edittext value) into the image, and in the process maybe create a new image file which is a combination of the original image and the caption. So that upon uploading, the image file that will be stored in storage is the image plus the embedded caption. Think of it as the way you can caption an instagram story, like in the attached screenshot.enter image description here



      Here is the code that I use to get the selected image from gallery



       @Override
      protected void onActivityResult(int requestCode, int resultCode, Intent data)
      {
      super.onActivityResult(requestCode, resultCode, data);

      if(requestCode==Gallery_Pick && resultCode==RESULT_OK && data!=null)


      PostDescription.setVisibility(View.VISIBLE);


      ImageUri = data.getData();
      SelectPostImage.setImageURI(ImageUri);



      ...
      then in uploading the image to Firebase storage



       StorageReference filePath = PostsImagesRefrence.child("Post_Images").child(ImageUri.getLastPathSegment() + timesfm + ".jpg");
      filePath.putFile(ImageUri).addOnCompleteListener(new OnCompleteListener<UploadTask.TaskSnapshot>()
      @Override
      public void onComplete(@NonNull Task<UploadTask.TaskSnapshot> task)

      if(task.isSuccessful())

      downloadUrl = task.getResult().getDownloadUrl().toString();
      Toast.makeText(PostActivity.this, "Success!!", Toast.LENGTH_SHORT).show();

      SavingToDb();


      else

      String message = task.getException().getMessage();
      Toast.makeText(PostActivity.this, "Error occured: " + message, Toast.LENGTH_SHORT).show();


      );


      Any help will be appreciated. Thank you.










      share|improve this question














      I am to upload a random image from my gallery to Firebase storage. Before uploading, I am to caption the image. I was wondering how I could embed the caption (edittext value) into the image, and in the process maybe create a new image file which is a combination of the original image and the caption. So that upon uploading, the image file that will be stored in storage is the image plus the embedded caption. Think of it as the way you can caption an instagram story, like in the attached screenshot.enter image description here



      Here is the code that I use to get the selected image from gallery



       @Override
      protected void onActivityResult(int requestCode, int resultCode, Intent data)
      {
      super.onActivityResult(requestCode, resultCode, data);

      if(requestCode==Gallery_Pick && resultCode==RESULT_OK && data!=null)


      PostDescription.setVisibility(View.VISIBLE);


      ImageUri = data.getData();
      SelectPostImage.setImageURI(ImageUri);



      ...
      then in uploading the image to Firebase storage



       StorageReference filePath = PostsImagesRefrence.child("Post_Images").child(ImageUri.getLastPathSegment() + timesfm + ".jpg");
      filePath.putFile(ImageUri).addOnCompleteListener(new OnCompleteListener<UploadTask.TaskSnapshot>()
      @Override
      public void onComplete(@NonNull Task<UploadTask.TaskSnapshot> task)

      if(task.isSuccessful())

      downloadUrl = task.getResult().getDownloadUrl().toString();
      Toast.makeText(PostActivity.this, "Success!!", Toast.LENGTH_SHORT).show();

      SavingToDb();


      else

      String message = task.getException().getMessage();
      Toast.makeText(PostActivity.this, "Error occured: " + message, Toast.LENGTH_SHORT).show();


      );


      Any help will be appreciated. Thank you.







      java android






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Mar 8 at 12:27









      Ezra RaleighEzra Raleigh

      155




      155






















          0






          active

          oldest

          votes












          Your Answer






          StackExchange.ifUsing("editor", function ()
          StackExchange.using("externalEditor", function ()
          StackExchange.using("snippets", function ()
          StackExchange.snippets.init();
          );
          );
          , "code-snippets");

          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "1"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55063242%2fembedding-edittext-value-on-image%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Stack Overflow!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55063242%2fembedding-edittext-value-on-image%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          1928 у кіно

          Захаров Федір Захарович

          Ель Греко