Font Size: a A A

Research On Multi-threaded Quick Response Code Generation Algorithm Based On Web Workers

Posted on:2018-02-10Degree:MasterType:Thesis
Country:ChinaCandidate:W SunFull Text:PDF
GTID:2428330512474213Subject:Information and Communication Engineering
Abstract/Summary:PDF Full Text Request
With the popularity of the Internet and the rapid development of the Internet of Things and smart terminal equipment,Quick Response code as a new information carrier and delivery tools also will be rapid develop.Quick Response code in all walks of life plays an integral role,it is widely used in a wide range of media,websites,e-ticketing,entertainment,shopping and other fields,not only Quick Response code used in social networks,and more widely used in business,payment and other services segments.There are many different kinds of Quick Response code generation techniques and algorithms,and it is hard to choose.For this problem,this paper studies various Quick Response code generation algorithms.This paper analyzed the advantages and disadvantages of each algorithm,proposed Quick Response code generation algorithm based on Web Workers and Quick Response code rendering algorithm based on SVG,then through specific experiments to measure the efficiency of each algorithm in different browser environment.HTML5 Web Workers standard create a multi-threaded environment for JavaScript,which allows JavaScript to create one or more threads,give full play to the potential of JavaScript.This paper uses the characteristics of multithread of Web Workers to handle the complex Quick Response code encoding process,and generate Quick Response code by sub-Worker thread.Because the SVG is a XML file essentially,this paper generate Quick Response code sequence of SVG on the use of sub-Worker thread first,and then display Quick Response code in HTML page by SVG.This method can reduce the pressure on the main JavaScript thread to the maximum extent.For the above Quick Response code generation algorithm Web Workers and Quick Response code rendering algorithm based on SVG,designed the experiment respectively.Each experiment detected Quick Response code total generating time and rendering time in Chrome,FireFox,IE and Opera browser environment by testing 40 groups respectively of different lengths Quick Response code input data.Each experimental test times averaged,then compared and analyzed the results by doing experiments on the line chart.Specific experimental verification analysis concluded the proposed multi-threaded Quick Response code generation algorithm and rendering algorithm based Web Workers are feasible.Multi-threaded Quick Response code generation algorithm increases the total time to improve stability of JavaScript main thread and browser;Web Workers rending algorithm uses SVG in most browser environment will increase the efficiency of rendering Quick Response code.Multi-threaded is first used to generate Quick Response code,and it is a big step forward.
Keywords/Search Tags:Quick Response code, HTML5, JavaScript, Web Workers, multi-threaded
PDF Full Text Request
Related items