POV-Ray : Newsgroups : povray.general : Merge TGA File POVRay Server Time
1 Nov 2024 19:17:09 EDT (-0400)
  Merge TGA File POVRay (Message 1 to 3 of 3)  
From: gaprie
Subject: Merge TGA File POVRay
Date: 17 May 2014 04:00:04
Message: <web.5377168227482bc52ebcdc450@news.povray.org>
Hello everyone,
I would like to ask, if I have 2 pieces of Povray rendering result of TGA images
and want to merge them into one whole image. Anyone ever tried?
For example, the object "pawns.pov" which has a pixel size of 400 (w) x300 (h),
I render into 2 parts:
"pawns_top.tga" (rendered from rows 1-150) with the command:
# Povray + W400 + H300 + SR1 +ER150 +FT +Opawns_top pawns.pov
"pawns_bottom.tga" (rendered from lines 151-300) with the command:
# Povray + W400 + H300 + SR151 +ER300 +FT +Opawns_bottom pawns.pov
And I wish I merge into "pawns.tga"
I have tried with the following command from the link
"http://povray.tashcorp.net/tutorials/qd_multicpu_render/"
# cp pawns_top.tga pawns.tga
# tail-c +19 pawns_bottom.tga >> pawns.tga
No error message,. But the merged image only contains images of paws_top.
Thank you for all your help ^ _ ^.
Regards,
Galih


Post a reply to this message

From: Le Forgeron
Subject: Re: Merge TGA File POVRay
Date: 17 May 2014 04:59:48
Message: <53772504$1@news.povray.org>
Le 17/05/2014 09:57, gaprie nous fit lire :
> Hello everyone,
> I would like to ask, if I have 2 pieces of Povray rendering result of TGA images
> and want to merge them into one whole image. Anyone ever tried?

It used to work, a long long time ago. No more.

> For example, the object "pawns.pov" which has a pixel size of 400 (w) x300 (h),
> I render into 2 parts:
> "pawns_top.tga" (rendered from rows 1-150) with the command:
> # Povray + W400 + H300 + SR1 +ER150 +FT +Opawns_top pawns.pov
> "pawns_bottom.tga" (rendered from lines 151-300) with the command:
> # Povray + W400 + H300 + SR151 +ER300 +FT +Opawns_bottom pawns.pov
> And I wish I merge into "pawns.tga"
> I have tried with the following command from the link
> "http://povray.tashcorp.net/tutorials/qd_multicpu_render/"
> # cp pawns_top.tga pawns.tga
> # tail-c +19 pawns_bottom.tga >> pawns.tga
> No error message,. But the merged image only contains images of paws_top.

Nope, the merged file contains bogus data whose only the first picture
remains accessible.

You moved from
 # header
 # data
 # extension
 # footer

to
 # header
 # data
 # extension
 # footer
 # data #2
 # extension #2
 # footer #2 (but now bogus)

Footer has information about the end of the data block

> Thank you for all your help ^ _ ^.
> Regards,
> Galih
> 

1. Partial images are put in full sized image (previously the partial
image was written as a smaller image. No more).

2. Extra data at the end of targa are ignored by most displaying program
which expect only v1 of the file format.
 v1 targa contains:
 # header
 # data

3. And to make it complete, version 2 of targa have a footer and
extension block (and since 2010, for gamma in file format, povray has
move from v1 to v2), so trick like the linked one are no more legit.

What's wrong with using a real image software to perform copy-paste ?


Post a reply to this message

From: jhu
Subject: Re: Merge TGA File POVRay
Date: 18 May 2014 02:25:00
Message: <web.53785115aad10d64fd3737aa0@news.povray.org>
"gaprie" <gap### [at] gmailcom> wrote:
> Hello everyone,
> I would like to ask, if I have 2 pieces of Povray rendering result of TGA images
> and want to merge them into one whole image. Anyone ever tried?
> For example, the object "pawns.pov" which has a pixel size of 400 (w) x300 (h),
> I render into 2 parts:
> "pawns_top.tga" (rendered from rows 1-150) with the command:
> # Povray + W400 + H300 + SR1 +ER150 +FT +Opawns_top pawns.pov
> "pawns_bottom.tga" (rendered from lines 151-300) with the command:
> # Povray + W400 + H300 + SR151 +ER300 +FT +Opawns_bottom pawns.pov
> And I wish I merge into "pawns.tga"
> I have tried with the following command from the link
> "http://povray.tashcorp.net/tutorials/qd_multicpu_render/"
> # cp pawns_top.tga pawns.tga
> # tail-c +19 pawns_bottom.tga >> pawns.tga
> No error message,. But the merged image only contains images of paws_top.
> Thank you for all your help ^ _ ^.
> Regards,
> Galih

See my other post in the images section. For command-line utilities you should
look into imagemagik.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.