With freepv you can view equirectangular, cubic, cylindrical, QTVR
and SPiV panoramas using OpenGL hardware acceleration. This
functionality is available as a standalone viewer, a firefox/mozilla
plugin and as a shared library. Here's a screenshot of the plugin
running on Linux:
http://www.flickr.com/photos/36383814@N00/2307900843/
(see if you can spot Yuval and Pablo)
The branch that needs testing is currently only available via SVN:
svn co https://freepv.svn.sourceforge.net/svnroot/freepv/freepv/branches/branch_leonox/
The build system uses cmake similar to hugin:
cd branch_leonox
cmake .
make
make install
That's it, bug reports, patches etc... can be sent to the freepv
tracker:
http://sourceforge.net/tracker/?group_id=148373
--
Bruno
A few questions:
"make install" prints out a few lines saying:
-- Install configuration: ""
What's this supposed to mean ?
The Mozilla plugin was renamed from libnsfreepv.so to libnpfreepv.so,
compared to the original freepv-0.1. Is this wanted ?
Somebody out there who has experience how to compile the plugin as a
32Bit shared lib on a 64Bit Linux system ? Reason is that I have to
run a 32Bit Firefox 'cause there is only a 32Bit Java plugin available
from Sun which cannot be wrapped with the nspluginwrapper.
Bruno Postle wrote:
> That's it, bug reports, patches etc... can be sent to the freepv
> tracker:
> http://sourceforge.net/tracker/?group_id=148373
Submitted one: 1911568 (Cmake cannot find GECKO SDK)
Rgds,
Stephan.
I just compiled it successfully on Debian Lenny/Testing. cmake was
complaining that it wasn't finding the GECKO SDK, but
GECKO_ROOT_DIR=/usr/include/iceape/ cmake .
fixed that.
Testing the standalone freepv-glut and freepv-glx with an
euquirectangular jpg, I realize that it's a lot slower than panoglview
with the same panoroma, even to the point that it is not useable with
larger window sizes.
Is there something I am doing wrong?
Regards,
Felix
No idea, cmake does it here too - Seems to be harmless.
>The Mozilla plugin was renamed from libnsfreepv.so to libnpfreepv.so,
>compared to the original freepv-0.1. Is this wanted ?
I think Pablo changed it a while ago, it could just be a typo but it
doesn't do any harm.
>Somebody out there who has experience how to compile the plugin as a
>32Bit shared lib on a 64Bit Linux system ?
It depends on your distribution, on fedora I would do this with a
mock chroot, the debian equivalent is 'mach' I think.
>Reason is that I have to run a 32Bit Firefox 'cause there is only a
>32Bit Java plugin available from Sun which cannot be wrapped with
>the nspluginwrapper.
Are you sure this is necessary anymore? I have 64bit java here, it
plays ptviewer etc...
>Submitted one: 1911568 (Cmake cannot find GECKO SDK)
Thanks, the gecko detection is fragile, I'll ask for more info via
the tracker.
--
Bruno
Thanks I've added this path. Iceape is what debian call firefox? I
thought it was iceweasel or something.
>Testing the standalone freepv-glut and freepv-glx with an
>euquirectangular jpg, I realize that it's a lot slower than panoglview
>with the same panoroma, even to the point that it is not useable with
>larger window sizes.
I don't have a comparison of the code, but I suspect that this part
of freepv isn't so well optimised - freepv is definitely in the
middle of the features->bugfixes->optimisation cycle.
--
Bruno
Bruno Postle wrote:
>> Somebody out there who has experience how to compile the plugin as a
>> 32Bit shared lib on a 64Bit Linux system ?
>
> It depends on your distribution, on fedora I would do this with a
> mock chroot, the debian equivalent is 'mach' I think.
Thanks, I'll check this out.
> Are you sure this is necessary anymore? I have 64bit java here, it
> plays ptviewer etc...
Yes, I've checked today with SDK 6u5, 64Bit. It works perfectly fine
with other applications. But there is still no java plugin for mozilla
or firefox in the distribution.
Rgds,
Stephan.
I think the old freepv build system worked on OS X, so this is
something that needs to be fixed in cmake - I'm not in a position to
do this for OS X.
>And as a side note: why use "cmake ." and not "mkdir build; cd build; cmake
>.." to keep your source tree clean ? Is there a specific reason for?
Nope, that is just the usual cmake build instructions. Both methods
should work fine (else that is a bug).
--
Bruno
*** snippet ***
IF (APPLE)
# These values for Apple could probably do with improvement.
FIND_PATH( GLUT_INCLUDE_DIR glut.h
/System/Library/Frameworks/GLUT.framework/Versions/A/Headers
${OPENGL_LIBRARY_DIR}
)
SET(GLUT_glut_LIBRARY "-framework Glut" CACHE STRING "GLUT library
for OSX")
SET(GLUT_cocoa_LIBRARY "-framework Cocoa" CACHE STRING "Cocoa
framework for OSX")
ELSE (APPLE)
FIND_PATH( GLUT_INCLUDE_DIR GL/glut.h
/usr/include
/usr/include/GL
/usr/local/include
/usr/openwin/share/include
/usr/openwin/include
/usr/X11R6/include
/usr/include/X11
/opt/graphics/OpenGL/include
/opt/graphics/OpenGL/contrib/libglut
)
FIND_LIBRARY( GLUT_glut_LIBRARY glut
/usr/lib
/usr/local/lib
/usr/openwin/lib
/usr/X11R6/lib
)
FIND_LIBRARY( GLUT_Xi_LIBRARY Xi
/usr/lib
/usr/local/lib
/usr/openwin/lib
/usr/X11R6/lib
)
FIND_LIBRARY( GLUT_Xmu_LIBRARY Xmu
/usr/lib
/usr/local/lib
/usr/openwin/lib
/usr/X11R6/lib
)
ENDIF (APPLE)
*** snippet ***
The complete "script" is at
http://www.cmake.org/cgi-bin/viewcvs.cgi/*checkout*/Modules/FindGLUT.cmake?view=auto&root=CMake&revision=1.19
I'll try some more but if one of you guru's see it right away, please
be my guest and patch the code.
Harry
2008/3/11, Bruno Postle <br...@postle.net>:
On 11/03/2008, Bruno Postle <br...@postle.net> wrote:
> >I just compiled it successfully on Debian Lenny/Testing. cmake was
> >complaining that it wasn't finding the GECKO SDK, but
> > GECKO_ROOT_DIR=/usr/include/iceape/ cmake .
> >fixed that.
>
> Thanks I've added this path. Iceape is what debian call firefox? I
> thought it was iceweasel or something.
iceape is the unbranded seamonkey in Debian. I digged a bit further
and found out that building against iceape probably is not the right
thing to do, sorry for that.
Similar to OpenSuSE it should be build against xulrunner, so on Debian
testing GECKO_ROOT_DIR should be /usr/lib/xulrunner.
I successfully build it and tested the plugin with the provided test
cases. It's working very well (and fast) with test.html and
test_qt_embed.html, but fails on test_cube.html and cubeYuval.htm:
> iceweasel test_cube.html
Starting freepv, revision: $Revision: 119 $
a scene was created
ERROR: 23:17:43.555320 (plugin_unix.cpp:508) glSwapBuffers(): OpenGL
Error: 1281, invalid value
state 4: downloading: outside_000000.jpg
ERROR: 23:17:43.556466 (plugin_unix.cpp:350) SetWindow(): Could not
get XtAppContext from mozilla, trying XtDisplayToApplicationContext
state 4: 371350 bytes downloaded
state 7: IMAGE decoding error: outside_000000.jpg
state 7: 255036 bytes downloaded
ERROR: 23:17:43.739871 (PanoViewer.cpp:302) onDownloadComplete():
INVALID state after downloading to memory
> iceweasel cubeYuval.htm
Starting freepv, revision: $Revision: 119 $
a scene was created
ERROR: 23:18:55.355851 (plugin_unix.cpp:508) glSwapBuffers(): OpenGL
Error: 1281, invalid value
state 3: downloading dswmedia/SPi-V.dcr
Downloading: dswmedia/SPi-V.dcr
ERROR: 23:18:55.357327 (plugin_unix.cpp:508) glSwapBuffers(): OpenGL
Error: 1281, invalid value
state 7: download failed: dswmedia/SPi-V.dcr
ERROR: 23:18:55.357875 (plugin_unix.cpp:350) SetWindow(): Could not
get XtAppContext from mozilla, trying XtDisplayToApplicationContext
> >Testing the standalone freepv-glut and freepv-glx with an
> >euquirectangular jpg, I realize that it's a lot slower than panoglview
> >with the same panoroma, even to the point that it is not useable with
> >larger window sizes.
>
> I don't have a comparison of the code, but I suspect that this part
> of freepv isn't so well optimised - freepv is definitely in the
> middle of the features->bugfixes->optimisation cycle.
A bit more testing shows that this is only happens for the mouse
controls. If the viewer window size is increased the movement as a
reaction to mouse drag is first getting jerky. Increase the window
size even more and there is no reaction to mouse movements any more.
BTW:
I seem to have strange problems with cmake when trying to "make
install" freepv. The output claims it is installing everything, but it
only installs every now and then and I have not yet understood what
the necessary conditions are. Could be some problem of my system,
though.
Felix
Do you mean /usr/include/xulrunner ?
>> iceweasel test_cube.html
>state 7: IMAGE decoding error: outside_000000.jpg
>state 7: 255036 bytes downloaded
>ERROR: 23:17:43.739871 (PanoViewer.cpp:302) onDownloadComplete():
>INVALID state after downloading to memory
Yep, same here.
>> iceweasel cubeYuval.htm
>Starting freepv, revision: $Revision: 119 $
>a scene was created
>ERROR: 23:18:55.355851 (plugin_unix.cpp:508) glSwapBuffers(): OpenGL
>Error: 1281, invalid value
>state 3: downloading dswmedia/SPi-V.dcr
Did you fetch SPi-V.dcr separately? This isn't in SVN as it is a
shockwave file - Though it isn't processed, so any .dcr file should
do as well.
I can't get SPi-V to work here anyway, so this is a bug.
>A bit more testing shows that this is only happens for the mouse
>controls. If the viewer window size is increased the movement as a
>reaction to mouse drag is first getting jerky. Increase the window
>size even more and there is no reaction to mouse movements any more.
I see the same on the Eee, the mouse control is basically unusable,
but the arrow keys work well enough.
--
Bruno
Not me, Leon Moctezuma did the summer of code work, I'm just trying
to get it into a state where it builds for most people and can be
released.
It is completely usable and stable as a QTVR firefox plugin on my
fedora system (and 256MB video card), but that doesn't mean that it
works generally.
>How can I provide additional feedback? I can provide debug
>information(when I start firefox from the console) and tell if I bump
>to some panoramas where it crashes...
The freepv tracker is the best place:
http://sourceforge.net/tracker/?group_id=148373
>Here are some problems that occured:
>1.) I am not sure, but there is something wrong with firefox plugin or
>I have some problems running it, because it does not work.
>[00000390] main access debug: connection in progress
>[00000390] access_http access debug: protocol 'HTTP' answer code 206
>[00000390] access_http access debug: Server: Apache
>[00000390] access_http access debug: stream size=1807689
>[00000390] access_http access debug: Content-Type: video/quicktime
>[00000393] ffmpeg decoder error: more than 5 seconds of late video ->
>dropping frame (computer too slow ?)
This looks like some other plugin is trying to show the quicktime
content and failing - freepv doesn't use ffmpeg.
Where did it put the plugin? Older versions of firefox don't look
in /usr/local/lib/mozilla/plugins and need it in
/usr/lib/mozilla/plugins
>2.) There is also a problem when viewing this:
>http://panoramas.dk/2008/oscars.html
>...look directly above the viewpoint - sky is strangely distorded.
Yes it is distorted in the original even if I use Apple QuickTime.
>3.)When viewing panorama: using keyboard only(directional keys), I can
>only move the viewpoint up-down and not left-right. Is this a bug or
>this feature is not yet implemented?
I added arrow key navigation, looks like it doesn't work quite as I
intended.
--
Bruno
I shouldn't post when having a cold and being tired...
You are right, it's /usr/include/xulrunner.
> Did you fetch SPi-V.dcr separately? This isn't in SVN as it is a
> shockwave file - Though it isn't processed, so any .dcr file should
> do as well.
> I can't get SPi-V to work here anyway, so this is a bug.
No, I didn't fetch SPi-V.dcr. I just did and as you said it's not
working anyway.
Felix
Before I submit this as a bug, I'd like to know if I'm running freepv
correctly here:
~/work/freepv/branches/branch_leonox $ ./src/freepv-glx/freepv-glx
cube_front="outside_000000.jpg" cube_right="outside_000001.jpg"
cube_back="outside_000002.jpg" cube_left="outside_000003.jpg"
cube_top="outside_000004.jpg" cube_bottom="outside_000005.jpg"
XF86VidModeExtension-Version 2.2
Got Doublebuffered Visual!
glX-Version 1.3
Depth 24
Congrats, you have Direct Rendering!
before processing events
Starting freepv, revision: $Revision: 119 $
a scene was created
ERROR: 19:07:34.696471 (glx_platform.cpp:349) glSwapBuffers(): OpenGL
Error: 1281, invalid value
state 4: downloading: outside_000000.jpg
ERROR: 19:07:34.698321 (glx_platform.cpp:349) glSwapBuffers(): OpenGL
Error: 1281, invalid value
state 7: download failed: outside_000000.jpg
Type=22
Type=22
Type=19
Type=12
Type=6
...
~/work/freepv/branches/branch_leonox $ ./src/freepv-glut/freepv-glut
cube_front="outside_000000.jpg" cube_right="outside_000001.jpg"
cube_back="outside_000002.jpg" cube_left="outside_000003.jpg"
cube_top="outside_000004.jpg" cube_bottom="outside_000005.jpg"
before processing events
Starting freepv, revision: $Revision: 119 $
a scene was created
state 4: downloading: outside_000000.jpg
state 7: download failed: outside_000000.jpg
glutMouseMotion, pos: 497, 412
glutMouseMotion, pos: 493, 416
glutMouseMotion, pos: 485, 426
glutMouseMotion, pos: 473, 440
glutMouseMotion, pos: 465, 458
glutMouseMotion, pos: 461, 476
glutMouseMotion, pos: 461, 502
In both cases I only get a black window with text saying: "download
failed: outside_000000.jpg"
FYI: I'm using SVN checkout from revision 137.
--
Libre Software:
http://www.gnu.org/philosophy/free-sw.html
It's "monkey see, monkey do" here too as far as cmake scripts go, so
if you can figure this out for OS X then that would be great.
--
Bruno
>state 4: downloading: outside_000000.jpg
>state 7: download failed: outside_000000.jpg
Actually I get a different error, are you sure you are passing the
correct image paths?:
state 4: downloading: outside_000000.jpg
state 4: 371350 bytes downloaded
state 7: IMAGE decoding error: outside_000000.jpg
state 7: 255036 bytes downloaded
ERROR: 23:45:45.521451 (PanoViewer.cpp:302) onDownloadComplete():
INVALID state after downloading to memory
..anyway I've created a tracker item for this.
--
Bruno
As far as I can tell from reading signatures.cpp, the code will
always detect QTVR unless it has already detected JPEG or PNG. So
SPiV never gets detected, indeed both /dev/null and /etc/passwd are
both interpreted as QTVR.
--
Bruno
As someone else already mentioned: I'll be back.
Harry
2008/3/15, Bruno Postle <br...@postle.net>:
there is no such thing as detecting SPiV. It's an XML file that points
to one or more JPGs.
I am pretty much sure that it worked with branch leonox and the test
case that is in there
$ ./freepv-glut ../../testcases/good/spiv/mini.xml
I'll have a look when I reboot into Linux later.
Yuv
The file detection logic for the command-line tool never detects XML
and always interprets it as QTVR:
./freepv-glut ../../testcases/good/spiv/mini.xml
...
state 3: downloading testcases/good/spiv/mini.xml
state 3: file testcases/good/spiv/mini.xml downloaded
FILE type:QTVR
ReadMovieAtom: fread() failed!
state 7: Error during QTVR parsing: No panorama found
I'm not great with C++, but my interpretation of
src/libfreepv/Utils/signatures.cpp is that it will detect JPEG and
PNG but then decide that everything else is QTVR.
The plugin doesn't do SPi-V either, though about:plugins lists it ok
(I have no trouble with QTVR content):
application/x-director Schockwave dcr Yes
Most SPi-V pages don't work because the server runs a javascript
plugin detection that doesn't recognise freepv, but even with pages
that don't, freepv decides that the SPi-V content is actually QTVR:
http://wiki.panotools.org/Help:Pano-Tag_SPi-V_Example
"Error during QTVR parsing: No panorama found"
--
Bruno
>I checked the code that you modified, it actually didn't solved the problem,
>it just made the function to recognize all the files as QTVR, the fact that
>it was not doing that with JPEG and PNG files is because the function checks
>their signature first, then goes with QTVR, then tries XML and then DCR,
>I modified the code to a state similar toe revision 119
Ok I see how I broke it (sorry) and I think I see why the unbroken
code doesn't recognise many QTVR files. Basically it is checking
for the string 'moov' as the second four bytes, but the QuickTime
spec doesn't require that the first atom is a 'moov' atom, in fact
it can be one of several:
http://wiki.multimedia.cx/index.php?title=QuickTime_container#Known_Top-Level_Atoms
--
Bruno
Leon Moctezuma wrote:
> Hi, I didn't know about this group :)
sorry, that was one of my mistakes with last year's GSoC organization -
communication was fragmented on devel mailing lists and into private
mentor-students email, and this year will be better since the students
are all here.
Bruno Postle wrote:
> Most SPi-V pages don't work because the server runs a javascript
> plugin detection that doesn't recognise freepv, but even with pages
> that don't, freepv decides that the SPi-V content is actually QTVR:
My code detects freepv - it even discern the new version (QTVR+SPiV)
from the old version (QTVR only).
<http://www.photopla.net/070618assnat/> worked last summer
the error I am experiencing is with the offline test - just after making
and before installing.
./freepv-glut ../../testcases/good/spiv/mini.xml
Leon Moctezuma wrote:
> I modified the code to a state similar toe revision 119
I tried with revision 142 and
./freepv-glut ../../testcases/good/spiv/mini.xml
still does not work. interestingly it reports $Revision: 119 $ ?
yuv@yuv-desktop:~/src/freepv/src/freepv-glut$ ./freepv-glut
../../testcases/good/spiv/mini.xml
before processing events
Starting freepv, revision: $Revision: 119 $
a scene was created
state 3: downloading ../../testcases/good/spiv/mini.xml
state 3: file ../../testcases/good/spiv/mini.xml downloaded
FILE type:XML
The file to download is global.xml
Dowloading: global.xml
state 3: file global.xml downloaded
FILE type:Unknown
state 7: internal error: invalid state after downloading to file
I tried 119
had to manually set GECKO_NSPR_DIR to /usr/includes/nspr at the ccmake
stage. While researching it, I found that you had searched the issue
last year too :-)
<http://www.cmake.org/pipermail/cmake/2007-November/017396.html>
have you received a useful answer?
Anyway, 119 does not build on my Ubuntu 7.10 AMD64 box:
[ 75%] Built target freepv
Scanning dependencies of target freepv-glut
[ 78%] Building CXX object
src/freepv-glut/CMakeFiles/freepv-glut.dir/freepv-glut.o
/home/yuv/src/freepv/src/libfreepv/PanoViewer.h: In function ‘int
main(int, char**)’:
/home/yuv/src/freepv/src/libfreepv/PanoViewer.h:43: error:
‘FPV::PanoViewer::PanoViewer()’ is private
/home/yuv/src/freepv/src/freepv-glut/freepv-glut.cpp:136: error: within
this context
/home/yuv/src/freepv/src/libfreepv/PanoViewer.h:44: error: ‘virtual
FPV::PanoViewer::~PanoViewer()’ is private
/home/yuv/src/freepv/src/freepv-glut/freepv-glut.cpp:136: error: within
this context
make[2]: *** [src/freepv-glut/CMakeFiles/freepv-glut.dir/freepv-glut.o]
Error 1
make[1]: *** [src/freepv-glut/CMakeFiles/freepv-glut.dir/all] Error 2
make: *** [all] Error 2
123 builds and has the same symptom as 142.
Yuv
>My code detects freepv - it even discern the new version (QTVR+SPiV)
>from the old version (QTVR only).
>
><http://www.photopla.net/070618assnat/> worked last summer
Yes this works with the latest code (after Leon fixed the bugs I
added), both if I select QTVR or SPi-V.
Though I can't view any SPi-V on fieldofview.com, due to the plugin
not being detected:
http://fieldofview.com/pano-fullscreen/
Aldo?
>the error I am experiencing is with the offline test - just after making
>and before installing.
>
>./freepv-glut ../../testcases/good/spiv/mini.xml
>state 3: file global.xml downloaded
>FILE type:Unknown
>state 7: internal error: invalid state after downloading to file
This is a bug with path processing, it's ok if the xml file is in
the current directory:
cd testcases/good/spiv
../../../src/freepv-glx/freepv-glx mini.xml
--
Bruno
>the error I am experiencing is with the offline test - just after making
>and before installing.
>
>./freepv-glut ../../testcases/good/spiv/mini.xml
>state 3: file global.xml downloadedThis is a bug with path processing, it's ok if the xml file is in
>FILE type:Unknown
>state 7: internal error: invalid state after downloading to file
the current directory:
cd testcases/good/spiv
../../../src/freepv-glx/freepv-glx mini.xml
Can somboedy with access to the bug tracker close
<http://sourceforge.net/tracker/index.php?func=detail&aid=1935911&group_id=148373&atid=772024>
I opened
<http://sourceforge.net/tracker/index.php?func=detail&aid=1938540&group_id=148373&atid=772024>
Bruno Postle wrote:
> On Tue 08-Apr-2008 at 08:51 -0400, Yuval Levy wrote:
>> <http://www.photopla.net/070618assnat/> worked last summer
>
> Yes this works with the latest code (after Leon fixed the bugs I
> added), both if I select QTVR or SPi-V.
cool! why didn't I think of trying the plugin right away? and why am I
in Windows when I want to play on Linux (and the other way around)?
> Though I can't view any SPi-V on fieldofview.com, due to the plugin
> not being detected:
>
> http://fieldofview.com/pano-fullscreen/
>
> Aldo?
I'm not sure he's on this list, but from what I can see here the above
page does not work on Windows with Shockwave either. IIRC he recently
migrated his site. I'll notify him.
Leon can tell us more about the details, but for webpages to work (or
not work) with SPiV content there are two cases: HTML (passive) vs.
JavaScript (dynamic) content embedding.
Passive content embedding should always work. If it does not, it's most
likely a FreePV bug. Because the plugin is properly registered to handle
the MIME type associated with Shockwave, and AFAIK there are no other
plugins competing from the same association. This in contrast with QTVR,
that shares the same MIME type as linear QuickTime content. A number of
media player plugins all compete for the same association, and only one
can be associated. Hence the importance to get the FreePV library
integrated in VLC as a GSoC project and proof of concept for other media
players to follow.
Dynamic content embedding may or may not work. If it does not, it's most
likely a website specific bug. The simple JavaScript just blindly adds
HTML tags and should work, but very often JavaScript is used for detection.
If the detection algorythm takes shortcuts such as assuming there is no
Shockwave player on other systems than Windows and Mac, it won't even
try to display the SPiV pano.
I've worked with Leon last year to make sure the name of the plugin and
its description are crafted so that they mimic as close as possible a
mix of the QuickTime and Shockwave ones to trigger the most common
string filters / regexp used against the plugin object in Mozilla. You
can see them when entering about:plugins in the address bar.
It's a fine line to walk. On the one side we have an interest for FreePV
to mimic both the QuickTime and the Shockwave plugins as close as
possible. On the other hand, we have an interest to disclose to well
crafted detecting website that this is not the real QuickTime or the
real Shockwave so that they can adapt to its specificity. I detect a few
QuickTime replacements in the FOSS world. None of them can play QTVR and
a few of them can play object movies. Being able to discern between them
makes my website work better in those cases, but I am afraid that for
most websites the combined quantity of all of those special cases is so
small that they simply choose to ignore them.
So if a website does not work as advertised with FreePV, the problem is
most often on that website, not in FreePV, and it is most likely that
they don't even know about it.
Yuv
I experienced many crashes of gecko powered browsers (galeon, epiphany,
firefox).
I've reported a bug against epiphany and got an answer as the culprit
was the freepv plugin.
In fact, I've desinstalled this plugin and got a stable behaviour.
See:
http://bugzilla.gnome.org/show_bug.cgi?id=527107
Regards
Jean-Luc
Done, but I opened a new bug #1938778 for the QTVR detection problem
that was ultimately responsible. I added a patch that works for me,
but somebody else will need to fix it properly (and securely).
--
Bruno