Archives
Trending
Support
Login
clear text
XML
Django
JavaScript
MATLAB
C
C++
C#
Python
SQL
Shell
Bash
Markdown
YAML
JSON
HTML
CSS
PHP
Java
Ruby
Go
Rust
Swift
Kotlin
Arduino
TypeScript
Perl
Autohotkey
Lua
SQF
R
Scala
Haskell
Groovy
Dart
Clojure
VB.NET
Objective-C
PowerShell
Bash
CoffeeScript
Verilog
"; $centerX = $width / 2; $centerY = $height / 2; echo "
The center of the image is at " .$centerX . ", " . $centerY ; echo '
Test Trig Fucntions php
Get all cordinates for a circle
'; $r = 1 ; $sum = 0; echo 'Radiuz == ' . $r . '
X, Y, PixelColour at that point.
'; $im = imagecreatefromjpeg($fiel); $Pi = pi(); for ($a=0; $a<=1; $a++) { $ax = $r*cos($a*$Pi/180) + $centerX ; //x $ay = $r*sin($a*$Pi/180) + $centerY ; //y $PXCol = imagecolorat($im, $ax, $ay); echo $ax . ", " . $ay . ", " . $PXCol . "
"; //$sum = $sum + $PXCol; //$avg = $sum / 360; } //Says red ff0000 is 16646144 //echo "
Average Pixel Value in ring is: ". $avg . "
"; //$trunc = round($avg); //echo "
Trucated Average: ".$trunc."
"; echo "
Average in Hex: ". dechex(16646144) ."
"; echo "
The value FF0000 should be: ". hexdec("#FF0000") ."
"; ?>
Mark as private (unlisted)
for 30 minutes
for 6 hours
for 1 day
for 1 week
for 1 month
for 1 year
everlasting (like CCCP)