-
Notifications
You must be signed in to change notification settings - Fork 269
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds Python bindings for the Light convenience class #2043
Conversation
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tests?
Codecov Report
@@ Coverage Diff @@
## main #2043 +/- ##
==========================================
- Coverage 65.35% 65.30% -0.06%
==========================================
Files 320 321 +1
Lines 30216 30303 +87
==========================================
+ Hits 19749 19789 +40
- Misses 10467 10514 +47
|
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
bde5acb
to
ebab22a
Compare
@azeey The setters for this class doesn't seem to be working for some reason I'm not able to find. The test I added shouldn't be passing after I set the property to another value and they do. Also there are other values that doesn't change from the default value even after defining it on the sdf file such as the |
python/test/light_test.sdf
Outdated
<sdf version="1.6"> | ||
<world name="world_test"> | ||
|
||
<light type="point" name="light_test"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The <direction>
and <spot>
parameters do not apply when the light type is "point" (see http://sdformat.org/spec?ver=1.10&elem=light).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh I see, we have point
, spot
and directional
. That makes a lot more sense. That should solve some of my problems, but, I think the setters's issue remains the same.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made the required changes in 4e72d74. However, the behavior is the same as I expected, solved some issues but not a single set
method is working.
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
95ee75f
to
fadc032
Compare
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Michael Carroll <[email protected]>
Signed-off-by: Michael Carroll <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Voldivh <[email protected]>
fadc032
to
d2cf8f6
Compare
Signed-off-by: Eloy Briceno <[email protected]>
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Eloy Briceno <[email protected]>
Signed-off-by: Voldivh <[email protected]>
python/src/gz/sim/Light.cc
Outdated
#include <pybind11/pybind11.h> | ||
#include <pybind11/stl.h> | ||
|
||
#include <iostream> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Voldivh can you address this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the header is still there? did you push ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Might have been re-added when bringing back an older commit for testing. Fixed in 801bb08
python/src/gz/sim/Light.hh
Outdated
{ | ||
namespace python | ||
{ | ||
/// Define a pybind11 wrapper for a gz::sim::World |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/// Define a pybind11 wrapper for a gz::sim::World | |
/// Define a pybind11 wrapper for a gz::sim::Light |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks and done.
Signed-off-by: Eloy Briceno <[email protected]>
python/src/gz/sim/Light.cc
Outdated
#include <pybind11/pybind11.h> | ||
#include <pybind11/stl.h> | ||
|
||
#include <iostream> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Voldivh can you address this?
Signed-off-by: Voldivh <[email protected]>
Signed-off-by: Addisu Z. Taddese <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is still a pending comment, good to go when the iostream
header is removed
python/src/gz/sim/Light.cc
Outdated
#include <pybind11/pybind11.h> | ||
#include <pybind11/stl.h> | ||
|
||
#include <iostream> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the header is still there? did you push ?
Signed-off-by: Addisu Z. Taddese <[email protected]>
Signed-off-by: Addisu Z. Taddese <[email protected]>
🎉 New feature
Summary
This PR adds bindings for the
Light
convenience class.Checklist
codecheck
passed (See contributing)Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining
Signed-off-by
messages.