Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. How to capture image with .png extension using qml camera
Forum Updated to NodeBB v4.3 + New Features

How to capture image with .png extension using qml camera

Scheduled Pinned Locked Moved QML and Qt Quick
4 Posts 3 Posters 2.1k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    beemaneni
    wrote on last edited by
    #1

    Hi i need to capture an image with .png extension ,where as it gives default as jpg.How do i do that...

    Here is my code:
    @cameraObj.imageCapture.captureToLocation("/tmp/xxx.png")@

    The above code captures image to destination path ,bt the format is .jpg..
    The output looks like ... @ xxx.png.jpg@

    Please help me if anyone knows the solution

    Thanks in Advance

    Bala B
    Infinite Computer systems
    Chennai

    1 Reply Last reply
    0
    • p3c0P Offline
      p3c0P Offline
      p3c0
      Moderators
      wrote on last edited by
      #2

      Hi,

      I don't think so that is available. IMO jpeg's are fine for photography. Just capture a high resolution image.
      Otherwise you can convert jpeg to PNG explicitly.

      157

      1 Reply Last reply
      0
      • dheerendraD Offline
        dheerendraD Offline
        dheerendra
        Qt Champions 2022
        wrote on last edited by
        #3

        Hi Bala

        Which platform did you try ? I tried on Mac and able to save file with png extension.

        Dheerendra
        @Community Service
        Certified Qt Specialist
        http://www.pthinks.com

        1 Reply Last reply
        0
        • B Offline
          B Offline
          beemaneni
          wrote on last edited by
          #4

          Hi p3c0,Dheerendra,

          Thanks for reply..
          I am working on ubuntu and cross compiling to android.wen i give that it saves with .jpg extension nly

          Thanks
          Bala Beemaneni

          Bala B
          Infinite Computer systems
          Chennai

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved