Loading TGAs into CImage

This is a discussion on Loading TGAs into CImage within the Windows Programming forums, part of the Platform Specific Boards category; Hi i wanted a program to quickly convert bunch of image files into another format(ex. bmp to jpg). So i ...

  1. #1
    Android
    Join Date
    Mar 2004
    Location
    Kurunegala Colony, Sri Lanka, Sri Lanka
    Posts
    362

    Loading TGAs into CImage

    Hi
    i wanted a program to quickly convert bunch of image files into another format(ex. bmp to jpg). So i added that functionality to the msdn sample "SimpleImage" (modified) - goto Tools>Convert Multiple Files.

    But now i have this set of TGA files that i want to convert to JPGs, but the GetExporterFilterString() function does not return TGA as an available image format (program uses CImage library). so CImage::Load() fails when trying to load TGAs. Does anyone know a way to load TGAs into an CImage object?

    Thanx.
    Some useless programs i've wrote : slprogrammersheaven
    Youtube: http://www.youtube.com/user/geekyzine
    My amature IT Blog: http://everything-geeky.blogspot.com/
    My Flash games: http://flashweed.blogspot.com/

    (and, sorry for my amature english)

  2. #2
    CSharpener vart's Avatar
    Join Date
    Oct 2006
    Location
    Rishon LeZion, Israel
    Posts
    6,484
    I would inherit my clas from the CImage and implement its fuctions for the TGA format using something like
    http://local.wasp.uwa.edu.au/~pbourke/dataformats/tga/
    for the source information...
    For all other formats I would call the base-class functions
    The first 90% of a project takes 90% of the time,
    the last 10% takes the other 90% of the time.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Cargo loading system
    By kyle rull in forum C Programming
    Replies: 1
    Last Post: 04-20-2009, 12:16 PM
  2. added start menu crashes game
    By avgprogamerjoe in forum Game Programming
    Replies: 6
    Last Post: 08-29-2007, 01:30 PM
  3. Loading a bitmap (Without using glaux)
    By Shamino in forum Game Programming
    Replies: 7
    Last Post: 03-16-2006, 08:43 AM
  4. Loading Screen
    By pinkcheese in forum Windows Programming
    Replies: 2
    Last Post: 04-06-2002, 10:48 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21