Skip to content
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

drawable area cairo #67

Open
diver3416 opened this issue Oct 21, 2019 · 3 comments
Open

drawable area cairo #67

diver3416 opened this issue Oct 21, 2019 · 3 comments

Comments

@diver3416
Copy link

Hi,
I'm working on a project based on your library and example mapviewer.py.
I would like to add several layers (real-time localisation of a robot, waypoints and paths the robot can take) and I try to create a cairo drawable area that matches with the map displayed on Gtk window.
I don't know how to proceed, i see on cairo website some examples like this but how to define the surface that will be used to draw compared with map displayed ???
surface = cairo.ImageSurface(cairo.FORMAT_ARGB32, WIDTH, HEIGHT)
ctx = cairo.Context(surface)
Thanks a lot in advance for your help (if you can tell me lines to add to mapviewer.py)
David

@diver3416
Copy link
Author

In other words, i understand that I need to create a cairo context where I need to set the target surface.
What is the surface that I need to use ?

@MichalMisiaszek
Copy link

In other words, i understand that I need to create a cairo context where I need to set the target surface.
What is the surface that I need to use ?

Did you find solution ?

@nzjrs
Copy link
Owner

nzjrs commented Sep 14, 2020 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants