Pages

Se afișează postările cu eticheta programming. Afișați toate postările
Se afișează postările cu eticheta programming. Afișați toate postările

sâmbătă, 7 septembrie 2024

vineri, 12 ianuarie 2024

CodePen: CodePen Home WebGL Flower Pattern (Voronoi diagram GLSL)

You can find good web development with a great graphics on Ksenia Kondrashova codepen account.
See this example named: CodePen Home WebGL Flower Pattern (Voronoi diagram GLSL):

marți, 3 ianuarie 2023

Manim : some example with manim.

You can see an official document writen in Jupiter notebook with Manim package from manim community, see this link.

marți, 12 aprilie 2022

News : The new release of Unity 2021 LTS.

Unity comes with a new released game engine:
We’re excited to introduce Unity 2021 LTS, now available to download and use.
You can download it from the official website.

duminică, 6 martie 2022

Online tool badge builder.

Badges or logos are often required in design and graphics.
An intermediate solution to a company logo or badge is to use a tool to create or generate it.
This is an online tool that can be used quickly with a very good output.

duminică, 5 decembrie 2021

News : CopperCube 6.5 released.

CopperCube 6.5 was just released for Windows and Mac on 2 December 2021.
You can see all new changes on the official webpage.
You can see a good video from the Gamefromscratch youtube channel.

sâmbătă, 4 septembrie 2021

Online tool shader-playground.

Here's an online tool for shaders.
This time it is a development with multiple shader specific languages and these compilers: ANGLE, Clspv, DXC, FXC, Glslang, hlsl2glslfork, HLSLcc, HLSLParser, Mali offline compiler, Naga, PowerVR compiler, Radon GPU Analyzer (RGA), Rust GPU, Slang, SPIRV-Cross, SPIRV-Cross - Intel fork with ISPC backend, SPIRV-Tools, spirv-as, Tint, XShaderCompiler.

duminică, 15 august 2021

Virtual Bones with Direct Delta Mush .

Direct Delta Mush (DDM) is a high-quality, direct skinning method with a low setup cost. However, its storage and run-time computing cost are relatively high for two reasons: its skinning weights are 4 × 4 matrices instead of scalars like other direct skinning methods, and its computation requires one 3 × 3 Singular Value Decomposition per vertex. see this PDF.
see this video for SIGGRAPH 2021 Presentation: Direct Delta Mush Skinning Compression with Continuous Examples

sâmbătă, 26 iunie 2021

News : $140,000 USD in prizes by Core Games.

Enter the Core Invitational game dev competition from July 29 to August 30 with $140,000 USD in prizes, including a grand prize Tesla Model 3! Visit https://invitational.coregames.com to download and create for free today!
Core is the easiest way to build, host, and run multiplayer games and worlds.
This team provide all you need to build a game from assets, servers, and all the code needed to get your first game built and published in minutes.
You can see more on the youtube official channel.

duminică, 20 iunie 2021

The BBC BASIC an 8-bit computer emulator.

BBC Micro bot runs your tweet on an 8-bit computer emulator.
The BBC BASIC - a language created by Sophie Wilson in 1981 for the BBC Micro.
You can share yor work like a tape or disk and test with a old computer.
This program will show a message and run commands on screen.
1 MODE 1:VDU 19,0,4,0,0,0:VDU 19,1,6,0,0,0
2 COLOUR 1
3 PRINT:PRINT "    **** COMODORE 64 BASIC V2 ****"
4 PRINT:PRINT " 64K RAM SYSTEM  38911 BASIC BYTES FREE"
5 PRINT:PRINT "READY."
See more about this on the official webpage.

News : Another game engine Rogue Engine.

Another game engine for web games using three.js .
Rogue Engine is a powerful environment to create Web Games and Apps using three.js.
The author of this game engine is BeardScript.
You can see more video on the youtube channel.

duminică, 14 martie 2021

OpenProcessing - simple tree_001.

This is modified example from this in order to build another good tree using openprocessing website interface.
You can see this example on my account.
Let's see the source code:
/*--based on https://openprocessing.org/sketch/396851--*/

var nbranchs = 73;
function setup() {
  createCanvas(640, 400);
  background(0, 0, 128);
  
  noFill();
  stroke(128);
  noLoop();
}

function draw() {
  tree(100, 200, 150, 350);
}
function mousePressed() {
  background(0, 0, 128);
  redraw();
}

function branch(x, y, dx, dy) {
  var sign = random(dx+1.0)/(abs(dx)+5.0);
  
  for (var i = 0; i <= x; i += 3) {
    var idx = i/x;
    
    var xi = bezierPoint(x, x + dx/2,   x + dx, x + dx, idx);
    var yi = bezierPoint(y, y, y + dy, y + dy, idx);

    line(xi, yi, xi + sign*random(8), yi + random(18));  
	
  }
}

function tree(left, right, top, bottom) {
  for (var idx = 0; idx < nbranchs; idx += 1) {
    
    // choose a random y position
    var y = random(bottom, top);
		
    
    // choose a random x position inside of a triangle
    var dx = map(y, bottom, top, 0.0, (right-left)/2.0);
    var x = random(left + dx, right - dx);
		
    var x1 = random(left + dx, right - dx);
    
		// choose the size of the branch according to the position on the tree
    var w = map (x, left, right, random(-25) -25, random(25)+25) + 1;
    var h = map (y, bottom, top, 5 +random(20), 5);
    
		var w1 = map (x, left, right, random(-35), random(35)) + 3;
    var h1 = map (y, bottom, top, random(10), random(10));
    // randonize the size
    var dw = random(-10, 5);
    var dh = random (-5, 5);
  	
		var dw1 = random(-5, 1);
    var dh1 = random (-1, 1);
    // create the new branch
		branch(x1, y, w1 + dw1, h1 + dh1);
		stroke(random(0),random(128),random(15));
		branch(x1, y, w1 + dw1, h1 + dh1);
		stroke(random(25),random(255),random(50));
    branch(x, y, w + dw, h + dh);
    
  }
}

luni, 1 februarie 2021

Shadertoy: Modulo N and shader effects.

You can see easily how the math function modulo n affects the shaders.
These three colors are the result of the function modulo n.
You can see two vectors with two modulo ivec areas with these values: 6 and 3.
You can make changes and you see similar results.
A good math teacher can explain why this is happening.
Let me give you a hint: encryption and decryption theories.

sâmbătă, 5 septembrie 2020

Shadertoy: The sin math function - 002.

This is another shader example to draw a sine math function using a sine wave, see Wikipedia. I used shadertoy website and the mat sin function by time. The source code is commented for a better understanding of it.
// this size of line to paint each pixel from screen
const float size = 0.01;

void mainImage( out vec4 fragColor, in vec2 fragCoord )
{
    // Normalized pixel coordinates (from 0 to 1)
    vec2 uv = fragCoord/iResolution.xy;
    // resize uv 
    uv = uv  * 2.0;
    // translate normalized pixel coordinates uv from [0,1] to [-1, 1] with 
    uv = (uv - 1.0);

    // get uv.x aspect ratio
    uv.x *= iResolution.x / iResolution.y;
  
    // get simple sine 
    //float t = sin(uv.x);

    // get sine * 3 with same size uv will zoom the sine graphic
    // see also https://en.wikipedia.org/wiki/Sine_wave
    float t = sin(uv.x * 3.0);
    
 // select domain area of sine and drwa yellow color 
    // else put an blue color on rest
    if (uv.y >= t - size && uv.y <= t + size) {
        // draw sine
     fragColor = vec4(1.0,1.0,0.0,1.0);
    } else {
        // draw background
        fragColor = vec4(0.0,0.0,1.0,1.0);
    }
}
The result of this shader is this:

duminică, 29 martie 2020

Unity 3D : About VFX Graph.

The official webpage of the VFX Graph for Unity 3D comes with a short intro.
The install steps can be seen on this webpage.
I started today to follow one video tutorial about fire and smoke from youtube channel named Brackeys.
This video tutorial can be seen here:

Some conclusions about my test with an old video card:
  • you need a good video graphic card;
  • you need a unity version with Package Manager;
  • I found some new changes using with the Unity 3D version 2019.3.5f1;
  • many changes in the 
  • the one is the Output Particle Quad with many changes into variables;
  • I cannot set the TotalTime, this crash it all;
The result is this:

The settings for this smoke effect using the Visual Effect Graph Asset can be seen in the next image:

marți, 24 martie 2020

Unity 3D : Fix error "Failed executing external process for 'Bake Runtime' job."

If you want to remove the error show on the Unity 3D console:
Failed executing external process for 'Bake Runtime' job.
... then go to Main Menu - Lightning - Settings and uncheck the Auto Generate checkbox.
See the screenshot shown below:

luni, 23 martie 2020

Unity 3D : Use Quick Fix on Visual Code for Unity and Linux.

Because I don't use Unity 3D with Linux and Visual Studio today I solve another issue for the development area.
This is the quick fix option for Visual Code that helps the user to add source code.
For example, you can add source code for the implement an abstract class PlayerBaseState:
using UnityEngine;

public abstract class PlayerBaseState 
{
    public abstract void EnterState(PlayerController_FSM player);
    public abstract void Update(PlayerController_FSM player);
    public abstract void OnCollisionEnter(PlayerController_FSM player);
}
Create a new C# script named PlayerIdleState. The script needs to be changed into this source code:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class PlayerIdleState : PlayerBaseState
{
    
}
Select the PlayerIdleState and use these keys: Cmd or Ctrl and . (the point key) .
This will show a menu named Generate overrides... and help the developer to generate the new code:
The result is this source code with all new override for each of methods of PlayerBaseState class:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class PlayerIdleState : PlayerBaseState
{
    public override void EnterState(PlayerController_FSM player)
    {
        throw new System.NotImplementedException();
    }

    public override bool Equals(object obj)
    {
        return base.Equals(obj);
    }

    public override int GetHashCode()
    {
        return base.GetHashCode();
    }

    public override void OnCollisionEnter(PlayerController_FSM player)
    {
        throw new System.NotImplementedException();
    }

    public override string ToString()
    {
        return base.ToString();
    }

    public override void Update(PlayerController_FSM player)
    {
        throw new System.NotImplementedException();
    }
}

joi, 19 martie 2020

Unity 3D : Setup Visual Code for Unity and Linux.

The tutorial for today will cover the settings of Visual Code and Unity into a Linux distro.
First, you need to install the Visual Code into your Linux distro.
You need to have the Unity 3D software working well into the Linux distro.
Open the Unity 3D software and create a new script using the main menu: Assets - Create - C# Script.
Open into Unity 3D from the main menu: Unity - preferences - External tools.
Select the Visual Studio Code like into the next image:

Double click on the newly created C# script.
This will open the Visual Studio Code and will ask you to install the C# feature using the Install button, see the next image:
 
This will install the C# extension for Visual Code.
The last step is the install of DotNet for Visual Code.
Use the button with the name Get the .Net Core SDK to install the Net CORE.
This will redirect to a webpage where you find the commands to install for your Linux distro.
After these steps, you can use Unity 3D software with Visual Code.

duminică, 15 martie 2020

Unity 3D : Settings for Android build game.

If you try to set the Android SDK on Unity 3D using the Linux O.S. then you can have a problem.
After you set the name of the package and the default android settings you can use External Tool from menu Edit - Preferences to set paths for Android SDK, NDK, and more.
This is the path I used to build with Android:
  • /home/catalin/Unity/Hub/Editor/2019.3.5f1/Editor/Data/PlaybackEngines/AndroidPlayer/OpenJDK
  •  /home/catalin/Unity/Hub/Editor/2019.3.5f1/Editor/Data/PlaybackEngines/AndroidPlayer/SDK
  • /home/catalin/Unity/Hub/Editor/2019.3.5f1/Editor/Data/PlaybackEngines/AndroidPlayer/NDK
  • /home/catalin/Unity/Hub/Editor/2019.3.5f1/Editor/Data/PlaybackEngines/AndroidPlayer/Tools/gradle
You can see the android SDK, NDK and Gradle is set on the Hub Editor This is my External Tools configuration for that build game:

Unity 3D : The new learning area ...

The Unity 3D game engine comes with significant improvements in the learning area.
If you know nothing about Unity Editor and C # then this area has a simple and efficient introduction for new developers of this game engine.
For example , see the Creator Kit: Beginner Code.
You can start with John Lemon's Haunted Jaunt: 3D Beginner or with the Ruby's Adventure: 2D Beginner.
I am starting to see how deep and good these tutorials are and for me it was quick to follow them and use them.
This is an more advance learn step from Unity 3D using the Creator Kit: Beginner Code.