[Sumover-dev] Re: [Media Tools] #76: yellow tint with vic built on PowerPC mac

Media Tools SUMOVER-dev at cs.ucl.ac.uk
Thu Jun 7 18:26:16 BST 2007


#76: yellow tint with vic built on PowerPC mac
---------------------------------+------------------------------------------
  Reporter:  eolson at mcs.anl.gov  |       Owner:  socrates         
      Type:  defect              |      Status:  new              
  Priority:  major               |   Milestone:                   
 Component:  vic                 |     Version:  vic-branch-mpeg4 
Resolution:                      |    Keywords:  yellow vic endian
---------------------------------+------------------------------------------
Changes (by eolson at mcs.anl.gov):

  * keywords:  yellow vic => yellow vic endian

Comment:

 Thanks for the pointer Doug.

 It looks like the endian test is failing in render/color-true.cpp
   ImageByteOrder(dpy_) == LSBFirst

 ImageByteOrder(dpy_) returns a large number instead of 0 or 1 for me.
 I'm not sure why that doesn't work well.  It could be that not using OSX
 X11 caused something to change.

 In any case, putting a different endian test in the file fixed things for
 me:
    if(isLittleEndian())

 which is a pretty common function:

 Here's one:
   http://unixpapa.com/incnote/byteorder.html

 I'll paste one I've used in case it's easier than adapting that code.

 bool isBigEndian() {
    short word = 0x4321;[[BR]]
    return ((*(char *)& word) != 0x21 );
 [[BR]]}

 bool isLittleEndian(){ return ! isBigEndian(); }

-- 
Ticket URL: <https://frostie.cs.ucl.ac.uk/mbone/mmedia/ticket/76>
Media Tools <http://www-mice.cs.ucl.ac.uk/multimedia/software>
Media Tools


More information about the Sumover-dev mailing list