Tag:distance

  • Slow motion animation by time warping

    Time:2021-7-19

    Slow motion animation by time warping We often see all kinds of jogging functions. In CSS, there are ready-made jogging effects such as bounce and elastic, which can be used directly. If we want to implement these jog functions in canvas animation. It’s a headache to think about how to deal with it directly. This […]

  • Spring boot 2 real combat: using redis’s geo function to find nearby locations

    Time:2021-7-7

    1. Preface The boss suddenly wants to go online for a demand to obtain the business agent point with the current location of one kilometer. Online tomorrow! When I received this demand, I almost vomited blood, and the time was too tight. Hurry to check the relevant technology selection. After a lot of twists and […]

  • How to set the background image in HTML (full screen display without stretching)

    Time:2021-7-2

    1 <br><em id=”__mceDel”>2 body{background-image:url(https://uploadbeta.com/api/pictures/random/?key=BingEverydayWallpaperPicture);</em></code></pre> <pre><code><em id=”__mceDel”><em id=”__mceDel”>3 background-size:cover;background-attachment: fixed; 4 background-repeat:no-repeat;background-position:center } It’s the code I use Background: background colorBackground image: select your background imageReapeat: whether the background image is repeated or not, itsSelect no repeat asRepeat is not repeated, repeat is repeated, repeat-x and repeat-y are only repeated in X and Y direction respectively.Attachment: […]

  • IPhone x design website adaptation

    Time:2021-6-24

    Design website adaptation for iPhone x Almost all front-end developers will come into contact with designing H5 web pages for iPhone x, in which they have to adapt to its unique security area in order to optimize the user experience. Safe area Layout guides define rectangular areas that don’t actually appear on the screen, but […]

  • Gets the distance from any (non fixed) DOM element to the HTML at the top of the page

    Time:2021-6-8

    function toTopHeight(el) { var top_ height = el.offsetTop; // First save the offsettop value of the current element if(el&&el.nodeName!=’HTML’) { el = el.parentElement; while(el&&el.nodeName!=” HTML “) {// when the current element is not the top HTML tag, continue the iteration if(getComputedStyle(el).position!==’static’){ //The offset top value of an element is added to the result only when […]

  • Personal learning series – spring boot uses redisgeo to realize location search function

    Time:2021-6-5

    Recently, when using tuanyou, I always thought that its function of sorting by distance was very good, so I tried to study it. 1. Create a new spring boot project 1.1 pom.xml Add redis dependency and Lombok dependency <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-redis</artifactId> </dependency> <dependency> <groupId>org.projectlombok</groupId> <artifactId>lombok</artifactId> <version>1.18.16</version> <scope>provided</scope> </dependency> 1.2 application.yml #Redis database index (default is […]

  • Reproducing kernel Hilbert space

    Time:2021-6-4

    Hilbert space Let’s first talk about what isHilbert space。 This concept sounds tall, but it’s actually a very simple concept.First of all, what is itlinear space linear space Linear space is the space that defines multiplication and addition. This is a space with a linear structure. With the concept of linear space, we can find […]

  • Can people near wechat also use redis( GEO)

    Time:2021-5-13

    I believe that the functions of people around wechat should have been usedI can easily see people near me through my own positioning, and see the distance from that person to me. Have you ever thought about how to achieve this? As a program, any problem should have a process of thinking, rather than looking […]

  • On the calculation of the distance between two longitudes and latitudes

    Time:2021-5-4

    Generally speaking, the linear distance between two points we usually see when calculating latitude and longitude is directly linked to the distance between the driving and cycling curves, as the map docking of APP docking map, official account and other small programs, etc., so the two cannot be equated attention. Here are two ways to […]

  • Bootstrap column sort

    Time:2021-5-3

    Column sorting is actually changing the direction of the column, that is, changing the left and right floating, and setting the floating distance. In the grid system of bootstrap framework, the class name “col MD push” is added-”And “col MD pull”-”(where the asterisk represents the number of column combinations moved). Let’s look at a simple […]

  • Use jcanvascript plug-in to simplify canvas operation to draw interface

    Time:2021-5-3

    Directly on the code, copy to the file, run directly can see the effect; Plug in address jcanvascript:http://jcscript.com <!DOCTYPE html> <html lang=”en”> <head> <meta charset=”UTF-8″> <title>jcanvas</title> </head> <script></script> <body> <canvas height=”568″ width=”320″ id=”canvas_1″ style=”border:1px solid #ccc;width:320px;height:568px”></canvas> </body> <script> var h = 1; var img=new Image(); img.src=”./head.png” jc.start(‘canvas_1′); jc.rect(0,0,320*h,130*h,’#ff5d5e’,true); JC. Text (“personal center”, 160 * h, […]

  • Weekly canvas animation — circular motion

    Time:2021-5-1

    Next to “weekly canvas animation” — wave motion Circular motion can be divided into two basic formsCircular motionandElliptical motion。Before explaining circular motion, the essential mathematical formula is about to come. So, ladies and gentlemen, please protect your knees. It doesn’t matter if you don’t understand, just understand the principle. Of course, can understand is the […]