You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am a backer of the pixy project on kickstarter and out of my own self interest I started to try to compile the pixy host application on Linux (both my Laptop and my stationary PC run Fedora 19).
The first thing that the compiler complained about are the lines 739 and 740 in pixy/host/pixymon/renderer.cpp:
unsigned int addr = (unsigned int)comps;
unsigned int paddr = (unsigned int)&comps;
Here you try to cast a int16_t* into an unsigned int which does not work, because at least with my gcc version on linux you need an unsigned long int to hold the value of a pointer.
While this fixes the error emitted by the compiler:
Why do you try to cast a pointer to an integer in the first place? On a system with virtual memory this is generally not a good idea. At least you should use a reinterpret_cast to show that you know what you are doing.
Since addr and paddr are only used to initialize k and l, I can not figure out what your intent with this is.
Kevin
The text was updated successfully, but these errors were encountered:
I am a backer of the pixy project on kickstarter and out of my own self
interest I started to try to compile the pixy host application on Linux
(both my Laptop and my stationary PC run Fedora 19).
The first thing that the compiler complained about are the lines 739 and
740 in pixy/host/pixymon/renderer.cpp:
unsigned int addr = (unsigned int)comps;
unsigned int paddr = (unsigned int)&comps;
Here you try to cast a int16_t* into an unsigned int which does not work,
because at least with my gcc version on linux you need an unsigned long
int to hold the value of a pointer.
While this fixes the error emitted by the compiler:
Why do you try to cast a pointer to an integer in the first place? On a
system with virtual memory this is generally not a good idea. At least you
should use a reinterpret_cast to show that you know what you are doing.
Since addr and paddr are only used to initialize k and l, I can not
figure out what your intent with this is.
Kevin
—
Reply to this email directly or view it on GitHubhttps://github.com//issues/1
.
Hey,
I am a backer of the pixy project on kickstarter and out of my own self interest I started to try to compile the pixy host application on Linux (both my Laptop and my stationary PC run Fedora 19).
The first thing that the compiler complained about are the lines
739
and740
inpixy/host/pixymon/renderer.cpp
:Here you try to cast a
int16_t*
into anunsigned int
which does not work, because at least with my gcc version on linux you need anunsigned long int
to hold the value of a pointer.While this fixes the error emitted by the compiler:
Why do you try to cast a pointer to an integer in the first place? On a system with virtual memory this is generally not a good idea. At least you should use a
reinterpret_cast
to show that you know what you are doing.Since
addr
andpaddr
are only used to initializek
andl
, I can not figure out what your intent with this is.Kevin
The text was updated successfully, but these errors were encountered: