10.07.2015 Views

HALCON Extension Package Programmer's Manual

HALCON Extension Package Programmer's Manual

HALCON Extension Package Programmer's Manual

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

2.2. EXTENDED OPERATOR DESCRIPTION 23(‘true’) by a program thread, or whether it may called by any (“external”) thread withoutproblems. The slot is mainly important when programming multithreaded applicationsunder Windows NT and Windows 2000. Here, there exists a direct mapping betweenprogram threads and graphical elements, such as windows, dialog boxes or button controls.In short, a graphical element only exists in the context of its associated thread. Thiscan cause severe problems, for example, hang the application, if another thread tries toperform user interactions via graphical elements which belong to other threads. For example,troubles might occur under Windows NT/ 2000, if one thread opens a window viaÓÔÒ ÛÒÓÛ and another thread tries to get input from this window via ÖÛ ÖÐ.As it is not always obvious for all operators, whether they work with critical (graphical)elements or not, the slot ÔÖÓ×× ÐÓÐÐÝ was introduced. If ÔÖÓ×× ÐÓÐÐÝ isset to ‘true’, this signals the programmer that the corresponding operator must be usedcarefully within multithreaded Windows NT/ 2000 applications. The most simple wayto avoid any problems with such operators is to process them all under mutual exclusionwithin the main thread of the program.As a side effect, Parallel <strong>HALCON</strong> processes an operator without parallelization regardlessthe settings of the subslots ÑØÓ and ÓÑÒ ×ÔÐØ,ifÔÖÓ×× ÐÓÐÐÝ is set to‘true’. This avoids problems with ‘local’ operators and multithreading and makes sensebecause ‘local’ operators normally are responsible for graphical interaction and thus arenot suitable for parallelization.If no subslot ÔÖÓ×× ÐÓÐÐÝ is filled in with an operator, it is assumed that the operatormust be processed “locally” (“pessimistic” assumption). However, this subslot should befilled in in any case, because it contains a very useful information for programmers ofmultithreaded applications.ÑØÓ ÒÓÒ¸×ÔÐØ ØÙÔи×ÔÐØ ÒÒи×ÔÐØ ÓÑÒThis subslot of ÔÖÐÐÐÞØÓÒ can contain one or more of the strings above andspecifies, which type of (automatic) parallelization the operator is suitable for:¯ ×ÔÐØ ØÙÔÐ: Parallel <strong>HALCON</strong> does not automatically parallelize the operator.¯ ×ÔÐØ ØÙÔÐ: Parallel <strong>HALCON</strong> parallelizes the operator by splitting every inputimage tuple into several subsets of the tuple; the tuple subsets are then processed inparallel.¯ ×ÔÐØ ÒÒÐ: Parallel <strong>HALCON</strong> parallelizes by splitting every multichannel(input) image into several subsets of the channels; the subsets are then processedin parallel.¯ ×ÔÐØ ÓÑÒ: Parallel <strong>HALCON</strong> parallelizes by splitting the domain of everyinput image into several parts; the parts are then processed in parallel.If ÑØÓ is set to anything other but ‘none’, the parameter slot Ó×Ø× ÛØ must befilled in for every input control parameter and the parameter slot ÔÓ×ØÔÖÓ××Ò mustbe filled in for every output control parameter of the operator (see page 29)!If ÑØÓ is set to ‘split domain’, the slot ÓÑÒ ×ÔÐØ (see below) must also be setcorrectly and may not be omitted !If the slot ÔÖÓ×× ÐÓÐÐÝ is set to ‘true’, ÑØÓ should be set to ‘none’, because theoperator won’t be parallelized then (see description of ÔÖÓ×× ÐÓÐÐÝ above).<strong>HALCON</strong> 6.0

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!