Summary of common usage of [C + +] set

I. concept set is a standard association container in STL. It uses a balanced search tree - red black tree to implement the underlying layer. When inserting and deleting operations, only pointer operation nodes are needed to complete, which does not involve memory movement and copy, so the efficienc ...

Posted by willythemax on Sun, 15 Mar 2020 20:55:58 -0700

ffplay -- source code analysis: code architecture

/* Minimum SDL audio buffer size, in samples. */ // Minimum audio buffer #define SDL_AUDIO_MIN_BUFFER_SIZE 512 /* Calculate actual buffer size keeping in mind not cause too frequent audio callbacks */ // To calculate the actual audio buffer size, you do not need to call back too often. The maximum numb ...

Posted by swatisonee on Sun, 15 Mar 2020 04:47:17 -0700

JS node access add, delete, modify and query (attach node access compatibility writing method of low version browser)

Node access add, delete, modify and query And get page element type, but node operation uses node level relationship to get elements Getting elements by parent-child sibling relationship Logical, but less compatible Generally, a node has at least three basic attributes: nodeType, nodeName and nodeVal ...

Posted by jek1134 on Sat, 14 Mar 2020 20:50:20 -0700

Getting started with Go language - process control

go process control String explanation String principle The bottom layer of string is a byte array, so it can be converted to and from [] byte type Characters in a string cannot be modified String is composed of byte, so the length of string is the length of byte The run type (int32 in four bytes) is used to represent utf8 characters. A run co ...

Posted by fredted40x on Sat, 14 Mar 2020 08:37:41 -0700

Java IO details -- byte stream and character stream

1, Byte stream overview Byte stream is divided into byte output stream and byte input stream Byte stream directly operates on binary data; byte stream is generally used to operate on media files, such as pictures 2, Byte output stream outputStream in java is an abstract class that controls ...

Posted by ashton321 on Sat, 14 Mar 2020 06:18:19 -0700

Classification algorithm - K-nearest neighbor algorithm (with case and test data)

One definition If most of the k most similar samples in the feature space belong to a certain category, then the sample also belongs to this category. 1.1 distance formula The distance between two samples can be calculated by the following formula, also called Euclidean distance II. Analysis of fi ...

Posted by aclees86 on Sat, 14 Mar 2020 04:17:16 -0700

Understanding of SurfaceFlinger (12) in Android GUI system

Link to the general outline of this series of articles: surface flinger series of articles of Android GUI system Summary & description of key points in this chapter: The mind map of this chapter is as above. This paper mainly introduces the concept of FrameBuffer, mainly focuses on the basic ...

Posted by russia5 on Fri, 13 Mar 2020 22:37:38 -0700

Surface flinger (01) display system framework of Android GUI system

Link to the general outline of this series of articles: surface flinger series of articles of Android GUI system Summary & description of key points in this chapter: The mind map of this chapter is as above. It mainly describes the basis of the display system, understands the relationship be ...

Posted by ChaosXero on Fri, 13 Mar 2020 22:22:55 -0700

The summary of js anti shake and throttle

In recent projects, the test proposed that clicking the button quickly for many times would trigger multiple calls of the interface. Later, when querying the data, you can use the anti shake optimization, which just integrates the use of anti shake and throttling for your own learning Code: <!DOCTYPE html> <html> <head> ...

Posted by shamuraq on Fri, 13 Mar 2020 03:24:07 -0700

bmp image graying and binarization

C language removes the background of bmp picture I. Preface 2, Grayscale Header file C file 3, Binarization I. Preface In image processing, most of the processing methods need to convert color image into gray image in advance to carry out relevant calculation and recognition. The principle of ...

Posted by robb73 on Thu, 12 Mar 2020 06:05:26 -0700