Results 1 to 3 of 3

Thread: Open tga file

  1. #1
    Join Date
    Apr 2015
    Posts
    4
    Thanks
    1

    Default Open tga file

    I want to open tga images in my application but apparently, it's not possible by default in Qt and a tierce party plugin must be used.
    But I found in Qt files on Mac OS, in plugins/imageformats, the file libqtga.dylib. So I wondered if I can link this file in my project to read tga, and how (I didn't find any include files so I don't think it's possible) ?

    Thanks

  2. #2
    Join Date
    Jan 2008
    Location
    Alameda, CA, USA
    Posts
    5,230
    Thanks
    302
    Thanked 864 Times in 851 Posts
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: Open tga file

    TGA support is standard in Qt. There are no header files - you simply use the ones for QImage or whatever, and specify TGA format where needed. When you distribute your app, you must be sure to install the dynamic library in the correct location, and specified in the Qt deployment guide. Search the docs for Qt for OS X - Deployment.

  3. The following user says thank you to d_stranz for this useful post:

    SteveQt (12th June 2015)

  4. #3
    Join Date
    Apr 2015
    Posts
    4
    Thanks
    1

    Default Re: Open tga file

    OK thanks for your answer, I searched in Qt doc and indeed tga is supported by default (I should have read that instead of answers on another forum ).
    After trying to make it work without success, I read that in Qt doc : "TGA support only extends to reading non-RLE compressed files.". So I tested with a valid tga file and it's ok.

    Thanks again!
    Last edited by SteveQt; 12th June 2015 at 10:13.

Similar Threads

  1. Replies: 1
    Last Post: 7th May 2013, 00:34
  2. Replies: 1
    Last Post: 8th November 2010, 03:24
  3. Replies: 3
    Last Post: 1st November 2010, 16:33
  4. Replies: 5
    Last Post: 15th June 2010, 07:42
  5. Replies: 4
    Last Post: 9th May 2010, 16:18

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.