Merge pull request #19319 from TolyaTalamanov:at/introduce-gopaque-garray-for-python

[G-API] Introduce GOpaque and GArray for python

* Introduce GOpaque and GArray for python

* Fix ctor

* Avoid code duplication by using macros

* gapi: move Python-specific files to misc/python

* Fix windows build

Co-authored-by: Alexander Alekhin <alexander.a.alekhin@gmail.com>
This commit is contained in:
Anatoliy Talamanov
2021-02-09 16:55:16 +03:00
committed by GitHub
parent 8fa013309e
commit c527b3cefd
4 changed files with 213 additions and 2 deletions
+8 -2
View File
@@ -1020,8 +1020,14 @@ class PythonWrapperGenerator(object):
decls = self.parser.parse(hdr)
if len(decls) == 0:
continue
if hdr.find('opencv2/') >= 0: #Avoid including the shadow files
self.code_include.write( '#include "{0}"\n'.format(hdr[hdr.rindex('opencv2/'):]) )
if hdr.find('misc/python/shadow_') < 0: # Avoid including the "shadow_" files
if hdr.find('opencv2/') >= 0:
# put relative path
self.code_include.write('#include "{0}"\n'.format(hdr[hdr.rindex('opencv2/'):]))
else:
self.code_include.write('#include "{0}"\n'.format(hdr))
for decl in decls:
name = decl[0]
if name.startswith("struct") or name.startswith("class"):