[XviD-devel] 32Bit input pin / Alpha

Jan Lucas jan at lucas-berlin.de
Fri Jul 18 19:55:57 CEST 2003



Florian Schaper wrote:
> for my current Project (using DirectShow) I need a video-codec with
> an 32Bit input pin (to save an alpha channel).
> Most Videocodec's provide an 32Bit output pin (xvid thankfully
> already set's the alpha value to 255, thanks guy's ) but not an 32Bit
> input pin (talking still about directShow).
>
> I understand, that most people won't need alpha in their movies
> anyway but hey, here I am.
>
> The mpeg4 standard reads somewhat promissing, alpha for textures and
> so on, but I found no codec that would implement it.
>
> I don't know that much about what you guy's are fighting with, so all
> thats left for me is simply to ask you how difficult it would be to
> "upgrade" the existing xvid source to encode an 8Bit alpha channel as
> well? Is there no 32bit 'in', simply because nobody saw a need there
> to implement it? Or are there other (technical) reasons ? (besides
> maintaining more sections of code).
>
> Currently I'm using the huffyuv codec but since it work's lossless
> files get to big and performace is crappy.
> If there is no way xvid will support this in imminent future is there
> another codec that might fit my needs? (fast [playback that is] &
> small, like alway's)

I would suggest you just do a little workaround. Convert your X*Y RGBA
to a X*(Y*2) RGB Picture. In the top part of the image you save your
image data and in the bottom part you can save the alpha channel as a BW
image. If you really need real RGBA input you can write another small
directshow filter that converts between real RGBA and this fake RGBA.

                                    Jan



More information about the XviD-devel mailing list