SMPEG on nano-X

Hi,

I’ve got this problem with the colors using the MPEG player that
compiles with the SMPEG library package. I’m using Nano-X 0.89pre8,
SDL version 1.1.3 and SMPEG 0.4.0 and the problem is that my platform/
device has the pixelformat 0444 (in nanox I converted MWPF_TRUECOLOR565
functions to suit my 0444 platform) and I probably have to do something
similar in SDL to accomodate my 0444 but I don’t quite know where to do
the necessary changes in SDL code.

I admit that I’m a bit lost with all the blit/pixel functions. In
microwindows I only had to change one definition namely the
COLOR2PIXEL565© (in /src/include/device.h) from

(((© & 0xf8) >> 3) | ((© & 0xfc00) >> 5) | ((© & 0xf80000) >> 8))

to

(((© & 0xf0) << 4) | ((© & 0xf000) >> 8) | ((© & 0xf00000) >> 20))

get the colours right and I’m kinda hoping to get away with a similar
modification for SDL.

This is my configuration script for SDL 1.1.3 (I’m crosscompiling to an
ARM device):
AR=/atools/local/bin/arm-linux-ar CC=/atools/local/bin/arm-linux-gcc
CXX=/atools/local/bin/arm-linux-c++
RANLIB=/atools/local/bin/arm-linux-ranlib
STRIP=/atools/local/bin/arm-linux-strip ./configure arm-linux
–host=i686-pc-linux-gnu --libdir=/atools/local/arm-linux/lib
–includedir=/atools/local/arm-linux/include
–prefix=/atools/local/arm-linux --disable-shared --disable-esdtest
–disable-nasm --disable-video-dga --disable-pthread-sem
–enable-video-microwin --disable-video-x11 --disable-video-opengl
–disable-video-x11-vm --disable-video-x11-dgamouse --disable-video-x11-xv

The plaympeg player works fine otherwise but the colours are wrong and I’d
really appreciate if somebody could give me a hint where and what should
I change in SDL.–
Juha Haapakorpi @Haapakorpi_Juha

Haapakorpi Juha wrote:

I’m using Nano-X 0.89pre8,
SDL version 1.1.3 and SMPEG 0.4.0 and the problem is that my platform/
device has the pixelformat 0444

SDL should support that pixel format without problem (if slowly), but it’s
quite possible that nobody has tried it before so please report any bugs
you find

Since we’ll probably move to another way of specifying pixel formats
in 1.3, it would be interesting to know what kind of device you are using,
with that odd format

Haapakorpi Juha wrote:

I’m using Nano-X 0.89pre8,
SDL version 1.1.3 and SMPEG 0.4.0 and the problem is that my platform/
device has the pixelformat 0444

SDL should support that pixel format without problem (if slowly), but it’s
quite possible that nobody has tried it before so please report any bugs
you find

Since we’ll probably move to another way of specifying pixel formats
in 1.3, it would be interesting to know what kind of device you are using,
with that odd format

Also make sure you’re using SDL 1.2.3

See ya,
-Sam Lantinga, Software Engineer, Blizzard Entertainment

hi!

I want to know ,if your smpegplayer can play audio with video , thanks?
zhengyue

http://www.eyou.com
–??? ??? ??? ??? ???..???